Howto upgrade debian: Difference between revisions

From Vidalinux Wiki
Jump to navigation Jump to search
Line 30: Line 30:
reboot system:
reboot system:
  sudo reboot
  sudo reboot
list all packages in hold status:
sudo apt-mark showhold
if any packages appear in the list, remove the hold status for each package:
sudo apt-mark unhold [package_name]

Revision as of 02:45, 4 September 2025

update from 10 to 11

list all packages in hold status:

sudo apt-mark showhold 

if any packages appear in the list, remove the hold status for each package:

sudo apt-mark unhold [package_name]

upgrade all packages to the latest version:

sudo apt update && sudo apt upgrade -y

install the gcc-8-base package:

sudo apt install gcc-8-base -y

backup /etc/apt/sources.list file

cp /etc/apt/sources.list /etc/apt/sources.list.bk.$(date +%F)

update /etc/apt/sources.list file with bullseye repos:

cat > /etc/apt/sources.list << EOF
deb http://deb.debian.org/debian bullseye main contrib non-free
deb http://deb.debian.org/debian bullseye-updates main contrib non-free
deb http://security.debian.org/debian-security bullseye-security main
deb http://ftp.debian.org/debian bullseye-backports main contrib non-free
EOF

if you have repos in /etc/apt/sources.list.d update all to bullseye:

grep -rl "buster" /etc/apt/sources.list.d | xargs sed -i "s/buster/bullseye/g"

now upgrade your system:

sudo apt update && apt full-upgrade -y

upgrade from 12 to 13

update and upgrade:

sudo apt update && apt upgrade -y && apt autoremove -y

upgrade all packages:

sudo apt full-upgrade -y

clean off any leftover packages:

sudo apt --purge autoremove -y

reboot system:

sudo reboot

list all packages in hold status:

sudo apt-mark showhold 

if any packages appear in the list, remove the hold status for each package:

sudo apt-mark unhold [package_name]