升级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
onetechcloud香港CN2/CMI大带宽VPS,美国CN2/CUII/AS4837高防双ISP低至22元/月
onetechcloud香港CN2/CMI大带宽VPS,美国CN2/CUII/AS4837高防双ISP低至22元/月
2
lightnode怎么样?深度测评缅甸VPS,lightnodd缅甸仰光机房测评数据分享
lightnode怎么样?深度测评缅甸VPS,lightnodd缅甸仰光机房测评数据分享
3
Vultr账户计费攻略,充值退款规则,赠金使用避坑/新用户赠$100试用金
Vultr账户计费攻略,充值退款规则,赠金使用避坑/新用户赠$100试用金
4
edgeNAT韩国VPS测评,首尔LG机房、SK回国直连、企业级SSD RAID10、解锁Netflix/TikTok/ChatGPT等
edgeNAT韩国VPS测评,首尔LG机房、SK回国直连、企业级SSD RAID10、解锁Netflix/TikTok/ChatGPT等
5
VS Code打开文本显示乱码
VS Code打开文本显示乱码
6
RAKsmart:“RAK Cloud”云服务器低至1折起,裸机云新品上市,全场7折,低至129元/年!!!
RAKsmart:“RAK Cloud”云服务器低至1折起,裸机云新品上市,全场7折,低至129元/年!!!
7
6块钱购买1年的便宜域名,13块可用7年期限,站长亲测超值分享
6块钱购买1年的便宜域名,13块可用7年期限,站长亲测超值分享
8
DediPath:夏季特惠继续进行,全场VPS和混合服务器5折,独立服务器E3-1240v2再次大幅打折低至$39/月
DediPath:夏季特惠继续进行,全场VPS和混合服务器5折,独立服务器E3-1240v2再次大幅打折低至$39/月
9
VPS一键DD整合脚本,安装Windows/Debian/Ubuntu/CentOS
VPS一键DD整合脚本,安装Windows/Debian/Ubuntu/CentOS
10
了解PPTP、L2TP这些协议的区别及端口号
了解PPTP、L2TP这些协议的区别及端口号