升级Debian12就是这么简单,新手玩转教程

简介

我也是最近才晓得debian12出来了,之前一直没怎么关注,据说是今年6月份就发布了。debian12较上一代的debian11含大量更新的软件包,可以玩一玩。我正好可以拿vmware里头的debian升级一下,平时只是当测试环境的,如果小伙伴们要升级,建议升级前一定要先备份,万一升级后Grub 加载失败,又没备份那就真玩坏咯。好了下面我就演示一下如何升级debian12的,方法适用于物理机、VPS、云服务器等。

 

教程

查看系统

升级前,第一步先查看下你自己的系统版本,使用如下命令

cat /etc/debian_version

# 或者

cat /etc/os-release

能看到我这里的debian版本显示的是debian11

- debian12shengji01

 

更新系统

先更新一下系统,

apt update
apt upgrade -y
apt dist-upgrade -y
apt autoclean
apt autoremove -y

 

手动升级

修改apt源

vi /etc/apt/sources.list

替换 bullseye 为 bookworm ,国内服务器把【deb.debian.org】和【security.debian.org】修改为【mirrors.tuna.tsinghua.edu.cn】

deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware
deb-src http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware

deb http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware
deb-src http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware

deb http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware
deb-src http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware

执行更新系统

apt update
apt upgrade -y
apt dist-upgrade -y

更新完我们再看下,版本已经升级到debian12了

cat /etc/debian_version 

# 或者 

cat /etc/os-release

- debian12shengji02

 

脚本自动升级

一键升级脚本如下

bash <(curl -sSL https://raw.githubusercontent.com/wikihost-opensource/linux-toolkit/main/system-upgrade/debian.sh)

如果是Debian9系统,那么需要执行好几次脚本,每次脚本执行只升级一个版本,更新过程会出现提示是否自动重启,选Y就可以了

Debian 9 升级到 Debian 10
Debian 10 升级到 Debian 11
Debian 11 升级到 Debian 12

- debian12shengji03

上一篇 cubecloud:#中秋&国庆双节优惠,香港CN2 GIA(原生IP),美国CN2 GIA
下一篇 阿里云盘自动签到方法分享

投稿邮箱:
ivpsr888@gmail.com (投稿详情)

TG订阅频道:
t.me/ivpsr_news 网站最新内容推送

TG交流群:
(点击加入) 用户交流

文章列表
1
RAKsmart:9月活动VPS全场5折,新注册送$10,RAK Cloud低至3折,更有特惠产品 $30秒杀 !!!
RAKsmart:9月活动VPS全场5折,新注册送$10,RAK Cloud低至3折,更有特惠产品 $30秒杀 !!!
2
JustHost:美国VPS洛杉矶机房简单测评,200Mbps带宽的JustHost怎么样?看了数据就懂
JustHost:美国VPS洛杉矶机房简单测评,200Mbps带宽的JustHost怎么样?看了数据就懂
3
VinaHost庆祝成立14年周年的活动,-90% 折扣, 新注册和续费-30%折扣
VinaHost庆祝成立14年周年的活动,-90% 折扣, 新注册和续费-30%折扣
4
raksmart:站群服务器$142/月,优化线路/8个C段,美国站群、日本站群、香港站群
raksmart:站群服务器$142/月,优化线路/8个C段,美国站群、日本站群、香港站群
5
TikTok运营播放量低怎么解决
TikTok运营播放量低怎么解决
6
noslacloud特价VPS,优惠低至119元/年,三网均走高端网络 (电信CN2GIA、联通CUII、移动CMIN2)
noslacloud特价VPS,优惠低至119元/年,三网均走高端网络 (电信CN2GIA、联通CUII、移动CMIN2)
7
设置CentOS7系统时间方法以及NTP同步中国时区
设置CentOS7系统时间方法以及NTP同步中国时区
8
Vmiss香港节点真实测速:BGP优化线路表现如何?答案全在这篇
Vmiss香港节点真实测速:BGP优化线路表现如何?答案全在这篇
9
clash中Gloabal Rule的使用介绍
clash中Gloabal Rule的使用介绍
10
UFOVPS暑期促销,全场VPS折扣、充300送150、充满1000翻倍、新用户订单返10%、香港、日本、美国机房可选
UFOVPS暑期促销,全场VPS折扣、充300送150、充满1000翻倍、新用户订单返10%、香港、日本、美国机房可选