Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 08-08-2012, 12:17 AM   #1
LQ Newbie
Registered: Aug 2012
Posts: 1

Rep: Reputation: Disabled
Not able to install jdk in linux ubuntu.

i am getting messages like "404 not found" for some packages when i ran "apt-get update" command.

After that when i am using "install" command msgs coming like
Unable to locate package sun,java6,jdk etc..

Anyone having any idea what i am missing ?
Old 08-08-2012, 02:15 AM   #2
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 55
What distribution and version are you using?
Old 08-08-2012, 02:25 AM   #3
Registered: Jul 2012
Location: Pune, India
Distribution: Ubuntu 9.10
Posts: 193
Blog Entries: 3

Rep: Reputation: 23

To install Java in Ubuntu, use the commands -

#sudo apt-get install openjdk-6-jdk

#sudo apt-get install openjdk-6-jre-headless

I think you are using the package names wrong.


Last edited by kedarp; 08-08-2012 at 02:37 AM.
Old 08-08-2012, 02:29 AM   #4
LQ Guru
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,753

Rep: Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286Reputation: 1286

sounds like your /etc/apt/sources.list needs to be updated. But knowing what to put in there will depend on
(as segfault hints) what version of Ubuntu you are using.

I suspect you may be running an outdated version and as such the repos have moved. If this is the case you'll need to replace all instances of and with
If all this is true, you should probably consider upgrading to a current release.

1 members found this post helpful.


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
LXer: Install Oracle Java (JDK) 7 in Ubuntu via PPA Repository LXer Syndicated Linux News 0 01-18-2012 01:02 AM
LXer: How To Install Oracle Java 7 (JDK) In Ubuntu LXer Syndicated Linux News 0 09-14-2011 09:10 PM
Where to get JDK 1.5.0_08 and JDK 1.6.0_10 for Linux Redhat Itanium servers java_ascii Linux - Software 1 09-22-2009 12:17 PM
How do i install JDK on my ubuntu 8.04 kushal.agarwal Linux - Newbie 8 11-06-2008 12:11 AM
How to install Jdk in linux... Help me :( jolly Linux - General 9 09-13-2001 02:57 PM

All times are GMT -5. The time now is 08:44 PM.

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