Do I need a symlink to make javaws, that is, Java Web Start, work if I have a personalized location for my Java?

I have installed Java as follows:

sudo update-alternatives --install "/usr/bin/java" "java" 
    "/home/user/programs/jdk6u32/bin/java" 1

sudo update-alternatives --install "/usr/bin/javaws" "javaws" 
    "/home/user/programs/jdk6u32/bin/javaws" 1

sudo update-alternatives --config java
sudo update-alternatives --config javaws

sudo ln -s /home/user/programs/jdk6u32/jre/lib/amd64/libnpjp2.so 

The last line is necessary for Firefox to find the Java plug-in. It sets up a symlink. It was due to advice found on stackexchange and I suspect I need something similar for javaws and if so, what would it be?

I am on ubuntu 12.04 (Precise) and Firefox 12.0 and Oracle Java 6 update 32.

  • @Samik, You are right. There are a few choices: download, open with Firefox or open and browse. Opening and browsing to 'javaws' did the trick. Strangely, I never had to browse through the file system with my earlier setups but I think I had Java setup differently before. You should post it as an answer. – H2ONaCl Jun 6 '12 at 18:56
  • Ok, then posting this as an answer. – Samik Jun 6 '12 at 18:59

Whenever you encounter a .jnlp file download, Firefox will present you with the "open-with" dialogue, then you can browse to the location of javaws and open the .jnlp file with it. From next time on, it'll be the default choise remembered by the browser.

  • That's true, but is it necesarry to launch firefox to run JNLP application? But on right click on file javaws is missing in open with other application application list :-( – Betlista Jan 3 '13 at 22:46
  • just open a terminal and type javaws <jnlp file name> – Samik Jan 3 '13 at 22:57
  • I know, but when I can associate it with firefox I would expect, that I can associate it also with javaws... – Betlista Jan 3 '13 at 23:38
  • well, there is a way to associate file-types to application, go to /usr/share/applications/ then edit defaults.list to add the line application/x-java-jnlp-file=javaws.desktop, of course you have to create the .desktop file if that doesn't exist; I use icetea plugin, so mine is icedtea-netx-javaws.desktop but you can custom create a .desktop file with menu editor that points to javaws and kp it in that directory. Then log out and log back in. – Samik Jan 3 '13 at 23:53
  • Thanks for your comments. I used this way - askubuntu.com/questions/235861/… – Betlista Jan 4 '13 at 0:04

After you launch the jnlp before, the mime type is stored into the firefox mimeType.rdf, so you could pike up it from Edit > Preferences > Applications, search "jnlp", then you could associate the javaws (any version of jdk or jre) with it.

  • Works in particular for Webex. – Harald Sep 26 '17 at 15:22

Open Firefox and go to: EditPreferencesApplicationsJava Web Start

Pick the choice you want.

  • Today Java Web Start is not listed anymore, but a search for jnlp works. – Harald Sep 26 '17 at 15:21

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.