Sdkman - Cannot Install Java on Ubuntu - Permission Denied

Sdkman - Cannot Install Java on Ubuntu - Permission Denied

I just installed sdkman on Ubuntu 20.04.2 LTS following the instructions here. Now, i am trying to install java, but i am getting a permission issue:

Issue

user@u:~$ sdk i java

Downloading: java 11.0.11.hs-adpt

In progress...

#################################################################################################################################################################################################### 100.0%Warning: Failed to create the file Warning: /home/user/.sdkman/tmp/java-11.0.11.hs-adpt.bin: Permission denied 0.0%curl: (23) Failure writing output to destination

Download has failed, aborting!

Can not install java 11.0.11.hs-adpt at this time...

ls -lrta .sdkman
drwxrwxr-x 3 user user 4096 May 31 10:47 tmp

Any help is much appreciated, thanks!

3

1 Answer

I had the same problem when I installed curl using snap.

On stackoverflow I found help :)

sudo snap remove curl
sudo apt-get install curl

After this and restarted bash session sdkman work fine

Installing: java 11.0.11-open
Done installing!
1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Alexander Ross
Author

Alexander Ross

Alexander Ross has covered the video game industry for a decade, writing deep dives on game design, esports tournaments, VR developments, and gaming culture.