利用APT-FAST给下载或更新提速

本文介绍两种方法来提升Ubuntu系统中软件包的下载速度。第一种方法通过使用axel结合apt-fast脚本来实现更快的下载速度;第二种方法则通过配置apt源选择最近的镜像站点来提高下载效率。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Apt-fast script that combines the power of the axel download manager with the stability of apt-get.
Install axel in ubuntu

First you need to install axel in ubuntu using the following comamnd from your terminal

sudo apt-get install axel

Now you need to download apt-fast script from here .Then, just place the script somewhere (/usr/bin or /usr/sbin is ideal), rename it to apt-fast (without the .sh extension)

sudo mv apt-fast.sh apt-fast

now you need to change the permissions to downloaded script

sudo chmod +x apt-fast

Using apt-fast

Once done, just use it like apt-get. To install a single package, make sure your database is up to date (apt-fast update), and run apt-fast install packagenamehere. Watch it download with incredible speed, and install your requested packages. To upgrade or dist-upgrade, do the same thing. Just use apt-fast dist-upgrade or apt-fast upgrade.

Should your download stall for any number of reasons, you'll need to do an apt-fast clean.

 

提速方法二:

 

apt-get now supports a 'mirror' method that will automatically select a good mirror based on your location. Putting:

 

deb http://ap-northeast-1.ec2.archive.ubuntu.com/ubuntu/ precise main restricted universe multiverse
deb http://ap-northeast-1.ec2.archive.ubuntu.com/ubuntu/ precise-updates main restricted universe multiverse
deb http://ap-northeast-1.ec2.archive.ubuntu.com/ubuntu/ precise-security main restricted universe multiverse

 

on the top in your /etc/apt/sources.list file should be all that is needed to make it automatically pick a mirror for you based on your geographical location.

Lucid (10.04), Maverick (10.10), Natty (11.04), And Oneiric (11.10) users can replace precise with the appropriate name.

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值