Рубрики
Debian \ apt \ update \ install \ dpkg

Обновление Debian 9.0 Stretch до Debian 10 buster

Подготовка:

!!! Внимание обновление может сломать систему.
sudo aptitude search '~i(!~ODebian)' -  очистка системы от сторонних пакетов 

sudo apt update - обновим список обновлений
sudo apt dist-upgrade - запустим обновление

dpkg -C - проверим целостность базы данных пакетов

apt-mark showhold - проверим нет ли отложенных пакетов

dpkg --audit - проверим и исправим все проблемы

Настройка репозиториев:

0. cp /etc/apt/sources.list /etc/apt/sources.list_backup - делаем копию sources.list
1. Настраиваем sources.list в зависимости от наших пакетов
#---------------------------------------------
#If you also need the main.  For example, for Debian 10/Buster:
deb http://deb.debian.org/debian buster main
deb-src http://deb.debian.org/debian buster main

deb http://deb.debian.org/debian-security/ buster/updates main
deb-src http://deb.debian.org/debian-security/ buster/updates main

deb http://deb.debian.org/debian buster-updates main
deb-src http://deb.debian.org/debian buster-updates main

#----------------------------------------------
#If you also need the contrib and non-free components, add contrib non-free after main. For example, for Debian 10/Buster:

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

deb http://deb.debian.org/debian-security/ buster/updates main contrib non-free
deb-src http://deb.debian.org/debian-security/ buster/updates main contrib non-free

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

#----------------------------------------------
#If you also need the Backports, contrib, and non-free components, add buster-backports lines. For example, for Debian 10/Buster:
deb http://deb.debian.org/debian buster-backports main contrib non-free
deb-src http://deb.debian.org/debian buster-backports main contrib non-free
----------------------------------------------

Обновление:

apt update
apt list --upgradable - посмотреть список пакетов для обновления
apt-get upgrade  - обновить Debian
apt-get dist-upgrade  - обновить Debian
cat /etc/os_release - проверить версию ос после обновления