Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JDK is not downloaded to the /tmp directory #596

Closed
cprin21 opened this issue Apr 15, 2024 · 11 comments · Fixed by #619
Closed

JDK is not downloaded to the /tmp directory #596

cprin21 opened this issue Apr 15, 2024 · 11 comments · Fixed by #619
Labels
bug Something isn't working

Comments

@cprin21
Copy link

cprin21 commented Apr 15, 2024

INFO: downloading 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip' to '/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
ERROR: '/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip' does not exist, aborting

The directories are made but the zip does not get downloaded from github.
I believe the issue must be in step/download_external_resources.sh
I am on Fedora if this matters!

@andymason
Copy link

To add some more information about this issue. I also encountered the problem running Fedora testing. In my case, the issue was caused by using wget in the download.sh util. Switching to curl resolved the problem. Maybe something has changed with the wget output?

@cprin21
Copy link
Author

cprin21 commented Apr 19, 2024

Not going to mark this as closed due to it still being an issue in 4.6.1 but yes, forcing download.sh to use curl instead of wget on Fedora 40 Beta does indeed get the script to work as intended again.

I also manually confirmed the sources the script pulls from are still up and running which means the issue is indeed not that the JDK was taken down on github but rather some issue with wget on Fedora 40 Beta.

@cprin21
Copy link
Author

cprin21 commented Apr 20, 2024

I have posted a quick workaround to force the use of curl instead of wget. See #601 (comment)

@rockerbacon rockerbacon added the bug Something isn't working label Apr 20, 2024
@ghost
Copy link

ghost commented Apr 20, 2024

Why it doesn't use alternative backend when failed is another question...

@rockerbacon
Copy link
Owner

With Wget2 reaching maturity, some distributions are starting to ship it by default. Fedora 40 is one such distribution:
https://fedoraproject.org/wiki/Releases/40/ChangeSet#Wget2_as_wget

The download utility will have to be modified to differentiate between wget and wget2. In the meantime, affected users should force usage of the curl download backend:

DOWNLOAD_BACKEND=curl ./install.sh

@Fesiug
Copy link

Fesiug commented Apr 25, 2024

Hi, I'm on latest Arch Linux. This fixed it for me. Thanks!

@swjzielinski
Copy link
Contributor

For me, it didn't work also. Got stuck on downloading. Then I went into the scripts and was able to isolate the cause of the problem: wget doesn't recognise the option --show-progress. After removing this option, I successfully completed an install.

@SwordsmanJ
Copy link

I'm not sure if this is related to this issue, but the two similar fixes posted here do not correct my issue.
Log when running with variable DOWNLOAD_BACKEND=curl ./install.sh:

DOWNLOAD_BACKEND=curl ./install.sh
INFO: all dependencies met
INFO: selected game 'fallout4'
INFO: found Steam in '/home/jaredr/.local/share/Steam'
INFO: game found in '/home/jaredr/.local/share/Steam'
INFO: steam not found in '/home/jaredr/.var/app/com.valvesoftware.Steam/.local/share/Steam'

(zenity:3455278): Gtk-CRITICAL **: 17:10:38.855: GtkBox 0x55dea2abb590 reports a minimum height of 246, but minimum height for width of 1048576 is 253. Expect overlapping widgets.

(zenity:3455278): Gtk-CRITICAL **: 17:10:38.855: GtkBox 0x55dea2a96410 reports a minimum height of 139, but minimum height for width of 1048576 is 146. Expect overlapping widgets.

(zenity:3455278): Gtk-CRITICAL **: 17:10:38.867: GtkBox 0x55dea2abb590 reports a minimum height of 246, but minimum height for width of 1048576 is 253. Expect overlapping widgets.

