树莓派最新raspbian系统换国内源

来源:互联网 发布:室内效果图制作软件 编辑:程序博客网 时间:2024/05/16 16:11

树莓派新版系统更换了专门优化过的桌面环境PIXEL,正好手头有个闲置的TF卡决定刷上新版系统玩玩。下载刷系统过程很多教程页很简单。插卡,上电开机,释放卡上的剩余空间都很正常,因为树莓派官方源访问很慢下一步就是换成国内源,以前一直在用中科大的源,于是开始按照以前的方法修改/etc/apt/sources.list换源。可是换完发现还会从官方源更新,直到找到了/etc/apt/sources.d/raspi.list。

网上教程一般只更换/etc/apt/sources.list里面的源地址,当按照之前的方法更换/etc/apt/sources.d/raspi.list里面的网址之后,发现更新失败了...

直到从网上查找资料之后发现正确的方法:

 

1.修改之前,先备份下配置文件。

 

cp /etc/apt/sources.listcp /etc/apt/sources.d/raspi.list

 


2.
修改/etc/apt/sources.list或者直接修改原文件,把原有的配置全部注释掉(使用#注释)。

#deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib non-free rpi# Uncomment line below then 'apt-get update' to enable 'apt-get source'#deb-src http://archive.raspbian.org/raspbian/ jessie main contrib non-free rpi#科大源deb http://mirrors.ustc.edu.cn/raspbian/raspbian/ jessie main contrib non-free rpi

 

 

3.修改/etc/apt/sources.list.d/raspi.list

#deb http://archive.raspberrypi.org/debian/ jessie main ui# Uncomment line below then 'apt-get update' to enable 'apt-get source'#deb-src http://archive.raspberrypi.org/debian/ jessie main ui#科大源deb http://mirrors.ustc.edu.cn/archive.raspberrypi.org/debian/ jessie main ui

 

实际是将archive.raspberrypi.org替换为mirrors.ustc.edu.cn/archive.raspberrypi.org就可以了。


花了些时间整理了目前最新的树莓派中国大陆地区的软件源,记下来,希望对大家有帮助。

中国科学技术大学
Raspbian http://mirrors.ustc.edu.cn/raspbian/raspbian/

阿里云
Raspbian http://mirrors.aliyun.com/raspbian/raspbian/

清华大学
Raspbian http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/

华中科技大学
Raspbian http://mirrors.hustunique.com/raspbian/raspbian/
Arch Linux ARM http://mirrors.hustunique.com/archlinuxarm/

华南农业大学(华南用户)
Raspbian http://mirrors.scau.edu.cn/raspbian/

大连东软信息学院源(北方用户)
Raspbian http://mirrors.neusoft.edu.cn/raspbian/raspbian/

重庆大学源(中西部用户)
Raspbian http://mirrors.cqu.edu.cn/Raspbian/raspbian/

中山大学 已跳转至中国科学技术大学源
Raspbian http://mirror.sysu.edu.cn/raspbian/raspbian/

新加坡国立大学
Raspbian http://mirror.nus.edu.sg/raspbian/raspbian

牛津大学
Raspbian http://mirror.ox.ac.uk/sites/archive.raspbian.org/archive/raspbian/

韩国KAIST大学
Raspbian http://ftp.kaist.ac.kr/raspbian/raspbian/


原创粉丝点击