Asdf-erlang: Unable to recover from failed Erlang 23.0 installation

Created on 14 May 2020  路  9Comments  路  Source: asdf-vm/asdf-erlang

I ran into #141 earlier, which means I ran asdf install erlang 23.0 before #142 was merged/pulled.

But the problem I'm seeing now is:

jason@jdesktop ~/config (arch-desktop)> asdf install erlang 23.0
Downloading kerl...
There's already a build named asdf_23.0
jason@jdesktop ~/config (arch-desktop) [1]> asdf uninstall erlang 23.0
No such version
jason@jdesktop ~/config (arch-desktop) [1]> asdf install erlang 23.0
There's already a build named asdf_23.0

So instead I had to manually remove 23.0 from ~/.asdf/plugins/erlang/kerl-home/otp_installations and ~/.asdf/plugins/erlang/kerl-home/otp_builds. So it seems like there is a bug in the build is treated as successful too early. Also it might be good for asdf uninstall erlang 23.0 to remove 23.0 from the otp_installations and otp_builds directories even if 23.0 was not fully installed.

I also had to remove ~/.asdf/plugins/erlang/kerl-home/archives/OTP-23.0.tar.gz to get the build to start working.

bug

Most helpful comment

Try this.

  • remove line with '23'-thing in :

    • ~/.asdf/plugins/erlang/kerl-home/otp_installations

    • ~/.asdf/plugins/erlang/kerl-home/otp_builds

  • asdf plugin update --all
  • asdf install erlang 23.0

Success message:

$ asdf install erlang 23.0
Extracting source code
Building Erlang/OTP 23.0 (asdf_23.0), please wait...
Erlang/OTP 23.0 (asdf_23.0) has been successfully built
Installing Erlang/OTP 23.0 (asdf_23.0) in /Users/fahrinh/.asdf/installs/erlang/23.0...
You can activate this installation running the following command:
. /Users/fahrinh/.asdf/installs/erlang/23.0/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for
Cleaned up compilation products for  under /Users/fahrinh/.asdf/plugins/erlang/kerl-home/builds
ln: ./erl_call: File exists

Erlang 23.0 has been installed. Activate globally with:

    asdf global erlang 23.0

Activate locally in the current folder with:

    asdf local erlang 23.0

All 9 comments

Also that install ended up failing as well

Edit: it actually seems like it worked, the first time I think I may have hit ctrl-c at some point near the beginning of the build since I had received sigint, cleaning up at the end.

I have same issue here:

$ asdf install erlang 23.0
There's already a build named asdf_23.0

$ asdf uninstall erlang 23.0
No such version

My install seems to have finished the kerl part but failed at ln: ./erl_call: File exists (https://github.com/asdf-vm/asdf-erlang/issues/141):

$ asdf install erlang 23.0
Downloading OTP-23.0.tar.gz to /Users/bruce.yinhe/.asdf/plugins/erlang/kerl-home/archives
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   120  100   120    0     0    369      0 --:--:-- --:--:-- --:--:--   369
100 53.7M    0 53.7M    0     0  3672k      0 --:--:--  0:00:14 --:--:-- 2573k
Extracting source code
Building Erlang/OTP 23.0 (asdf_23.0), please wait...
Erlang/OTP 23.0 (asdf_23.0) has been successfully built
Installing Erlang/OTP 23.0 (asdf_23.0) in /Users/bruce.yinhe/.asdf/installs/erlang/23.0...
You can activate this installation running the following command:
. /Users/bruce.yinhe/.asdf/installs/erlang/23.0/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for
Cleaned up compilation products for  under /Users/bruce.yinhe/.asdf/plugins/erlang/kerl-home/builds
ln: ./erl_call: File exists

Edit: This seems to be fixed by https://github.com/asdf-vm/asdf-erlang/pull/142. I first removed asdf_23.0 from both:

~/.asdf/plugins/erlang/kerl-home/otp_builds
~/.asdf/plugins/erlang/kerl-home/otp_installations

then

asdf plugin update erlang
asdf install erlang 23.0

Try this.

  • remove line with '23'-thing in :

    • ~/.asdf/plugins/erlang/kerl-home/otp_installations

    • ~/.asdf/plugins/erlang/kerl-home/otp_builds

  • asdf plugin update --all
  • asdf install erlang 23.0

Success message:

$ asdf install erlang 23.0
Extracting source code
Building Erlang/OTP 23.0 (asdf_23.0), please wait...
Erlang/OTP 23.0 (asdf_23.0) has been successfully built
Installing Erlang/OTP 23.0 (asdf_23.0) in /Users/fahrinh/.asdf/installs/erlang/23.0...
You can activate this installation running the following command:
. /Users/fahrinh/.asdf/installs/erlang/23.0/activate
Later on, you can leave the installation typing:
kerl_deactivate
Cleaning up compilation products for
Cleaned up compilation products for  under /Users/fahrinh/.asdf/plugins/erlang/kerl-home/builds
ln: ./erl_call: File exists

Erlang 23.0 has been installed. Activate globally with:

    asdf global erlang 23.0

Activate locally in the current folder with:

    asdf local erlang 23.0

My installation gets stuck here:
Building Erlang/OTP 23.0 (asdf_23.0), please wait...

@phpcitizen how long did you wait for it to install? It may take 30 minutes or more on some systems. Check your CPU usage.

@Stratus3D I think I waited more than 30 minutes, let it go for a while...

I tried it on WSL Ubuntu, did not check CPU, will check.

Edit: Waited longer and installation done.

following the steps pointed by @fahrinh worked for me!
Thank you guys

Was this page helpful?
0 / 5 - 0 ratings

Related issues

RobinClowers picture RobinClowers  路  3Comments

denegny picture denegny  路  6Comments

zacky1972 picture zacky1972  路  3Comments

denegny picture denegny  路  6Comments

cehoffman picture cehoffman  路  3Comments