Ubuntu管理软件源
在Ubuntu环境下,我们经常会使用apt-get(apt)命令下载各种软件,当所需软件在官方软件库中找不到时,我们需要添加第三方的软件源,或者由于位于海外的官方软件源下载速度过于感人时,需要添加国内的源,我们可以编辑"/etc/apt/sources.list"文件,添加相应的源,例如添加阿里云软件源如下:
1、百度找到阿里云软件源
deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
2、编辑之前最好先备份
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
3、用vim或其它方法编辑
sudo vim /etc/apt/sources.list
4、配置完成后需要更新下
sudo apt-get update
添加PPA源
PPA(Personal Package Archives)源的添加我们需要用到software-properties-common软件包下的add-apt-repository命令,当然,该命令不仅仅可以添加PPA源,普通的源也可以
先安装该软件包
sudo apt-get install software-properties-common
安装完成后即可使用
sudo add-apt-repository [options] [repository]
例如Oracle Jdk的ppa(由于Oracle JDK的下载需要登录Oracle账号,该PPA源已经无法使用)
sudo add-apt-repository ppa:webupd8team/java
删除PPA源,先输入命令:
sudo add-apt-repository -r ppa:user/ppa-name
然后进入 /etc/apt/sources.list.d 目录,将相应 ppa 源的保存文件删除,然后更新
sudo cd /etc/apt/sources.list.d
sudo rm -r xxx
sudo apt-get update
要更方便的找到需要的PPA源,可以上launchpad查看
Ubuntu管理软件源的更多相关文章
- [ubuntu]deb软件源
虽然ubuntu的中国服务器的速度已经非常不错,但是难免,会有网络不畅的情形,所以修改软件源地址是一个基础的知识点. 修改ubuntu的软件源的方式有多种,一直是通过ubuntu软件中心提供的UI,还 ...
- ubuntu更换软件源
ubuntu更换软件源 /etc/apt/source.list 163: deb http://mirrors.163.com/ubuntu/ trusty main restricted u ...
- ubuntu 更新软件源
ubuntu 更新软件源 修改文件sources.list 位于/etc/apt/sources.list,并备份原文件为sources.list.bak deb http://mirrors.163 ...
- linux -- ubuntu 何为软件源
新手学Ubuntu的时候,一般不知道什么是源,但源又是Ubuntu下常用到的东西.因此,本文就详细介绍一下Ubuntu 源. 什么是软件源? 源,在Ubuntu下,它相当于软件库,需要什么软件,只要记 ...
- Linux学习笔记——Ubuntu更新软件源
0.前言 通过改动ubuntu软件源可提高apt命令下载安装软件的速度. 參考资料 [官方资料]--配置文件改动方法 [Ubuntu如何改动软件源地址]--使用ubun ...
- ubuntu修改软件源的方法
最快方法--替换法 刚安装好的ubutun,打开source.list后,用vim替换的方法将所有的us提付出替换为 cn,然后保存退出,更新即可. # vim /etc/apt/source.lis ...
- ubuntu 把软件源修改为国内源
国内有很多Ubuntu的镜像源,比如:阿里源.网易源等,还有很多教育网的源,比如:清华源.中科大源等. 这里以清华源为例讲解如何修改Ubuntu 18.04里面默认的源. 修改步骤 第一步:备份原始源 ...
- ubuntu更新软件源
更新源方法: 1. 打开终端.单击主菜单中的“应用程序 - 附件 - 终端”. 2. 修改更新服务器列表.请在终端中执行下面的两条命令: sudo cp /etc/apt/sources.list / ...
- ubuntu apt 软件源的更改
在ubuntu上面安装软件一般都使用 apt安装 在ubuntu下面有一个源列表,源列表里面都是一些网站信息,每条网址就是一个源,这个地址指向的数据标识着这台服务器上有哪些软件可以用 编辑源命令: s ...
随机推荐
- 容器服务kubernetes federation v2实践五:多集群流量调度
概述 在federation v2多集群环境中,通过前面几篇文章的介绍,我们可以很容易的进行服务多集群部署,考虑到业务部署和容灾需要,我们通常需要调整服务在各个集群的流量分布.本文下面简单介绍如何在阿 ...
- 2019-8-31-PowerShell-通过-WMI-获取系统服务
title author date CreateTime categories PowerShell 通过 WMI 获取系统服务 lindexi 2019-08-31 16:55:58 +0800 2 ...
- HTML--简单的注册网页
利用表格,渐变色 <body background="未标题-2.jpg"> <table align="center" border=&qu ...
- Python--day69--ORM外键的正向查询和反向查询
什么是正向查询,什么是方向查询?
- Element节点输出到System.out
protected void writeElementToFile(Element valrespEle) { try { TransformerFactory transformerFactory ...
- H3C OSPF协议区域LSA发布
- H3C 寻找邻居
- 解决input number类型上下滚动 禁用滚轮事件
1.去掉input在type="number"时的上下箭头 <style> input::-webkit-outer-spin-button,input::-webki ...
- H3C IPv6地址自动配置
- H3C 三种生成树协议特性的比较