Post

Upgrading to "Lenny"

With “Etch” being released as new Debian stable I decided to upgrade to “Lenny”, Debian’s new testing branch. By the time of writing the difference between stable and testing isn’t very big - Etch was released about three weeks ago. So I didn’t expect any difficulties in upgrading and with one little exception I was right.

As always, updating Debian is very easy. You need to edit “/etc/apt/sources.list” and replace etch or stable with lenny or testing. I prefer the names, because this way you would automatically use the stable branch once lenny becomes stable - which will be in the far, far future. ;-) So, your “sources.list” should look something like this:

1
2
3
4
5
deb http://ftp.de.debian.org/debian/ lenny main contrib non-free
deb-src http://ftp.de.debian.org/debian/ lenny main contrib non-free

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

I’d then stop X by typing as root:

1
$ /etc/init.d/kdm stop  #if you're using KDE

or

1
$ /etc/init.d/gdm stop  #if you're using Gnome

Login as root again and go ahead updating:

1
2
$ apt-get update
$ apt-get dist-upgrade

As already mentioned, there is a little trap. You may receive some errors when dpkg tries to configure “ttf-opensymbol” which fails with:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
Updating fontconfig cache...
/usr/share/fonts: failed to write cache
/usr/share/fonts/X11: failed to write cache
/usr/share/fonts/X11/100dpi: failed to write cache
/usr/share/fonts/X11/75dpi: failed to write cache
/usr/share/fonts/X11/Type1: failed to write cache
/usr/share/fonts/X11/encodings: failed to write cache
/usr/share/fonts/X11/encodings/large: failed to write cache
/usr/share/fonts/X11/misc: failed to write cache
/usr/share/fonts/X11/util: failed to write cache
/usr/share/fonts/truetype: failed to write cache
/usr/share/fonts/truetype/arphic: failed to write cache
/usr/share/fonts/truetype/baekmuk: failed to write cache
...

Just let apt-get finish and then reboot, login into X again and invoke “apt-get dist-upgrade”. It’ll show the same errors again. Open another terminal as root and (this is the boring part…) touch every directory which gave the error message:

1
2
$ touch /usr/share/fonts
$ touch /usr/share/fonts/X1

You may write a little script to do that task or just go through it… Having that accomplished type

1
$ apt-get dist-upgrade

again and every package should then be configured all right. I found the solution to this bug in the Ubuntu Forums here.

No guarantee, that’ll be that easy to upgrade in the future when Etch and Lenny differ more, but for now that’s all you need to do. Congratulations, you’re now running Debian testing, aka Lenny!

EDIT: You may want to install the “apt-listbugs” package when running Debian testing/unstable. This way apt will let you know about critical bugs when installing a new software package.

This post is licensed under CC BY-SA 4.0 by the author.