I'm doing some HD upgrades (got a new largest HD, and trickling down
the space upgrades as I go). Since both of the upgrades I did tonight
were LVM, I thought they'd go smoothly. One of them didn't!
On Slackware, the upgrade was pretty simple. I simply put in the new
drive (it's a USB external enclosure right now, but later will be
mounted in the machine once I'm ready to power cycle it) and created an
LVM partition. Then I used pvcreate to create the physical layout, and
executed a nice vgextend to add it to the (smaller) drive's group. From
there, using the command pvmove /dev/olddrive caused it to copy all the
physical extents off the olddrive to any free space elsewhere (which, in
this group, was the only other drive). This all works fine while the
file system is live, due to the way that device mapper and LVM works!
Next up was my Ubuntu 6.10-based MythTV machine. I again added in the
new drive, partitioned it, and pvcreated an LVM. I then did vgextend,
and executed pvmove. Unfortunately, this is a good way to screw up your
system if you're using Ubuntu. The included LVM, library, and driver
version are all a couple of minor versions behind what I have setup in
my Slackware server. This, mixed with the dm-raid package's age, seems
to be a recipe for unhappyness. The easiest way I could fix this was to
reboot the machine (since the pvmove will lock up the entire lvm
subsystem), and then do a pvmove --abort. This managed to recover the
setup (since it was in an inconsistent pv-alloced state, where some of
the new drive was dedicated to things...), and allowed me to vgreduce to
remove the new drive.
The work around is to create a new volume group and logical volume,
telinit 1, and then cp -ax the files from the old partition to the new
one. I did to an apt-get update and apt-get upgrade to verify that this
was a behaviour of the current 6.10 Ubuntu as well. Hopefully Conrad
can push the apropriate bug buttons and get it fixed :)
I'm happy now that I get "50 hours available" vs. the 2 hours available
I had on a good day with my old, tiny, loud PATA drive that was in the
MythTV box.
Received on Wed Mar 14 00:00:36 2007
This archive was generated by hypermail 2.1.8 : Wed Mar 14 2007 - 00:00:45 CST