3

I run a server with Ubuntu 10.04 (Lucid Lynx) Minimal Server, on amd64 system. I 'd like to install the openjdk packages (jre and jdk), but when I try

sudo apt-get install openjdk-6-jdk

I get

Package openjdk-6-jdk is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package openjdk-6-jdk has no installation candidate

And I 'd like to install this package andI don't know how, while it seems to be available here

4
  • 1
    (1) Do you have lucid main in your sources.list? Run cat /etc/apt/sources.list and provide the output in your question. (2) What do you mean by "minimal" server? Did you use the official server image (ubuntu-10.04*-server-*.iso) from releases.ubuntu.com/lucid ? Feb 27 '12 at 16:15
  • Did you try a sudo apt-get update after changing your software mirrors? Feb 27 '12 at 16:16
  • Ok I tried apt-get clean and apt-get update and it worked. Thank you very much :-)
    – Paris
    Feb 27 '12 at 17:23
  • @bodhi.zazen Done :) Feb 28 '12 at 3:42
4

Please try a sudo apt-get clean && sudo apt-get update after changing your software mirrors :)

1

Open a terminal and try these commands:

sudo add-apt-repository ppa:openjdk-r/ppa  
sudo apt-get update   
sudo apt-get install openjdk-6-jre 
0

the error says "the package ....or is only available from another source"

Check your sources.list, see if it contains a non-standard ubuntu server.

0

Oracle has stop providing oracle 6 and 7 jdk. And to install older version, need to use offline installation method.

First download oracle-jdk7-installer.tar.gz and oracle-java7-installer_7u80+7u60arm-0~webupd8~1_all.deb

cp -r oracle-jdk7-installer.tar.gz oracle-java7-installer_7u80+7u60arm-0~webupd8~1_all.deb /var/cache/
cd /var/cache
tar -xvf oracle-jdk7-installer.tar.gz
dpkg -i oracle-java7-installer_7u80+7u60arm-0~webupd8~1_all.deb

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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