Ubuntu 更新源方法[通俗易懂]

Ubuntu 更新源方法[通俗易懂]阿里源:https://opsx.alibaba.com/mirrordebhttp://mirrors.aliyun.com/ubuntu/bionicmainrestricteduniversemultiversedeb-srchttp://mirrors.aliyun.com/ubuntu/bionicmainrestricteduniversemultiver…

大家好,又见面了,我是你们的朋友全栈君。

安装完Ubuntu系统之后,面临的最主要的一个问题就是将apt安装源进行更新,因为在国内直接利用Ubuntu默认的安装源下载安装包速度慢,并且有的时候软件版本也比较旧。今天小编对Ubuntu更新源进行介绍:(这里针对阿里源和清华源进行说明,具体源在第二部分)

第一:具体操作

  1. 复制阿里或者清华源

  2. 备份系统自带的源
    命令如下:

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

在这里插入图片描述
3. 打开/etc/apt/sources.list文件,将原来的内容删除,然后将上述复制的内容,粘贴上,保存。
这里用的是vim 进行操作,命令如下

sudo vi /etc/apt/sources.list

在这里插入图片描述
在这里插入图片描述
4. 更新,输入命令sudo apt-get update进行更新
在这里插入图片描述

当更新完成后会有如下显示:
在这里插入图片描述

第二: 首先是两个源的地址,以及源:

  1. 阿里源 :
    地址: https://opsx.alibaba.com/mirror
    源:

    deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

    deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

    deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

    deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

    deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

  2. 清华源 :
    地址:https://mirrors.tuna.tsinghua.edu.cn/help/ubuntu/

    源:
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse
    deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse
    # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse

大家可以用微信扫描下方的二维码,关注一下,大家一起讨论,学习。
在这里插入图片描述

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/146548.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • 【入门Ubuntu】Ubuntu 20.4 LTS 开荒之 Edge浏览器

    【入门Ubuntu】Ubuntu 20.4 LTS 开荒之 Edge浏览器因为大三开始跟着实验室老师入门计算机视觉领域科研工作,本人研究方向为目标检测,发现更多代码或者环境都是在Linux下更加“合法”,但是大二的时候Linux上课又滑水了(泪目),造孽啊…所以在此留下关于Ubuntu的入门指南,希望对后来人有所帮助,因为额关于我在一块电脑上的两个系统我本身也是win10的操作系统,然后有下载过虚拟机,但是昨天突发奇想,自己手上有两块空着的2T的移动硬盘,所以就拿其中一块作了Ubuntu的“家”,昨晚刚完成的,…

    2022年7月21日
    15
  • 【16】进大厂必须掌握的面试题-100个python面试

    点击上方“全栈程序员社区”,星标公众号 重磅干货,第一时间送达 我们整理了Python面试的主要问题清单,分为7个部分: 基本面试问题 OOPS面试问题 基本的Python程序 P…

    2021年6月23日
    139
  • PHPStorm2017去掉函数参数提示

    PHPStorm2017去掉函数参数提示

    2022年2月8日
    138
  • intellj 激活码2021(最新序列号破解)

    intellj 激活码2021(最新序列号破解),https://javaforall.net/100143.html。详细ieda激活码不妨到全栈程序员必看教程网一起来了解一下吧!

    2022年3月18日
    105
  • singleTop和singleTask有什么区别

    singleTop和singleTask有什么区别文章来源:http://blog.csdn.net/leon8/article/details/6844397singleTop要求如果创建intent的时候栈顶已经有要创建的Activity的实例,则将intent发送给该实例,而不发送给新的实例。(注意是栈顶,不在栈顶照样创建新实例!)singleTask模式:当intent到来,需要创建singleTask模式

    2022年6月26日
    42
  • 微信小程序:mpvue+flyio「建议收藏」

    微信小程序:mpvue+flyio「建议收藏」微信小程序:mpvue+flyiompvue项目创建1、全局安装vue-clinpminstall–globalvue-cli2、创建一个基于mpvue-quickstart模板的新项目vueinitmpvue/mpvue-quickstartmy-project//这是vue旧版本创建项目方法,如果init报错需要运行vueinit,创建项目过程中跟着命令行…

    2022年9月8日
    0

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号