Gaussia
February 29, 2024, 10:03pm
1
I have a new ubuntu 22 computer, and try to install Julia via:
$ curl -fsSL https://install.julialang.org | sh
info: downloading installer
curl: (23) Failure writing output to destination
juliaup: command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.reaO5Z3yWc/juliainstaller x86_64-unknown-linux-musl
(output included)
Not sure how to proceed from here. The computer is new, and there is not previous Julai installations on it. I have sudo permissions. Here is some info:
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.4 LTS
Release: 22.04
Codename: jammy
I have tried restarting the computer, but the result is the same.
Have you tried installing using apt? Just try a generic
sudo apt install julia
Should work fine.
1 Like
Does this install Julai with the juliaup interface active?
I have some vague memory of running into problems with the /tmp
directory under ubuntu.
You might want to try changing your configuration to use a tmp
directory in your user directory e.g. ~/tmp
Think you would do mkdir ~/tmp
and then export TMPDIR=~/tmp
.
It’s a while since I’ve had to do this so hope I’m not sending you off in the wrong direction, but perhaps worth a shot if nothing else is working.
edit: TMPDIR
works with debian and the mktemp
command rather than TEMP
1 Like
johnh
March 1, 2024, 1:22pm
6
Idiot question from me - why the musl version? Ubuntu 22 is a pretty mainstream distro, why not glibc?
2 Likes
When I do this I get an error:
:~$ sudo apt install julia
[sudo] password for user:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package julia is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'julia' has no installation candidate
Unfortunatley modifying the TMP directory didn’t work either:
torkelloman@system76-pc:~$ mkdir ~/tmp
torkelloman@system76-pc:~$ ls
Desktop Downloads Music Public Templates Videos
Documents examples.desktop Pictures snap tmp
torkelloman@system76-pc:~$ TMPDIR=~/tmp
torkelloman@system76-pc:~$ curl -fsSL https://install.julialang.org | sh
info: downloading installer
curl: (23) Failure writing output to destination
juliaup: command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.GXtRIHrSLf/juliainstaller x86_64-unknown-linux-musl
johnh
March 1, 2024, 5:22pm
9
Could you give this a try:
cd /tmp
wget https://install.julialang.org
sh -x index.html
ps. totally unrelated anecdote - at FOSDEM the developer of curl said he received death threats (some unbalanced person was convinced that the developer ruined his life for some bizarre reason)
Also he regularly gets help requests for automotive satnav setups as his email address is listed in the copyright notices.
2 Likes
You might just download the zip file, put is somewhere, and put it in your PATH
https://julialang-s3.julialang.org/bin/linux/x64/1.10/julia-1.10.1-linux-x86_64.tar.gz
I had to do that with Solus that I run in a VM, works fine.
1 Like
You probably need the export
, so
export TMPDIR=~/tmp
Also, thinking about it, the script might start it’s own shell and the environment variable won’t persist, so you could try adding it to your .bashrc
file
echo export TMPDIR=~/tmp >> ~/.bashrc
source ~/.bashrc
Check it’s as expected when you start a new shell session
echo $TMPDIR
When you run mktemp
it should create a directory in the right location e.g. ~/tmp/tmp.aksjdfh234
Note the part in your error message:
/tmp/tmp.reaO5Z3yWc
This is what I’m intending to see change.
2 Likes
Unfortunately does not work, I get an error on the last command:
/tmp$ sh -x index.html
+ has_local
+ set -u
+ JULIAUP_SERVER=https://julialang-s3.julialang.org
+ JULIAUP_VERSION=1.14.5
+ main
+ downloader --check
+ is_zsh
+ [ -n ]
+ local _dld
+ local _ciphersuites
+ local _err
+ local _status
+ local _retry
+ check_cmd curl
+ command -v curl
+ _dld=curl
+ [ --check = --check ]
+ need_cmd curl
+ check_cmd curl
+ command -v curl
+ need_cmd uname
+ check_cmd uname
+ command -v uname
+ need_cmd mktemp
+ check_cmd mktemp
+ command -v mktemp
+ need_cmd chmod
+ check_cmd chmod
+ command -v chmod
+ need_cmd mkdir
+ check_cmd mkdir
+ command -v mkdir
+ need_cmd rm
+ check_cmd rm
+ command -v rm
+ need_cmd rmdir
+ check_cmd rmdir
+ command -v rmdir
+ need_cmd ln
+ check_cmd ln
+ command -v ln
+ need_cmd cat
+ check_cmd cat
+ command -v cat
+ need_cmd tty
+ check_cmd tty
+ command -v tty
+ get_architecture
+ local _ostype _cputype _bitness _arch _clibtype
+ uname -s
+ _ostype=Linux
+ uname -m
+ _cputype=x86_64
+ _clibtype=gnu
+ [ Linux = Linux ]
+ uname -o
+ [ GNU/Linux = Android ]
+ _clibtype=musl
+ [ Linux = Darwin ]
+ [ Linux = SunOS ]
+ check_proc
+ test -L /proc/self/exe
+ _ostype=unknown-linux-musl
+ get_bitness
+ need_cmd head
+ check_cmd head
+ command -v head
+ local _current_exe_head
+ head -c 5 /proc/self/exe
+ _current_exe_head=ELF
+ printf \177ELF\001
+ [ ELF = ELF ]
+ printf \177ELF\002
+ [ ELF = ELF ]
+ echo 64
+ _bitness=64
+ _cputype=x86_64
+ [ unknown-linux-musl = unknown-linux-gnu ]
+ [ unknown-linux-musl = unknown-linux-gnueabihf ]
+ _arch=x86_64-unknown-linux-musl
+ RETVAL=x86_64-unknown-linux-musl
+ local _arch=x86_64-unknown-linux-musl
+ assert_nz x86_64-unknown-linux-musl arch
+ [ -z x86_64-unknown-linux-musl ]
+ local _ext=
+ local _url=https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl
+ local _dir
+ ensure mktemp -d
+ mktemp -d
+ _dir=/tmp/tmp.gZEpmvrhn9
+ local _file=/tmp/tmp.gZEpmvrhn9/juliainstaller
+ local _ansi_escapes_are_valid=false
+ [ -t 2 ]
+ [ set = set ]
+ _ansi_escapes_are_valid=true
+ local _y=no
+ local need_tty=yes
+ [ yes = yes ]
+ [ ! -t 1 ]
+ echo
+ true
+ printf \33[1minfo:\33[0m downloading installer\n
info: downloading installer
+ ensure mkdir -p /tmp/tmp.gZEpmvrhn9
+ mkdir -p /tmp/tmp.gZEpmvrhn9
+ ensure downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
+ downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
+ is_zsh
+ [ -n ]
+ local _dld
+ local _ciphersuites
+ local _err
+ local _status
+ local _retry
+ check_cmd curl
+ command -v curl
+ _dld=curl
+ [ https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl = --check ]
+ [ curl = curl ]
+ check_curl_for_retry_support
+ local _retry_supported=
+ check_help_for notspecified curl --retry
+ local _arch
+ local _cmd
+ local _arg
+ _arch=notspecified
+ shift
+ _cmd=curl
+ shift
+ local _category
+ curl --help
+ grep -q For all options use the manual or "--help all".
+ _category=all
+ curl --help all
+ grep -q -- --retry
+ true
+ _retry_supported=--retry 3
+ check_help_for notspecified curl --continue-at
+ local _arch
+ local _cmd
+ local _arg
+ _arch=notspecified
+ shift
+ _cmd=curl
+ shift
+ local _category
+ + curlgrep --help -q
For all options use the manual or "--help all".
+ _category=all
+ curl --help all
+ grep -q -- --continue-at
+ true
+ _retry_supported=--retry 3 -C -
+ RETVAL=--retry 3 -C -
+ _retry=--retry 3 -C -
+ get_ciphersuites_for_curl
+ [ -n ]
+ local _openssl_syntax=no
+ local _gnutls_syntax=no
+ local _backend_supported=yes
+ curl -V
+ grep -q OpenSSL/
+ _openssl_syntax=yes
+ local _args_supported=no
+ [ yes = yes ]
+ check_help_for notspecified curl --tlsv1.2 --ciphers --proto
+ local _arch
+ local _cmd
+ local _arg
+ _arch=notspecified
+ shift
+ _cmd=curl
+ shift
+ local _category
+ curl --help
+ grep -q For all options use the manual or "--help all".
+ _category=all
+ curl --help all
+ grep -q -- --tlsv1.2
+ curl --help all
+ grep -q -- --ciphers
+ grep -q -- --proto
+ curl --help all
+ true
+ _args_supported=yes
+ local _cs=
+ [ yes = yes ]
+ [ yes = yes ]
+ get_strong_ciphersuites_for openssl
+ [ openssl = openssl ]
+ echo TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384
+ _cs=TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384
+ RETVAL=TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384
+ _ciphersuites=TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384
+ [ -n TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384 ]
+ curl --retry 3 -C - --proto =https --tlsv1.2 --ciphers TLS_AES_128_GCM_SHA256:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_256_GCM_SHA384:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384 --silent --show-error --fail --location https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl --output /tmp/tmp.gZEpmvrhn9/juliainstaller
+ _err=curl: (23) Failure writing output to destination
+ _status=23
+ [ -n curl: (23) Failure writing output to destination ]
+ echo curl: (23) Failure writing output to destination
curl: (23) Failure writing output to destination
+ echo curl: (23) Failure writing output to destination
+ grep -q 404$
+ return 23
+ err command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
+ say command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
+ printf juliaup: %s\n command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
juliaup: command failed: downloader https://julialang-s3.julialang.org/juliaup/bin/juliainstaller-1.14.5-x86_64-unknown-linux-musl /tmp/tmp.gZEpmvrhn9/juliainstaller x86_64-unknown-linux-musl
+ exit 1
I think that might work for Julia 1.10 specifically, but I want to download the full juliaup version manager, since that just makes everything way easier once I want a new version.
1 Like
This worked, thanks a lot!
1 Like
Glad I could help.
Next question, why?
The /tmp
folder has weird permissions
drwxrwxrwt 21 root root 20K Mar 2 14:39 tmp/
Note, the t
at the end which is a “sticky” permission with execute, whatever that means.
We’re both on debian based systems, but I wonder if Ubuntu does something weird.
1 Like
johnh
March 2, 2024, 5:14pm
16
The installer works fine for me on a Vgrant box with ubuntu 222
This is the permissions for /tmp
drwxrwxrwt 13 root root 4096 Mar 2 17:11 tmp
1 Like
Got it. Still surprised how messy this is, figured I should have a really standard set up.
mkitti
March 3, 2024, 5:13am
18
Something still seems quite off here. Why is it downloading the musl version?
How did you install Ubuntu?
1 Like
johnh
March 3, 2024, 9:37am
19
I agree with @mkitti Please tell us your setup and the fix. This could be helpful for people in the future.
3 Likes
So, this is what confuses me. I just got a new laptop from https://system76.com/ (which specialises in linux laptops), with Ubuntu 22 on. I really hadn’t installed or done anything at all with it when i encountered this problem. So I figured my set-up should be the most normal one could expect. It seems really strange that I got these problems.