Unable to locate package oracle-java7-installer [Ubuntu 13]
Was installing Java today, this is an easy install thanks to “
ppa:webupd8team/java
“, but when I tried it was not working, but has worked for me all this while.
Little goggling around found me a solution. Here is full conversation if you wanted to have a look
http://ubuntuforums.org/showthread.php?t=2048793
Installing JAVA on Ubuntu is simple. Do the below to add the repository and run the below command ‘sudo apt-get install oracle-java7-installer’ to install.
Error.
ahmed@ubuntu:~$ sudo add-apt-repository ppa:webupd8team/java
ahmed@ubuntu:~$ sudo apt-get update
ahmed@ubuntu:~$ sudo apt-get install oracle-java7-installer
ahmed@ubuntu:~$ sudo apt-get install oracle-java7-installer
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package oracle-java7-installer
Solution.
Elevating to
root
. ahmed@ubuntu:~$ sudo su
Adding to
deb
. root@ubuntu:~# echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu precise main" > /etc/apt/sources.list.d/webupd8team-java.list
Adding to
deb-src
root@ubuntu:~# echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu precise main" >> /etc/apt/sources.list.d/webupd8team-java.list
Making sure we have the key as well.
root@ubuntu:~# apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886
Lets
update
our apt-get
repository. root@ubuntu:~# apt-get update
Now Install Oracle Java
root@ubuntu:~# apt-get install oracle-java7-installer
<..loads of verbose...>
root@ubuntu:~# exit
Checking Version
ahmed@ubuntu:~$
ahmed@ubuntu:~$ java -version
java version "1.7.0_60"
Java(TM) SE Runtime Environment (build 1.7.0_60-b19)
Java HotSpot(TM) 64-Bit Server VM (build 24.60-b09, mixed mode)
ahmed@ubuntu:~$
All done. !!!
Can you explain me, how did this work?
ReplyDeleteI just update / adding the new package to repos.
ReplyDeleteAnd added a key to keyserver that it.. :)
Below are the things we need to do to make it work.
1. sudo su
2. echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu precise main" > /etc/apt/sources.list.d/webupd8team-java.list
3. echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu precise main" >> /etc/apt/sources.list.d/webupd8team-java.list
4. apt-key adv --keyserver keyserver.ubuntu.com --recv-keys EEA14886
Hope that helps.
not work for me
ReplyDeletenot work for me
ReplyDeleteApply Now for Distance/Regular Learning through tablet specially designed for learn ethical hacking, Android app development,
ReplyDeletesoftware development, security engineer, forensic investigator,For more information visitClick Here
ReplyDeleteThank you for sharing your awesome and valuable article this is the best blog for the students they can also learn.
DevOps Training in Chennai | DevOps Training in anna nagar | DevOps Training in omr | DevOps Training in porur | DevOps Training in tambaram | DevOps Training in velachery
Very nice article post,Thank you for sharing this awesome blog.
ReplyDeletekeep updating more big data hadoop tutorials.
Big Data Online Course
Thanks for sharing this articles
ReplyDeleteformularios de divorcio no disputados de virginia
Divorcio rapido no disputado en Virginia