default
menu home
Icon library Sign up Login favorite_border message help_outline
Online notes - online bookmark

Ubuntu 22.04 live server更换亚马逊AWS的更新源

styleTags: All CSS html javascript php/other IT
by: fanshome  2023-05-18 08:47(UTC)

amzon亚马逊云AWS的更新源,即使在国内速度也基本可接受,其最大特点是软件丰富,常用软件包几乎没有找不到的。

具体步骤如下:

php/othercontent_copyCopy codes
1.备份sources.list文件
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
 

2.打开并编辑sources.list文件,这里用你最习惯的编辑器便可。
sudo nano /etc/apt/sources.list

3.删除原内容,选择AWS镜像源,添加至文档内
## Note, this file is written by cloud-init on first boot of an instance
## modifications made here will not survive a re-bundle.
## if you wish to make changes you can:
## a.) add 'apt_preserve_sources_list: true' to /etc/cloud/cloud.cfg
##     or do the same in user-data
## b.) add sources in /etc/apt/sources.list.d
## c.) make changes to template file /etc/cloud/templates/sources.list.tmpl

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy main restricted
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates main restricted
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy universe
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy universe
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates universe
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy multiverse
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy multiverse
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates multiverse
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-updates multiverse

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse
# deb-src http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ jammy-backports main restricted universe multiverse

deb http://security.ubuntu.com/ubuntu jammy-security main restricted
# deb-src http://security.ubuntu.com/ubuntu jammy-security main restricted
deb http://security.ubuntu.com/ubuntu jammy-security universe
# deb-src http://security.ubuntu.com/ubuntu jammy-security universe
deb http://security.ubuntu.com/ubuntu jammy-security multiverse
# deb-src http://security.ubuntu.com/ubuntu jammy-security multiverse

4.保存sources.list文件,然后更新apt-get
sudo apt-get update

visibility 2294


- for heavy web user Online notes
adimg
logo Post a comment

captcha
Please check the captcha code
Cancel