Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
Operating Systems Software IT Linux

How To Perform a Bare-Metal Backup On Linux LVM 34

perlow writes "Using the free System Rescue CD you can perform bare-metal backups and restores of many types of computer systems. In this article, ZDNet columnist Jason Perlow explains the multi-step procedure in detail on an LVM-based system."
This discussion has been archived. No new comments can be posted.

How To Perform a Bare-Metal Backup On Linux LVM

Comments Filter:
  • Sure - Don't. (Score:4, Interesting)

    by pla ( 258480 ) on Wednesday May 07, 2008 @03:23PM (#23328320) Journal
    Step 1 - If your LVM hasn't forgotten its own configuration yet, get that sucker off an LVM as fast as you possibly can.

    When I first discovered LVM (and it had already reached a quite mature V2 at that point), I thought it the greatest thing in volume management since the invention of the RAID.

    I didn't half-ass it, I took my time to learn how it works, set up and broke a few, added a new PV and grew it to make sure it worked, backed some up, recovered from deliberately broken volumes (which works great - as long as you never try to bring the broken volume online by, say, rebooting), etc. Then I turned it on and loved it.

    Then I received a hard lesson in what it means to say that JBOD has a failure rate multiplicatively proportional to that of each individual drive. And, surprise surprise, LVM amounts to nothing more than fancy OS-level JBOD, without even the performance boost of a proper RAID controller.

    Thanks but no thanks. If I want to span a volume across multiple disks, I'll use RAID 5 or 6 from now on, ThankYouVeryMuch. I can only thank Zeus that I hadn't yet gotten around to cannibalizing my old file server when the LVM one day decided to eat itself (even if I could have salvaged something from the individual drives, I couldn't once it "fixed" its configuration to reflect the new PV set).
  • Re:Sure - Don't. (Score:3, Interesting)

    by drsmithy ( 35869 ) <drsmithy@nOSPAm.gmail.com> on Wednesday May 07, 2008 @04:00PM (#23328856)

    I didn't half-ass it, I took my time to learn how it works, [...]
    Then I received a hard lesson in what it means to say that JBOD has a failure rate multiplicatively proportional to that of each individual drive. And, surprise surprise, LVM amounts to nothing more than fancy OS-level JBOD, without even the performance boost of a proper RAID controller.

    These two statements are in conflict.

  • by dnamaners ( 770001 ) on Wednesday May 07, 2008 @04:38PM (#23329376) Journal
    Don't get me wrong, I love centralized backups and backup server/client software (bacula for example). However I use old school methods for a bare metal restore. For simple things blanking the free space and then make a "dd" image is all you need. However you do it, keep it simple, and there may be no need to do bare metal on the whole of a file servers data set. Once I get the core of it back up I can use my favorite software to get the system up-to-the-last-snapshot current.

    LVM and Raid can be a little complex if you boot off it so ill give some tips. A nice small boot like SLAX (may favorite) or Knoppix is needed to start any bare metal restore. Pick something that supports the hardware and had LVM and or Raid. Either make a custom disk to add your backup data to the volume or have a 2nd DVD drive. Boot and restore.

    I make my backups via simple methods like rsync and tar. I use a few simple scrips to do it all. So simple that it is easy to restore by hand if need be. This makes the restore safer as it can be done a host of ways. Not to mention these unix tools are present in all distributions. Probably the biggest reason for the old school way is that on a bare metal restore often hardware may change. New drives etc, basically failure can be a reason to upgrade etc. Many utilities can choke on big hardware changes, new drive sizes and such.

    I take detailed system information and note it in the backup as human notes. Then grab your raid & LVM configuration and write a quick script to rebuild these features via the command line. Basically just a list of the actions you take to make a file system and format them the desired files system types manually. These same scripts will also re-apply boot loader and such as well. If the volumes change after a failure I can just issue updated commands (or edit the script) and make a similar layout of the filesystem. Then just open the tar balls via script or by hand and populate the new filesystem with the files you archived. With a bit of practice all of this can be automated by scripts. But if you need to vary the procedure due to hardware changes or as a way to clone a system you can.

Those who can, do; those who can't, write. Those who can't write work for the Bell Labs Record.

Working...