Sign up ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

This question already has an answer here:

I've installed the small image of Debian Wheezy from here but had to skip the mirror install of the extra packages.

Now that I have the command line how do I get the rest of the stuff?

When I tried apt-get install ssh-server, it told me to insert the CD.

share|improve this question

marked as duplicate by Anthon, Zelda, slm, casey, Timo Mar 13 '14 at 15:19

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

one search first result on google… – Kiwy Mar 13 '14 at 12:10
In the answers, is used as an mirror, I recommend which chooses automatically the best mirrors. See for more information. – jofel Mar 13 '14 at 12:25

3 Answers 3

You need to add the internet repositories, and remove the cdrom's ones, as root:

sed -i 's/deb\ cdrom/#deb cdrom/' /etc/apt/sources.list
sh -c "echo ' $(lsb_release -sc) main contrib' >> /etc/apt/sources.list"
## The following only for non-free repository
sh -c "echo ' $(lsb_release -sc) non-free' >> /etc/apt/sources.list"
apt-get update

Then install the package you need. There's also the -security and -update repository you can add. If you don't have sudo you can use su.

share|improve this answer
sudo is not installed by default on debian. – casey Mar 13 '14 at 13:06

Edit the repositories file:

sudo nano /etc/apt/sources.list

Remove all and add this lines:

deb stable main contrib non-free
deb wheezy-updates main contrib non-free
deb wheezy/updates main contrib non-free


sudo apt-get update
apt-get install ssh-server
share|improve this answer

Edit /etc/apt/sources.list, comment out the line referring to the CD, and add these lines (or make sure they're uncommented):

deb wheezy main contrib non-free
deb-src wheezy main contrib non-free

deb wheezy/updates main contrib non-free
deb-src wheezy/updates main contrib non-free

Then do a apt-get update and try again.

If the US site is slow for you, you can substitute a mirror that's closer to you.

share|improve this answer

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