I just installed a headless Debian on my first that I'v ever built but I can't install any packages on it.

root@media-server:~# apt-get install vim
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package vim 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 'vim' has no installation candidate

I get the same thing with pretty much any package I try to install. I have also already ran apt-get update
Any ideas? Thanks.

Recommended Answers

sudo add-apt-repository ppa:nmi/vim-snapshots
sudo apt-add-repository ppa:passy/vim
sudo apt-get update
sudo apt-get upgrade

There has been somebody who had already one version of Vim, and there was newer one which he/she couldn't find on his/her repository. This solved his/her issue, maybe it could solve yours.

Jump to Post

All 4 Replies

sudo add-apt-repository ppa:nmi/vim-snapshots
sudo apt-add-repository ppa:passy/vim
sudo apt-get update
sudo apt-get upgrade

There has been somebody who had already one version of Vim, and there was newer one which he/she couldn't find on his/her repository. This solved his/her issue, maybe it could solve yours.

root@media-server:~# add-apt-repository ppa:nmi/vim-snapshots
-su: add-apt-repository: command not found
root@media-server:~# apt-add-repository ppa:passy/vim
-su: apt-add-repository: command not found
sudo apt-get install python-software-properties

If this won't work

sudo nano /etc/apt/sources.list

And edit manually :)

Edit it manually to say what. The python thing didn't work.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.