There have been issue with the java when running the
firefox in linux. Firstly it is difficult to get java started
in ubuntu and if you need to have specific versions of
firefox and java you are in for some serious work.
What I do is just install firefox required version from
(if my version is older than the current version)
Next I download the java from java.com and use
to properly install the java.
Now that both are installed i need to link them
so create a link in my firefox plugin directory
this is problem with quit a few people as can be seen
from this link.