Wednesday, May 30, 2018

Linux Upgrade: The Hard Way

So my long-suffering Linux box, Lucky, ate itself a few days ago. I was in the middle of tinkering with a makehuman model, and all of a sudden, I couldn't write to the drive. It'd be having problems at boot time for months. My diagnosis: I suspect all the hangs and reboots finally corrupted the logical volume system.

Since I had to boot from a USB drive anyway (it was that bad), I decided to go ahead and upgrade to Xubuntu 18.04, Bionic Beaver. Seriously. That's what they called it. I get the feeling the name choosers' first language isn't English.

LVM, the logical volume management system (actually LVM2) is pretty robust. I was able, with some poking, to get my /home logical volume operational, albeit with a lot of complaints from LVM. I then rsynced it to my Buffalo NAS. This would bite me later.

After that, I reformatted the drives, set LVM up on it, made the registered boot partition much larger (4GiB) and installed. No problems on the 6th try.  Hint: if your installer complains that the install media is corrupt, reboot first, and try fscking it. I got no errors, but the installer stopped complaining and finished the job. Switch to the NVIDIA drivers so I get real performance out of my GPUs: yessss.  Works a treat. It boots reliably too, which is fantastic. Then the real work began.

Here's where the Buffalo NAS bit me for what will be its last time. Buffalo NASs come with almost no software, and no supported way to add more. So I had to root it and make some hacks to be able to back my Linux machines up to it at all. When trying to restore the same way, via rsync, it would occasionally drop the link and abort the sync. It never managed to restore my 40GiB windows 10 virtualbox drive. Likewise, copying data over windows file sharing was flaky, although this may be a problem with Thunar. Undaunted (but very pissed off) I finally managed to get the files I needed restored with a combination of those methods plus sftp from the NAS to my desktop machine. I don't need a NAS that I can't restore backups from reliably. I've got an infrastructure upgrade planned, and this piece of crap NAS is going to go away permanently.

So anyway. I've restored what I could not rebuild, and rebuilt what I couldn't restore (or more precisely, rebuilt what couldn't work on the restored files. Wine, I'm looking at you here.) Still have to get virtualbox going again, but I've done that before and it's given me only minimal grief, so I'm fairly (over)confident about that. Thunderbird? Give it its old .thunderbird directory and it picks up where it left off. Makehuman: reinstall and rebuild. Blender? restore the directories and go. Openscad: reinstall. And so on. My actual data loss is fairly minmal, although because some files just turn up missing despite having been restored, I'm going to have to keep that emergency dump around a while.

Anyway. I'd been meaning to tear into this machine and bring it up to 18.04 and try to fix the stability problems. Apparently it decided it was time. So far, that, at least, has been successful.

But seriously. Don't buy a Buffalo NAS unless you're only dealing with Windows or Mac. Even then, it's crappy.


No comments:

Blog Archive