LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices



Reply
 
Search this Thread
Old 08-10-2010, 04:03 PM   #1
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,028
Blog Entries: 5

Rep: Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791
Getting Java plugin to work on CentOS 5 Linux with Firefox 3.6.x


Just posting this because it was such a bear to find the right answer as so many sites had the wrong one. I'm hoping it might help someone else.

Over the weekend I wanted to install the Java plugin on my Firefox 3.6.8 (as installed directly from Mozilla Firefox download). I followed the instructions at the link below from Java's site:
http://www.java.com/en/download/help/linux_install.xml
Which unfortunately were wrong regarding the file to link.
They incorrectly show creating a link under the firefox/plugins directory with:

ln -s <JRE>/plugin/i386/ns7/libjavaplugin_oji.so
On CentOS5 after installing the
ln -s /usr/java/jre1.6.0/plugin/i386/ns7/libjavaplugin_oji.so

I also found that or variations on it in other web pages at Mozilla and around the web.

I finally found the correct file to link in this page:
http://www.oracle.com/technetwork/ja...ux-136395.html
It shows that instead of the above:
ln -s <JRE>/lib/i386/libnpjp2.so .
On CentOS5 that was:
ln -s /usr/java/jre1.6.0/plugin/i386/libnpjp2.so .
It even notes at the bottom:
Quote:
Notes
* The classic plugin file was located here:

<JRE>/plugin/i386/javaplugin-oji.so

This file should no longer be used and all symbolic links to it removed.
Other notes from me:
1) You first have to download and install the file from Java's site: jre-6u21-linux-i586-rpm.bin - There is also a non-rpm version if you're not using an rpm based distro.
2) Only JRE 6 update 10 or higher works with Firefox 3.6 or higher. (above is update 21).
3) This worked both with the Firefox 3.6.8 I had installed previously from Firefox download and with the Firefox 3.6.7 rpm installed using yum update with CentOS (the latter comes from the Fedora repository).

Last edited by MensaWater; 08-11-2010 at 09:56 AM.
 
Old 08-12-2010, 01:19 AM   #2
EricTRA
Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291Reputation: 1291
Hi,

Thank you for sharing this.

Kind regards,

Eric
 
Old 08-12-2010, 04:58 PM   #3
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,028
Blog Entries: 5

Original Poster
Rep: Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791
Solved also: Java plugin works for root but not for normal user

As a follow up:

My earlier post did in fact get the Java plugin working for root. However even though the plugin was showing up for my normal (non-root) user account after I did the above it wasn't actually loading java.

