博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
ubuntu 命令详解及使用技巧
阅读量:7040 次
发布时间:2019-06-28

本文共 1798 字,大约阅读时间需要 5 分钟。

仅作备忘录使用,陆续补充,勿喷

  1. ubuntu 源列表

    ubuntu 系统中维护着一个源列表,每一个网址就是一个源,地址指向的数据标识着这台源服务器有哪些软件可以安装源列表地址: /etc/apt/sources.list注释:#修改完 sources.list 后保存, 执行 sudo apt update
  2. 更换国内源

    清华大学开源镜像库:https://mirrors.tuna.tsinghua.edu.cn/help/ubuntu/① 查看版本      sudo lsb_release -a② 选择 对应版本,例如 ubuntu 18.0.4 LTS③ 备份配置文件  /etc/apt/sources.list        sudo vim /etc/apt/sources.list        # 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释        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        # 预发布软件源,不建议启用        # deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse        # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse④ 退出保存,执行更新    sudo apt update
  3. update 与 upgrade 的区别

    sudo apt update : 更新源列表文件,并保存到本地sudo apt upgrade : 根据本地软件,谨慎使用,避免系统更新
  4. 添加 apt 仓库

     
  5. 常用指令
    sudo apt list    // 查看所有软件列表sudo apt list  --upgradeable   // 查看所有可更新软件列表sudo apt autoremove  // 自动移除依赖

转载于:https://blog.51cto.com/12750968/2121249

你可能感兴趣的文章
在android项目中R.java中失去id类怎么办
查看>>
Andorid时间控件和日期控件
查看>>
VC MFC中设置对话框的背景色、背景图片
查看>>
ios中tableview侧栏的折叠
查看>>
mahout贝叶斯算法开发思路(拓展篇)1
查看>>
如何用LinkedHashMap实现LRU缓存算法
查看>>
EXTJS AJAX解析XML数据
查看>>
android 向服务器上传
查看>>
mount umont
查看>>
PHP源码下载
查看>>
poj 2594Treasure Exploration(有向图路径可相交的最小路径覆盖)
查看>>
block 数组排序
查看>>
简析 addToBackStack使用和Fragment执行流程
查看>>
JAVA设计模式《一》
查看>>
第1章 初识java----输出多行的语句写法
查看>>
Linux目录树
查看>>
CentOS进程资源占用高原因分析命令
查看>>
PHP发送返回404状态码
查看>>
第7章 类和对象 类
查看>>
【转】Android HAL实例解析
查看>>