不少vps的救援系统使用的都是debian9, 但是这货早就停止支持了,默认的源也没了,导致无法安装任何软件. 现记录一下更新源的方法. 替换为 代码: deb http://archive.debian.org/debian stretch main deb-src http://archive.debian.org/debian stretch main deb http://archive.debian.org/debian-security stretch/updates main deb [arch=amd64] https://download.docker.com/linux/debian stretch stable deb-src http://archive.debian.org/debian-security stretch/updates main deb http://archive.debian.org/debian/ stretch main contrib non-free deb http://archive.debian.org/debian/ stretch-proposed-updates main contrib non-free deb http://archive.debian.org/debian-security stretch/updates main contrib non-free 再
如果vi 编辑器无法使用,可以使用echo命名 先 代码: echo 'deb http://archive.debian.org/debian stretch main' >>sources.list echo 'deb-src http://archive.debian.org/debian stretch main' >>sources.list echo 'deb http://archive.debian.org/debian-security stretch/updates main' >>sources.list echo 'deb [arch=amd64] https://download.docker.com/linux/debian stretch stable' >>sources.list echo 'deb-src http://archive.debian.org/debian-security stretch/updates main' >>sources.list echo 'deb http://archive.debian.org/debian/ stretch main contrib non-free' >>sources.list echo 'deb http://archive.debian.org/debian/ stretch-proposed-updates main contrib non-free' >>sources.list echo 'deb http://archive.debian.org/debian-security stretch/updates main contrib non-free' >>sources.list