Results 1 to 10 of 10

Thread: Installing Sun Java and openSUSE 11.1

  1. #1

    Default Installing Sun Java and openSUSE 11.1

    I am having problems with getting Firefox to switch over to using Sun's version of Java, which I need for certain websites as the default OpenJDK/IcedTea plug-in combo doesn't seem to work.

    By default, openSUSE 11.1 installs:

    java-1_5_0-gcj-compat
    java-1_6_0-openjdk
    java-1_6_0-openjdk-plugin

    which leads

    # update-alternatives --config java

    to output:

    There are 2 alternatives which provide `java'.

    Selection Alternative
    -----------------------------------------------
    *+ 1 /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
    2 /usr/lib/jvm/jre-1.5.0-gcj/bin/java


    At this point, Firefox 3.0.14 uses OpenJDK 6 with IcedTea 6 to run java apps in the browser. I get these errors when I try to access a particular java app:

    -----

    java version "1.6.0_0"
    OpenJDK Runtime Environment (IcedTea6 1.6) (suse-0.1.3-i386)
    OpenJDK Client VM (build 14.0-b16, mixed mode)
    Calling plugin_get_documentbase
    java.lang.RuntimeException: Failed to handle message: GetJavaObject for instance 1 Thread[Thread-3,5,main]
    at sun.applet.PluginAppletViewer.handleMessage(PluginAppletViewer.java:533)
    at sun.applet.PluginStreamHandler.handleMessage(PluginStreamHandler.java:295)
    at sun.applet.PluginMessageHandlerWorker.run(PluginMessageHandlerWorker.java:72)
    Caused by: java.lang.NullPointerException
    at sun.applet.PluginAppletViewer.handleMessage(PluginAppletViewer.java:592)
    at sun.applet.PluginAppletViewer.handleMessage(PluginAppletViewer.java:525)
    ... 2 more
    Connection failure: Connection refused
    Error: Unable to fetch applet instance id from Java side.
    IcedTeaNPPlugin.cc:635: thread 0x8065800: Error: Unknown plugin value requested.

    -----

    So I started looking around for solutions... From what I read, I installed:

    java-1_6_0-sun
    java-1_6_0-sun-plugin

    in hopes that things would auto-magically work. It didn't, unfortunately. So I used:

    # update-alternatives --config java

    There are 3 alternatives which provide `java'.

    Selection Alternative
    -----------------------------------------------
    + 1 /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
    2 /usr/lib/jvm/jre-1.5.0-gcj/bin/java
    * 3 /usr/lib/jvm/jre-1.6.0-sun/bin/java

    Press enter to keep the default[*], or type selection number:

    to set 3 as the default (note the location of the *). This didn't seem to change anything either. OpenJDK/IcedTea were still active from Firefox.

    I made this link:

    cd /usr/lib/browser-plugins
    ln -s /etc/alternatives/jre_sun/plugin/i386/ns7/libjavaplugin_oji.so .

    Now, within Firefox Edit->Preferences->Main->Add-ons->Plug-ins, I have both IcedTea and Java(TM) Plug-in 1.6.0_15-b03, whereas before it was just IcedTea.

    IcedTea is clicked such that the plug-in button says Enable (which means it is currently disabled)
    Java(TM) is clicked such that the plug-in button says Disable (which means it is currently enabled)

    I'm still getting the situation where Firefox wants to use the OpenSDK and IcedTea plug-in over Sun's Java(TM).

    Any thoughts? Also, how should this work? Do I need to uninstall things I don't want for things to work? (Then why have Enable/Disable buttons?)

    Thanks!

  2. #2
    Join Date
    Aug 2009
    Location
    Wellington, NZ
    Posts
    110

    Default Re: Installing Sun Java and openSUSE 11.1

    Can't answer the "why have enable/disable" question, but to get Java working cleanly, remove all installed Java versions (i.e. uninstall) and then install only the latest Sun Java (1.5.x from memory - sorry not at a Suse desktop right now !)

    IG

  3. #3

    Default Re: Installing Sun Java and openSUSE 11.1

    ignz: I did as you suggested and uninstalled all the other java packages:

    java-1_5_0-gcj-compat
    java-1_6_0-openjdk
    java-1_6_0-openjdk-plugin

    When I went into Firefox's settings, Edit->Preferences->Main->Add-ons->Plug-ins, the OpenJDK/IcedTea combo disappeared and I was left with two options for java, one of which was from the link I created in /usr/lib/browser-plugins. I removed the link and only one choice was left in Firefox for java plug-ins. I Enabled it.

    The particular java apps that weren't working are working now!

    Thank you!

  4. #4
    Join Date
    Jun 2008
    Location
    The English Lake District. UK - GMT/BST
    Posts
    36,857
    Blog Entries
    20

    Default Re: Installing Sun Java and openSUSE 11.1

    You want it like this
    Tumbleweed_KDE
    My Articles Was I any help? If yes: Click the star below

  5. #5
    Join Date
    Aug 2010
    Location
    Anarcoworld
    Posts
    2

    Default Re: Installing Sun Java and openSUSE 11.1

    In my opensuse 11.3, some pages cannot be loaded and appears a java error with icedteanpplugin.
    then i install the
    java-1_6_0-sun
    java-1_6_0-sun-plugin
    and it solved the problem.

  6. #6
    Join Date
    Aug 2010
    Location
    Anarcoworld
    Posts
    2

    Default Re: Installing Sun Java and openSUSE 11.1

    In my opensuse 11.3, some pages cannot be loaded and appears a java error with icedteanpplugin.
    then i install the
    java-1_6_0-sun
    java-1_6_0-sun-plugin
    and it solved the problem. but only works in chromium

  7. #7
    Join Date
    Nov 2009
    Location
    West Virginia Sector 13
    Posts
    16,288

    Default Re: Installing Sun Java and openSUSE 11.1

    Uninstall icedtea if you are using real java

  8. #8

    Default Re: Installing Sun Java and openSUSE 11.1

    I was able to get JAVA working by completing following steps ...

    First remove all installed java packages ...

    check what is installed by rpm -qa

    rpm -qa | grep java-1

    this returned me for example java-1_5_0-gcj-compat-1.5.0.0-114.1.i586

    so I removed this package using rpm -e --nodeps and all other packages except timezone-java-2010l-0.3.1.noarch

    rpm -e --nodeps java-1_5_0-gcj-compat-1.5.0.0-114.1.i586


    then download package from java.com -> in my case jre-6u24-linux-i586.rpm.bin

    as root create /usr/java, copy jre-6u24-linux-i586.rpm.bin to /usr/java

    in /usr/java proceed with

    chmod a+x jre-6u24-linux-i586.rpm.bin

    ./jre-6u24-linux-i586.rpm.bin


    this will install new java to /usr/java/jre1.6.0.24 directory

    then create a link libnpjp2.so in firefox plugin directory (in my case for OpenSuse 11.3) this was

    ln -s /usr/java/jre1.6.0_24/lib/i386/libnpjp2.so /usr/lib/browser-plugins/libnpjp2.so


    then I also also had to disabled IcedTea firefox plugin as it caused some JAVA applications didt start properly in the firefox browser ... in /usr/lib/browser-plugins I simply renamed the file to *.bckp extension

    mv /usr/lib/browser-plugins/npwrapper.javaplugin.so /usr/lib/browser-plugins/npwrapper.javaplugin.so.bckp


    to check which version is your firefox using start it and go to "aboutlugins" page

    good luck ...

  9. #9
    Join Date
    Jun 2008
    Location
    Phoenix, AZ, US
    Posts
    188

    Default Re: Installing Sun Java and openSUSE 11.1

    Thanks for the instructions . I could not for the life of me remember where to set the links for the browser plugins. I had to re-install Java 23 after the update 24 messed up several programs I need for working at home.

    Are there any differences between 32 and 64 bit for this to work? I'm running 11.3 x64-bit.
    Go for it! You can always re-install...

    Registered Linux User #452291

    Windows Vista Boot Error: (S)hout, (P)arty, (D)ance, (L)inux? (L/L)?

  10. #10
    Join Date
    Jun 2008
    Location
    Earth - Denmark
    Posts
    10,730

    Default Re: Installing Sun Java and openSUSE 11.1

    have you noticed that openSUSE 11.1 has met end of life and is no
    longer supported, unless you follow the Evergreen path:
    http://en.opensuse.org/Evergreen

    --
    DenverD
    CAVEAT: http://is.gd/bpoMD
    [NNTP posted w/openSUSE 11.3, KDE4.5.5, Thunderbird3.0.11, nVidia
    173.14.28 3D, Athlon 64 3000+]
    "It is far easier to read, understand and follow the instructions than
    to undo the problems caused by not." DD 23 Jan 11

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •