Lately I've been having some trouble using apt-get using debain 8. when ever I attempt to install packages, I receive the following output...
michael@localhost:~$ sudo apt-get install teksyndicate [sudo] password for michael: Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. michael@localhost:~$
I think this may have been the result of purging packages using apt-get, but this was roughly a month ago when the uni semester ended. As for java being installed, the command java -version retunes the following output...
michael@localhost:~$ java -version java version "1.8.0_51" Java(TM) SE Runtime Environment (build 1.8.0_51-b16) Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode) michael@localhost:~$
michael@localhost:~$ sudo apt-get autoremove [sudo] password for michael: Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. michael@localhost:~$
michael@localhost:~$ sudo apt-get -f install Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it.
michael@localhost:~$ su - Password: root@localhost:~# echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# /etc/apt/sources.list.d/webupd8team-java.list -su: /etc/apt/sources.list.d/webupd8team-java.list: No such file or directory root@localhost:~# echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886 Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --homedir /tmp/tmp.PIwpw6fuZg --no-auto-check-trustdb --trust-model always --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-security-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-stable.gpg --keyring /etc/apt/trusted.gpg.d/lvillani-i3.gpg --keyring /etc/apt/trusted.gpg.d/pipelight-stable.gpg --keyring /etc/apt/trusted.gpg.d/team-xbmc-ppa.gpg --keyring /etc/apt/trusted.gpg.d/webupd8team-java.gpg --keyring /etc/apt/trusted.gpg.d/webupd8team-y-ppa-manager.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886 gpg: requesting key EEA14886 from hkp server keyserver.ubuntu.com gpg: key EEA14886: "Launchpad VLC" not changed gpg: Total number processed: 1 gpg: unchanged: 1 root@localhost:~# apt-get update -- --(UPDATING) -- E: Some index files failed to download. They have been ignored, or old ones used instead. root@localhost:~# sudo apt-get autoremove Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. root@localhost:~# apt-get -f install Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. root@localhost:~# apt-get install teksyndicate Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. root@localhost:~#
I've deleted the folder /usr/java folder (please tell me if there is a safer way) and followed up with the command that thirdmortal recomended. but it doesn't appear that apt is finding java with the PPA gived by Raate.
root@localhost:~# rm -rf /usr/java root@localhost:~# echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# sudo dpkg -r --force-all jdk1.8.0-45 dpkg: warning: ignoring request to remove jdk1.8.0-45 which isn't installed root@localhost:~# apt-get install teksyndicate Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. root@localhost:~#
root@localhost:~# echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# echo "deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main root@localhost:~# apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886 Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --homedir /tmp/tmp.fRedw05DNN --no-auto-check-trustdb --trust-model always --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-security-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-jessie-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-squeeze-stable.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-automatic.gpg --keyring /etc/apt/trusted.gpg.d/debian-archive-wheezy-stable.gpg --keyring /etc/apt/trusted.gpg.d/lvillani-i3.gpg --keyring /etc/apt/trusted.gpg.d/pipelight-stable.gpg --keyring /etc/apt/trusted.gpg.d/team-xbmc-ppa.gpg --keyring /etc/apt/trusted.gpg.d/webupd8team-java.gpg --keyring /etc/apt/trusted.gpg.d/webupd8team-y-ppa-manager.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886 gpg: requesting key EEA14886 from hkp server keyserver.ubuntu.com gpg: key EEA14886: "Launchpad VLC" not changed gpg: Total number processed: 1 gpg: unchanged: 1 root@localhost:~# apt-get update
(UPDATE)
E: Some index files failed to download. They have been ignored, or old ones used instead. root@localhost:~# apt-get install oracle-java8-installer Reading package lists... Done Building dependency tree Reading state information... Done E: The package jre1.8.0-45 needs to be reinstalled, but I can't find an archive for it. root@localhost:~#