start upgrade-to-stretch list
authorPeter Palfrader <peter@palfrader.org>
Sun, 26 Mar 2017 12:12:15 +0000 (14:12 +0200)
committerPeter Palfrader <peter@palfrader.org>
Sun, 26 Mar 2017 12:12:15 +0000 (14:12 +0200)
input/howto/upgrade-to-stretch.mdwn [new file with mode: 0644]

diff --git a/input/howto/upgrade-to-stretch.mdwn b/input/howto/upgrade-to-stretch.mdwn
new file mode 100644 (file)
index 0000000..a0a6920
--- /dev/null
@@ -0,0 +1,62 @@
+# Upgrade from jessie to stretch:
+
+Make sure to coordinate with whoever uses the host, be it the buildd
+operator, the QA team, the ftp team or just announce it on IRC if it's a
+general developer box.
+
+upgrade stuff:
+
+* answer question to libc6 "Restart services automaticaly" with "yes"
+* say no to other other questions.
+
+todo:
+  at least on lindsay samhain failed to configure after upgrading the package.  figure out details.
+
+commands:
+       sed -i "s#jessie#stretch#g" /etc/apt/sources.list.d/debian.list /etc/apt/sources.list.d/security.list &&
+       dpkg --clear-avail &&
+       if [ -e /etc/apt/sources.list.d/buildd.debian.org.list ]; then
+               sed -i "s#jessie#stretch#g" /etc/apt/sources.list.d/buildd.debian.org.list
+       fi &&
+       apt-get update &&
+       service samhain stop &&
+       apt-get install dpkg apt samhain &&
+       service samhain stop &&
+       apt-get dist-upgrade &&
+       rm -f /var/state/samhain/samhain_file /var/lib/samhain/samhain_file &&
+       samhain --foreground -t init -p none -s none -l none -m none &&
+       (puppet agent -t || true) &&
+       apt-get update &&
+       apt-get dist-upgrade &&
+       apt-get purge libssl1.0.0:amd64 gcc-4.9-base:amd64 gcc-4.8-base:amd64 libapt-pkg4.12:amd64 libreadline6:amd64  libprocps3:amd64 sp libsp1c2 libaugeas-ruby1.8
+       apt-get --purge autoremove &&
+       while [ "$(deborphan -n | wc -l)" -gt 0 ] ; do apt-get purge $(deborphan -n); done &&
+       dpkg --clear-avail &&
+       apt-get clean
+
+purge removed packages
+
+       dpkg --get-selections | awk '$2=="deinstall" {print $1}' &&
+       echo "really purge these [y/N]?" && read ans && [ "$ans" = "y" ] && dpkg --purge `dpkg --get-selections | awk '$2=="deinstall" {print $1}'` &&
+       echo "These are not at install:" && dpkg --get-selections | awk '$2!="install" {print $1}'
+
+more clean ups:
+
+       /usr/lib/nagios/plugins/dsa-check-packages | tr -d ,
+
+       (apt-get purge them)
+
+       apt-get --purge autoremove &&
+       while [ "$(deborphan -n | wc -l)" -gt 0 ] ; do apt-get purge $(deborphan -n); done
+
+       (puppet agent -t || true) && (puppet agent -t || true)
+
+update dsa-nagios.git (add host to jessie hostgroup)
+
+re-init samhain and finish with a reboot
+
+       (puppet agent -t || true) &&
+       (puppet agent -t || true) &&
+       (puppet agent -t || true) &&
+       samhain --foreground -t update -p none -s none -l none -m none &&
+       /sbin/reboot