So it’s time to upgrade the slug’s Debian NSLU2 from Etch to Lenny. Every upgrade carried a risk, depending on how much you have customised the installation. In my case, the risk was small since I have made little change to the default install. In spite of that, the hassle and significant time penalty in making a fresh install was a main factor of consideration. A little extra effort to ensure a fall back path in case of failed upgrade went a long way.
Backup backup backup
I am frequently amazed by people who complaint about a failed upgrade. Why didn’t they backup the installation before making this major change? The ease in which an upgrade can be made could be the reason for this complacency.
Also important is to verify that the backup is functional before going forward. In other words, once the backup is made, be sure to check that the backup can be restored to working condition.
If you have been following my “Hacking Linksys NSLU2″ blog posts, you would find that I have hacked the slug to make it considerably easy to backup. The installation is on an USB thumbdrive, which could be easily removed.
After plugging the thumbdrive into a PC, I did a direct disk dump of the entire partition to an image file.
sudo dd if=/dev/sdb2 | pv | sudo dd of=image.file
/dev/sdb2 is the root partition of the install (as it appeared in the PC);
pv is an application that allowed the data transfer to be monitored.
At the same time, I already have the internal boot flash image dump (refer to Debian NSLU2 post-install part 1 for more info on how to create this and recover, if necessary).
Upgrading was extremely simple. I followed the instructions here. It took about an hour, and I have to answer a few questions during the process. These were mainly about whether I wanted to keep the configuration files which I have made changes on.
The upgrade completed successfully. I have yet to use the new Lenny install for any significant amount of time, but thus far it appeared to be working. The “beep IP” customisation I made is still functional, but the “USB port beep and LED control” were not. I guess I would have to look into the script again.