f.zz.de
posts /

Debian Upgrade #2

Posted Thu 24 May 2007 10:09:17 AM CEST
in

One of the first problems to stumple upon is - How do i install/dist-upgrade without user interaction. The debconf part is easy - Just call apt-get dist-ugrade with DEBIAN_FRONTEND=noninteractive. But then you still get asked on whether you want the config files to get replaced which is dpkg's fault. There is a dpkg option to either take all new configs --force-confnew or to take all old config --force-confold. Now put everything together:

DEBIAN_FRONTEND=noninteractive \
apt-get \
-o Dpkg::Options::="--force-confnew" \
--force-yes \
-fuy \
dist-upgrade

If all packages would be nice this would be the solution. There are still packages which do everything on their own. Have a look at bind. It heavily complains even with this setup that /var/named exists and is non-empty. Another issue with bind is that the upgrade from bind to bind9 on etch tries to create a user bind. With my setup this fails because i am running libnss-ldap and the local machine may not create users in the ldap. So the first thing to do is to purge bind, disable ldap by changing nsswitch.conf and later to the reverse.