I found I had to move my $HOME/.java and $HOME/.mozilla directories out of the way for normal user and let it recreate them when I opened the browser. Prior to doing this however one should backup bookmarks (under Firefox' Bookmarks-->Organize Bookmarks option).

After you do it and pull up Firefox as the normal user you can restore the backed up bookmarks.

Also this loses any Firefox addons (e.g. WOT, AdBlockPlus, Java NoScript) you have for that user so you need to reinstall those after you restart firefox as the normal user. (Note these are addons not plugins - plugins should be OK so long as they are linked in the main firefox/plugins directory as mentioned in my earlier post for Java plugin.)

Last edited by MensaWater; 08-17-2010 at 03:00 PM.
 
Old 08-23-2010, 06:20 PM   #4
hcgrant
Member
 
Registered: Feb 2004
Location: UK Hertfordshire
Distribution: Opensuse 12.2 plus Macs and a Vista and two little RaspberryPi
Posts: 44

Rep: Reputation: 15
Thumbs up

Many many thanks!!!! Ive been messing around off and on for weeks trying to get Java working in Firefox... Kept thinking Id messed up somewhere .
Im using Opensuse 11.1 64 bit btw

PS I didnt have to do the things you mention above .. I just put a symlink into the Firefox plugins directory pointing to libnpjp2.so as normal user.

Last edited by hcgrant; 08-23-2010 at 06:25 PM.
 
Old 09-10-2010, 11:00 PM   #5
buzzybeemarketing
LQ Newbie
 
Registered: Jul 2010
Posts: 12

Rep: Reputation: 0
Firefox Java Runetime Plugin on centOS 5.5

Here are some tips. By the way, you guys have really helped. What a mess that you have to clean up totally incorrect instructions posted by Sun Java.

1. I was placing the symbolic link to libjavaplugin_oji.so in /usr/lib/mozilla/plugins. Well that's not the correct place. You have to create a plugins directory under (/usr/lib/firefox-3.6/), on my system.

2. Also, I originally installed java with rpm -Uvh jdk-1.6.0_20-fcs.i586.rpm a full all in one package. I had to go back and install update 21 just for the runtime. Then I had to recreate the proper symbolic link to the new runtime update 21.

3. Also, make sure to use the Verify Now link at http://www.java.com/en/download/installed.jsp I was using some other test link that is useless when you don't have java installed yet. At least the first link will give you a firefox missing plugin alert. The other test java site link will not. Don't use java.com/en/downloads/help/testvm.xml That link is useless at first.
 
Old 04-14-2011, 08:59 PM   #6
bustoutfunk
LQ Newbie
 
Registered: Mar 2011
Posts: 2

Rep: Reputation: 0
Smile For the super linux impaired...

I am really new to Linux so I thought it would help to put really easy directions (even though it might be redundant).

I performed the following commands:

$ cd /usr/lib/mozilla/plugins
$ sudo ln -s /usr/java/jre1.6.0_24/lib/i386/libnpjp2.so

Thanks for the posts. This problem has been driving me mad for weeks!

Last edited by bustoutfunk; 04-14-2011 at 08:59 PM. Reason: type-o
 
Old 02-17-2012, 12:23 PM   #7
clcbluemont
Member
 
Registered: Feb 2009
Distribution: Slackware
Posts: 95

Rep: Reputation: 15
For 64 bit systems
cd /usr/lib64/mozilla/plugins
ln -fs <JRE>/lib/amd64/libnpjp2.so
 
Old 02-27-2012, 09:50 PM   #8
donnieblaw
LQ Newbie
 
Registered: Feb 2012
Posts: 1

Rep: Reputation: Disabled
I read through all these posts and tried all kinds of symbolic links, but couldn't find any joy. I finally discovered that not all Firefoxes work with all Javas.

To get Java working on Centos 5.5, here's my recipe:

Download and install firefox 10.0. I installed in /usr/local.
Download and install JDK 6u31 (you can just use the jre if you want). I cd to /usr/local before running the self-extracting binary, so it will extract there. If you scroll down on http://www.oracle.com/technetwork/ja...ads/index.html you'll find 6u31.

Verify that the plugin is available:
ls /usr/local/jdk1.6.0_31/jre/lib/i386/libnpjp2.so

Then:

cd
cd .mozilla
mkdir -p plugins
ln -s /usr/local/jdk1.6.0_31/jre/lib/i386/libnpjp2.so .

(You have to type a space then a period at the end of the ln command.)
Then restart FF, and you should see Java when you enter the URL
Code:
about:plugins

Last edited by donnieblaw; 02-27-2012 at 10:06 PM. Reason: my bad
 
  


Reply

Tags
centos5, firefox, java, plugin


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Firefox 3.0.1 java plugin links don't work bluethumb Linux - Software 2 09-11-2008 05:13 PM
Java runtime enviroment plugin won't work with firefox in xubuntu Akashe Linux - Newbie 2 01-28-2008 03:59 PM
Java plugin for firefox does not work ferao Mandriva 9 05-10-2007 06:37 PM
Cannot get java plugin to work with firefox mike_savoie Ubuntu 5 09-13-2006 06:12 PM
Java plugin for Firefox on mandrake linux help ewualum98 Linux - Newbie 4 06-07-2004 11:05 AM


All times are GMT -5. The time now is 11:56 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration