zoukankan      html  css  js  c++  java
  • 修改 Ubuntu的源为阿里源

    安装Ubuntu 18.04后,使用国外源太慢了,修改为国内源会快很多。

    修改阿里源为Ubuntu 18.04默认的源

    备份/etc/apt/sources.list
    #备份
    cp /etc/apt/sources.list /etc/apt/sources.list.bak

    在/etc/apt/sources.list文件前面添加如下条目
    #添加阿里源
    deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
    deb 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 main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

    最后执行如下命令更新源
    ##更新
    sudo apt-get update
    sudo apt-get upgrade

    apt-get三个重要命令

    apt-get update 更新软件源中的所有软件列表。 
    apt-get upgrade 更新软件。 
    apt-get dist-upgrade 更新系统版本。如果你对新版本软件的需求不是那么迫切,可以不执行

  • 相关阅读:
    纯JavaScripst的全选、全不选、反选 【转】
    Java 文件和byte数组转换
    nc命令使用详解
    mtr 命令详解
    Nginx主动检测方案---Tengine
    Apache相关安全设置
    tomcat APR的配置
    Vsftpd 配置详解
    FTP主动模式和被动模式的区别
    iptables配置详解
  • 原文地址:https://www.cnblogs.com/chenzhong-w/p/11380302.html
Copyright © 2011-2022 走看看