There still isn't any post here in AskUbuntu about how to install the JDownloader 2 yet, so I decided to write this one. I googled a way to, and found one, but I sincerely think that there might be other ways, so I hope that you will share instructions for other ways to install it.
3 Answers
Firstly, get the silent installer script for your system type. For instructions on how to check your system type, read this. Open your terminal by typing Ctrl+Alt+T then type or copy&paste the following command:
- 32-bit OS:
wget http://installer.jdownloader.org/JD2SilentSetup_x86.sh
- 64-bit OS:
wget http://installer.jdownloader.org/JD2SilentSetup_x64.sh
Wait untill the download finishes, then give it executable permission and run it (don't forget to change JD2SilentSetup*.sh to the correct file name):
chmod +x JD2SilentSetup*.sh
./JD2SilentSetup*.sh
It'll bring up the install wizard. Follow the instructions and it will install automatically for you.
Thanks to Ji M for posting instructions on UbuntuHandBook.
Thanks to @MemPrices for letting us know that the necessary Java packages come built in the SH installer, so users don't have to install it beforehand.
- 355
One improvement though, as you pointed out in earlier posts, jDownloader 2 has a Java jre/ folder bundled with it, which size is ~ 147 MB. This is not useful in any Ubuntu distribution. Debian / Ubuntu provides java-7-openjdk packages that will be shared by all applications using Java. You may have installed as well Oracle java 7 or 8 from packages build by webupd8.org Install Oracle Java 8.
OpenJDK can be installed via Ubuntu's package system by running this command:
$ sudo apt-get install openjdk-7-jdk icedtea-7-plugin
Function of each package:
openjdk-7-jdk OpenJDK Development Kit (JDK)
icedtea-7-plugin web browser plugin based on OpenJDK and IcedTea to execute Java applets
These packages are installed in /usr/lib/jvm then you will see folder java-7-openjdk for OpenJDK and java-7-oracle or/and java-8-oracle for Java Oracle. Each of these install do have a jre/ folder.
In addition the Java version used by default in your system should be defined (system wide for all users) in the file /etc/profile e.g. for java-7-openjdk
JAVA_HOME=/usr/local/java/jdk1.7.0_09
PATH=$PATH:$HOME/bin:$JAVA_HOME/bin
JRE_HOME=/usr/local/java/jre1.7.0_09
PATH=$PATH:$HOME/bin:$JRE_HOME/bin
export JAVA_HOME
export JRE_HOME
export PATH
You may have to add or edit it, as the Ubuntu system uses update-alternatives to switch between installed versions of Java. These symbolic links are not per jre/ folder but per executable file i.e. java javac ...
Then you have to edit the Bash launch script jd2/JDownloader2 located in your home folder (echo $HOME in a Terminal), to add the following line as the first line of code below the comments ending #INSTALL4J_ADD_VM_PARAMS=
INSTALL4J_JAVA_HOME_OVERRIDE="$JAVA_JRE"
Or if you didn't define the jre/ folder
INSTALL4J_JAVA_HOME_OVERRIDE="$JAVA_HOME"/jre
Afterwards you can remove the bundled jd2/jre folder. That would save you ~ 147 MB and have your Java JRE managed by the Ubuntu system.
- 355
- 1,656