zoukankan      html  css  js  c++  java
  • Ubuntu18.04修改为阿里云

    对源安装时,要先知道系统的版本,以免安装错的版本

    使用命令:lsb_release -c

    备份原先的配置文件

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

    修改源文件的内容

    sudo vim sources.list    # 在 /etc/apt 目录下

    阿里源的源文件如下:

    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-backports main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports 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
    将阿里源文件复制到 sources.list下,用vim的相应操作

    全部删除:按esc键后,先按gg(到达顶部),然后dG
    全部复制:按esc键后,先按gg,然后ggyG
    全选高亮显示:按esc键后,先按gg,然后ggvG或者ggVG

    单行复制:按esc键后, 然后yy
    单行删除:按esc键后, 然后dd
    粘贴:按esc键后, 然后p
    复制到粘贴板: 全选高亮显示之后,ctrl+shift+c

    参考:
    原文:https://blog.csdn.net/vivian_wanjin/article/details/82804884

    更新源

    sudo apt-get update

    更新软件

    sudo apt-get upgrade
  • 相关阅读:
    刷题19. Remove Nth Node From End of List
    刷题17. Letter Combinations of a Phone Number
    mysql图形化工具基本操作
    报错:ER_NO_DEFAULT_FOR_FIELD: Field 'status' doesn't have a default value
    express综合用法
    npm自定义上传
    node_第三方包下载文件package.jon详解
    正则表达式修改文字元素对齐方式
    初始化文章分类的方法 下拉的layui框
    标准git请求
  • 原文地址:https://www.cnblogs.com/zgqcn/p/10734881.html
Copyright © 2011-2022 走看看