编辑/etc/apt/sources.list文件


root@debian:~# cat /etc/apt/sources.list

# deb cdrom:[Debian GNU/Linux 7 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20131013-23:23]/ wheezy main

#deb cdrom:[Debian GNU/Linux 7 _Wheezy_ - Official Snapshot amd64 LIVE/INSTALL Binary 20131013-23:23]/ wheezy main

deb http://ftp.de.debian.org/debian wheezy main contrib non-free

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

deb http://security.debian.org/ wheezy/updates main

deb-src http://security.debian.org/ wheezy/updates main


执行如下命令就可以用最新的源码包了

apt-get update && apt-get upgrade

aptitude install build-essential

aptitude install linux-headers-$(uname -r)

apt-get install libc6 libc6-dev xorg-dev linux-headers-`uname -r` make

aptitude install module-assistant


同样对于基于debian的开源系统,要想用apt-get源,可以做如下类似操作:

promox配置apt-get源:

#################proxmox ###############

deb http://ftp.debian.org/debian wheezy main contrib


# PVE pvetest repository provided by proxmox.com

deb http://download.proxmox.com/debian wheezy pvetest


# security updates

deb http://security.debian.org/ wheezy/updates main contrib


当然有时候debian修改了文件,但是apt-get源还是不能用,那么这种情况下,就需要查看resolv.conf等域名解析或者网络配置了。