2

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.

2
  • one search first result on google ortuno2k.wordpress.com/2011/03/14/… – Kiwy Mar 13 '14 at 12:10
  • In the answers, ftp.us.debian.org is used as an mirror, I recommend http.debian.net which chooses automatically the best mirrors. See http.debian.net for more information. – jofel Mar 13 '14 at 12:25
5

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 'http://ftp.us.debian.org/debian $(lsb_release -sc) main contrib' >> /etc/apt/sources.list"
## The following only for non-free repository
sh -c "echo 'http://ftp.us.debian.org/debian $(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.

1
  • 1
    sudo is not installed by default on debian. – casey Mar 13 '14 at 13:06
4

Edit the repositories file:

sudo nano /etc/apt/sources.list

Remove all and add this lines:

deb http://ftp.us.debian.org/debian stable main contrib non-free
deb http://ftp.debian.org/debian/ wheezy-updates main contrib non-free
deb http://security.debian.org/ wheezy/updates main contrib non-free

Execute:

sudo apt-get update
apt-get install ssh-server
3

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

deb http://http.us.debian.org/debian/ wheezy main contrib non-free
deb-src http://http.us.debian.org/debian/ wheezy main contrib non-free

deb http://security.debian.org/ wheezy/updates main contrib non-free
deb-src http://security.debian.org/ 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.

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