bian正式发布了,还在debian12的用户可以考虑升级到debian13了。主机测评在这里介绍最简单的升级办法,复制、粘贴、回车即可!注意:数据无价,备份了再升级,避免出现错误导致不必要的损失。

第一步:先升级现有系统组件
apt update
apt upgrade
apt full-upgrade
第二步:清理废物
apt –purge autoremove
然后重启: reboot
第三步:确认当前版本
cat /etc/debian_version
确定你当前已经是最新的debian12了,别搞了半天还是debian11或者其他
第四步:修改源文件
sed -i ‘s/bookworm/trixie/g’ /etc/apt/sources.list
sed -i ‘s/bookworm/trixie/g’ /etc/apt/sources.list.d/*
或者你干脆替换吧,国内用:
cat > /etc/apt/sources.list << EOF
deb https://mirrors.huaweicloud.com/debian/ trixie main non-free non-free-firmware contrib
deb-src https://mirrors.huaweicloud.com/debian/ trixie main non-free non-free-firmware contrib
deb https://mirrors.huaweicloud.com/debian-security/ trixie-security main
deb-src https://mirrors.huaweicloud.com/debian-security/ trixie-security main
deb https://mirrors.huaweicloud.com/debian/ trixie-updates main non-free non-free-firmware contrib
deb-src https://mirrors.huaweicloud.com/debian/ trixie-updates main non-free non-free-firmware contrib
deb https://mirrors.huaweicloud.com/debian/ trixie-backports main non-free non-free-firmware contrib
deb-src https://mirrors.huaweicloud.com/debian/ trixie-backports main non-free non-free-firmware contrib
EOF
海外用:
cat > /etc/apt/sources.list << EOF
deb http://mirrors.linode.com/debian/ trixie main non-free non-free-firmware contrib
deb-src http://mirrors.linode.com/debian/ trixie main non-free non-free-firmware contrib
deb http://mirrors.linode.com/debian-security/ trixie-security main
deb-src http://mirrors.linode.com/debian-security/ trixie-security main
deb http://mirrors.linode.com/debian/ trixie-updates main non-free non-free-firmware contrib
deb-src http://mirrors.linode.com/debian/ trixie-updates main non-free non-free-firmware contrib
deb http://mirrors.linode.com/debian/ trixie-backports main non-free non-free-firmware contrib
deb-src http://mirrors.linode.com/debian/ trixie-backports main non-free non-free-firmware contrib
EOF
接下来回车执行,然后更新过程中根据需要选择是或者否升级你需要升级的,实在不懂就一路yes+回车 !
最后一步:清理废物
apt –purge autoremove
apt autoclean
再次提醒:升级之前备份你的数据,别搞翻车了没办法后悔!
如果机器上没有重要的东西,你可以直接从第四步开始执行!

神马VPS










最新评论
Hey there! Do you use Twitter? I'd like to follow you if that would be okay. I'm absolutely enjoying your blog and look forward to new posts.
I delight in, result in I found exactly what I was looking for. You've ended my four day long hunt! God Bless you man. Have a great day. Bye
Wow, this piece of writing is fastidious, my younger sister is analyzing such things, therefore I am going to convey her.
Wow, fantastic blog layout! How long have you been blogging for? you make blogging look easy. The overall look of your website is great, as well as the content!
I want to to thank you for this excellent read!! I definitely enjoyed every bit of it. I have got you book-marked to check out new things you
I like this post, enjoyed this one appreciate it for posting.
Definitely, what a splendid blog and enlightening posts, I surely will bookmark your site.Best Regards!
As I website possessor I conceive the content here is very fantastic, thanks for your efforts.