首页 > 系统相关 >ubuntu换源

ubuntu换源

时间:2023-01-05 16:55:54浏览次数:47  
标签:mirrors restricted ubuntu 换源 universe main focal

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

在文件中添加国内源然后sudo apt-get update就ok了。

常用国内源:

阿里云源

deb http://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse

清华源

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse

# 预发布软件源,不建议启用
# deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse

中科大源

deb https://mirrors.ustc.edu.cn/ubuntu/ focal main restricted universe multiverse
deb-src https://mirrors.ustc.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.ustc.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb-src https://mirrors.ustc.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.ustc.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb-src https://mirrors.ustc.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.ustc.edu.cn/ubuntu/ focal-security main restricted universe multiverse
deb-src https://mirrors.ustc.edu.cn/ubuntu/ focal-security main restricted universe multiverse
deb https://mirrors.ustc.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse
deb-src https://mirrors.ustc.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse

网易163源

deb http://mirrors.163.com/ubuntu/ focal main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ focal-security main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ focal-updates main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ focal-proposed main restricted universe multiverse
deb http://mirrors.163.com/ubuntu/ focal-backports main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ focal main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ focal-security main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ focal-updates main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ focal-proposed main restricted universe multiverse
deb-src http://mirrors.163.com/ubuntu/ focal-backports main restricted universe multiverse

标签:mirrors,restricted,ubuntu,换源,universe,main,focal
From: https://www.cnblogs.com/hei-dashuai/p/17028068.html

相关文章

  • 基于Linux下的Ubuntu操作系统常用命令
    一 .linux操作系统的特点1、linux下一切皆文件2、linux系统就像一个倒置数3、linux系统支持多用户、多任务二.Ubuntu--“乌班图”操作系统Ubuntu是一个以桌面应......
  • ubuntu下docker及打deb包
    Bash函数-BashShell教程#文件测试-e文件存在-a文件存在这个选项的效果与-e相同.但是它已经被弃用了,并且不鼓励使用-ffile是一个regular文件(不是目录或者设备文......
  • ubuntu下搭建git服务器
    1、安装gitaptinstallgitaptinstallopenssh-server2、安装​​gitolite​​​​https://github.com/sitaramc/gitolite​​Installationandsetupserverrequirementsa......
  • composer 换源
    #首先把默认的源给禁用掉composerconfig-gsecure-http false#再修改镜像源这里我使用阿里的源composerconfig-grepo.packagistcomposerhttps://mirrors.aliyu......
  • Arch Manjaro 的清华aur源,yay换源避坑
    清华AUR源关了,不能用了,望大家周知鉴于网上那么多全是让换清华源的过时博客还是换回官方源吧。yay--aururl"https://aur.archlinux.org"--save......
  • npm换源
    npm换源淘宝npm源6月底下线现在换成新的sudonpminstall-gnrmnrmaddaliyunhttps://registry.npmmirror.comnrmusealiyun......
  • Ubuntu 22.10 解决按照官方教程无法使用搜狗输入法
    按照官方教程安装搜狗输入法后依然无法使用在/etc/environment文件中添加GTK_IM_MODULE=fcitxQT_IM_MODULE=fcitxXMODIFIERS=@im=fcitx注销后即可使用......
  • Ubuntu终端cmdline输入单行长文本消息的限制
    Linux-Ubuntuterminal输入单行长文本消息的限制4096我真的很无语好吧orz在做socket编程的时候,要求传长文本消息,20KB这样的。就是如果单行文本消息很长比如说20480B=20K......
  • ubuntu下安装mysql + qt编译mysql插件
    sudoapt-getinstallmysql-serverapt-getisntallmysql-clientsudoapt-getinstalllibmysqlclient-dev安装成功后可以看一下有没有进程在监听sudonetstat-tap......
  • 【神医华佗】Ubuntu空间爆满?cupsd惹的祸!!!
    病情描述打开Ubuntu准备工作,结果黑屏,等了一会(几分钟),通过ssh连上,使用df-h查看磁盘占用,发现/var目录空间被占满了,上图:病情分析先top查看资源占用,如下图所示:这不,病灶找......