Home > Articles > Operating Systems, Server > Linux/UNIX/Open Source

  • Print
  • + Share This
Like this article? We recommend

Making a Backup

Listed below are tutorials describing how to modify the Knoppix LiveCD disk in order to

  1. Add a backup script suitable for mirror drive and archival DVD backup
  2. Modify the Web page displayed by the browser that automatically opens on Knoppix startup

This allows you to point and click from the Knoppix default bootup Web page to a new backup page that provides the user a choice between these scripts.

Use the procedure described in my tutorial on backups, Part 1 and Part 2, with the script modified to substitute your new drive location paths for the old ones, including the boot partition part of the script.

The big advantage of the backup script-via-LiveCD approach is that once it's burned, you can't screw it up no matter how tired you are. (Making a mistake doing this manually can result in disaster.) Pop in the CD and the mobile rack, boot, click three times, and find something else to do for 20 minutes or so (or for several hours if you're running dar for backup to DVD or backing up to a new drive mirror).

Do this, and you have the software required either to quickly back up to a mobile drive (rsync only backs up the changes once the full filesystem is on the backup drive, leaving you with a ready-to-go filesystem), or to back up to a DVD backup set for archival purposes.

You can do a dd copy from sda to sdb, as the LinuxPlanet backup tutorials describe, by simply substituting sda for hda in the dd command. The advantage of doing this is that there's no messing around with partitioning or installing a bootloader/MBR. Just run the dd command, and you have an <i>identical</i> copy of the main drive ready for backup (with minor changes required if you're working with an LVM filesystem; see below).

The procedure in the LinuxPlanet tutorial for turning the dd-copied LVM backup disk into a useful backup by changing the UUIDs does not work on SATA hard drives.

Considerations for LVM

My article on the Red Hat Web site describes the SATA procedure for changing the LVM volume UUID for the backup drive on LVM filesystems. (If you aren't using LVM, skip this section.)

  • If you have an LVM filesystem for which UUIDs for the main and backup drive are identical, you won't be able to mount the main and backup drives at the same time to make backup possible.
  • If you don't have an LVM filesystem, ignore the LVM-specific portions of the article and continue following the steps until you have a point-and-click backup setup based on a modified LiveCD.

Change the scripts in the LinuxPlanet tutorial article to eliminate the u in the rsync -ahLvu command as discussed in the Redhat article. In addition, change the script references from hda to sda and from hdd to sdb or to whatever fits your workstation filesystem.

Alternatives to dd Bit Copying

Other choices include:

  • Install a minimum OS on the backup. Use a different name; for instance, if your main installation is labeled terrarium, call the backup install terrarium-back in the installation process. Then rsync from sda1 to sdb1 and from sda5 to sdb5, as described above for creating a main drive.
  • Using a Linux partitioning utility (e.g., gparted) to create disk partitions about the right size for /boot and /, and using grub-install to put in a boot loader and MBR, then doing a rsync transfer of each partition.
  • + Share This
  • 🔖 Save To Your Account