个人Linux(ubuntu)使用记录——更换软件源

说明:记录自己的linux使用过程,并不打算把它当作一个教程,仅仅只是记录下自己使用过程中的一些命令,配置等东西,这样方便自己查阅,也就不用到处去网上搜索了,所以文章毫无章法可言,甚至会记录得很乱

step1:

备份当前源

sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup

 step2:

进入网址  https://mirror.tuna.tsinghua.edu.cn/help/ubuntu/

 选择自己对应的linux版本,复制软件源

step3:

修改软件源文件为刚刚复制的内容(简单会使用vim编辑器即可)

sudo vi /etc/apt/sources.list

step4:

更新源

sudo apt-get update 

 step5:

更新软件

sudo apt-get dist-upgrade
sudo apt-get upgrade

 step6:

修复安装命令

sudo apt-get -f install

  

 

原文地址:https://www.cnblogs.com/418ks/p/10703636.html