(zenity:3455278): Gtk-CRITICAL **: 17:10:38.867: GtkBox 0x55dea2a96410 reports a minimum height of 139, but minimum height for width of 1048576 is 146. Expect overlapping widgets.
INFO: proceeding with existing prefix
INFO: user confirmed prefix setup
INFO: selected install directory '/home/jaredr/Games/mod-organizer-2-fallout4'
INFO: fetching remote resource at 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
INFO: downloading 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip' to '/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
mkdir: cannot create directory ‘/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07’: Permission denied

Log after using recommended fix of editing the download.sh file:

./install.sh
INFO: all dependencies met
INFO: selected game 'fallout4'
INFO: found Steam in '/home/jaredr/.local/share/Steam'
INFO: game found in '/home/jaredr/.local/share/Steam'
INFO: steam not found in '/home/jaredr/.var/app/com.valvesoftware.Steam/.local/share/Steam'

(zenity:3454112): Gtk-CRITICAL **: 17:03:19.490: GtkBox 0x5566ea30d4f0 reports a minimum height of 246, but minimum height for width of 1048576 is 253. Expect overlapping widgets.

(zenity:3454112): Gtk-CRITICAL **: 17:03:19.490: GtkBox 0x5566ea38a1b0 reports a minimum height of 139, but minimum height for width of 1048576 is 146. Expect overlapping widgets.

(zenity:3454112): Gtk-CRITICAL **: 17:03:19.502: GtkBox 0x5566ea30d4f0 reports a minimum height of 246, but minimum height for width of 1048576 is 253. Expect overlapping widgets.

(zenity:3454112): Gtk-CRITICAL **: 17:03:19.502: GtkBox 0x5566ea38a1b0 reports a minimum height of 139, but minimum height for width of 1048576 is 146. Expect overlapping widgets.
INFO: proceeding with existing prefix
INFO: user confirmed prefix setup
INFO: selected install directory '/home/jaredr/Games/mod-organizer-2-fallout4'
INFO: using curl backend
INFO: fetching remote resource at 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
INFO: downloading 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip' to '/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
mkdir: cannot create directory ‘/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07’: Permission denied

This was my first output after making sure I'd had all prerequisites installed and choosing to start with a clean prefix; subsequent to this, I stopped archiving the old prefix to save time because it didn't seem to be causing this error, but please let me know if it actually does.

./install.sh
INFO: all dependencies met
INFO: selected game 'fallout4'
INFO: found Steam in '/home/jaredr/.local/share/Steam'
INFO: steam not found in '/home/jaredr/.var/app/com.valvesoftware.Steam/.local/share/Steam'
INFO: game found in '/home/jaredr/.local/share/Steam'
INFO: user confirmed prefix setup
INFO: selected install directory '/home/jaredr/Games/mod-organizer-2-fallout4'
INFO: using wget backend
INFO: fetching remote resource at 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
INFO: downloading 'https://github.com/adoptium/temurin8-binaries/releases/download/jdk8u312-b07/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip' to '/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07.zip'
mkdir: cannot create directory ‘/tmp/mo2-linux-installer-downloads-cache/OpenJDK8U-jre_x64_windows_hotspot_8u312b07’: Permission denied

@rockerbacon
Copy link
Owner

@SwordsmanJ Completely unrelated. You have a broken /tmp mount. Permissions on /tmp should be 777 so that processes can create temporary files. sudo chmod 777 /tmp should fix it, at least until the next boot.

@SwordsmanJ
Copy link

@SwordsmanJ Completely unrelated. You have a broken /tmp mount. Permissions on /tmp should be 777 so that processes can create temporary files. sudo chmod 777 /tmp should fix it, at least until the next boot.

Thank you for the help, even though it was unrelated. I got the same error again at first after running the suggested command, then deleted the JDK folder in /tmp that had been created originally and it worked. I'll look up how to fix my /tmp mount permanently, but thanks again.

@swjzielinski
Copy link
Contributor

The download utility will have to be modified to differentiate between wget and wget2.

@rockerbacon Would you mind looking at my pull request? I added code to differentiate wget2 from wget 1.x.

@rockerbacon rockerbacon linked a pull request May 4, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants