Tutorial :No Java for Ubuntu?



Question:

I just installed Ubuntu 10.4 in VMWare Workstation.

When I try to install java, I couldn't find the package:

xxx@ubuntu:~$sudo apt-get install sun-java6-jre  Reading package lists... Done  Building dependency tree  Reading state information... Done  Package sun-java6-jre is not available, but is referred to by another package.  This may mean the package is missing, has been obsoleted, or  is only available from another source  E: Package sun-java6-jre has no installation candidate  

I'm confused.


Solution:1

Ubuntu is supporting OpenJDK-6 on Lucid Lynx (10.04). See the Ubuntu packages for OpenJDK for details. See also:

As someone else mentioned, the Ubuntu/Debian multiverse repositories have additional Java packages; you can enable them by following these instructions:


Solution:2

Thanks. I solved the problem by uncommenting the following lines in /etc/apt/sources.list:

deb http://archive.canonical.com/ubuntu lucid partner  deb-src http://archive.canonical.com/ubuntu lucid partner  


Solution:3

It is in the multiverse repository component, I think.

I can't remember if it is enabled by dafault.

here is info to enable the multiverse for an older version, but it should be similar for 10.04.


Solution:4

You need to enable your universe and multiverse repositories by editing /etc/apt/sources.list

It's not in the default sources list.


Solution:5

Do a search:

apt-cache search java  

See the correct JRE name. This should work.


Solution:6

You could always download and install Java from the Sun / Java website.


Solution:7

Did you update your APT?

sudo apt-get update  


Solution:8

you can use Ubuntu Software Center, to download java and many other Tools/Softwares


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »