How to upgrade Debian 10 (buster) to 11 (bullseye)

    Upgrade the current stretch installation to the latest packages.

    apt update && apt upgrade && echo OK


    Install the gcc-8-base package.

    apt install gcc-8-base


    Perform database sanity and consistency check.

    dpkg --audit


    Fix any output from this command.Check for any packages which are held back.

    apt-mark showhold


    Point apt to the buster sources.

    sed -e 's/^deb/#deb/g' -i /etc/apt/sources.list

    cat << EOF >> /etc/apt/sources.list

    deb bullseye main contrib non-free

    deb bullseye-updates main contrib non-free

    deb bullseye-security main
    deb bullseye-backports main contrib non-free


    Perform the upgrade, downloading packages in advance.

    apt update && apt clean && echo OK

    apt full-upgrade -d -y && echo OK

    apt full-upgrade -y && apt clean && echo OK




    No questions yet.