Debian Wheezy to Jessie update notes

# see: http://www.debian.org/releases/stable/amd64/release-notes/ch-upgrading.en.html

# check installed architecture first
# dpkg --print-architecture
# if not amd64, consider new installation with amd64

mkdir ~/wheezy
dpkg --get-selections > ~/wheezy/dpkg-get-selections
rsync -a /etc/ ~/wheezy/etc
rsync -a /var/lib/dpkg/info/ ~/wheezy/var-lib-dpkg-info
rsync -a /var/lib/apt/extended_states ~/wheezy/var-lib-apt-extended_states
deborphan --guess-all > ~/wheezy/deborphan
deborphan --list-keep > ~/wheezy/deborphan-keep

cd /etc/apt/sources.list.d
rm 03backports.list
mv 00wheezy.list 00jessie.list
mv 01wheezy-updates.list 01jessie-updates.list
mv 02wheezy-unikl.list 02jessie-unikl.list
sed -i 's/wheezy/jessie/g' *.list
cd /etc/apt/preferences.d
mv 02wheezy-unikl.pref 02jessie-unikl.pref
sed -i 's/wheezy/jessie/g' *.pref

<verify> /etc/apt/preferences <AND> /etc/apt/preferences.d/<>

dpkg --get-selections | fgrep hold
<fixup>
dpkg --audit
deborphan --list-keep
<fixup>

apt-get clean
apt-get update

apt-get dist-upgrade

systemctl daemon-reexec # when upgrade hangs at "setting up udev" for example

cd /etc ; find /etc -name '*.dpkg*' -o -name '*.ucf*'
<merge / remove / ...>

apt-get --purge autoremove
deborphan --guess-all
<delete unused packages ... run multiple times>

apt-show-versions | fgrep -v uptodate
<remove packages that have been removed from the _official_ archives,
 but keep old kernel until sucessful reboot>

reboot # verify kernel boot order first
apt-get --purge remove linux-image-3.2.0-4-amd64:amd64


<ext4 conversion>
tune2fs -O extents,uninit_bg,dir_index /dev/DEV
<change fs type in /etc/fstab>
<mount ro>
e2fsck -fDC0 /dev/DEV
<if root-fs is to be converted reboot and fix during startup when boot stops due to filesystem errors>