Backup and Restoration

Backup icon

The backup and restoration procedures outline in this section will allow for either complete or partial restoration of data.

Unforturnately, backup requirements are inversely proportional to the price per gigabyte of diskspace. As the price of diskspace decreases, the backup requirements increases. Since harddisk prices are so cheap, people put huge disks on their systems; resulting in the need for bigger and faster backup solutions.

Today, there are many backup solutions available: tape backup, optical disk backup, harddisk backup, network backup, etc. For those with the budget, tape backup is still the best solution as tapes are reliable, relatively cheap, fast, holds large volume of data and can be reuse. Unfortunately, for most SOHO users, tape backup is impractical, network backup server is also out of the question, so that just leave optical disk and harddisk backup. Only these two solutions are discussed in the following.

All material presented are licensed under The GNU Free Documentation License.


  1. Prerequisite
  2. The Backup Strategy
  3. Data Recovery
  4. Initial DVD Backup
  5. Regular Harddisk Backup
  6. USB Mobile Harddisk Preparation
  7. References

  1. Prerequisite

    1. Mondo Rescue software,
    2. blank DVDs or CD,
    3. One or more portable USB harddisk.

    Updated: 2007-04-04

    Back to top


  2. The Backup Strategy

    Disclaimer: The strategy outline here is a recommendation; it does not cover all circumstances and all hardware/software configurations. i.e. Don't blame us if it doesn't work for you.

    We divide the backup into two parts. DVD backup and harddisk backups. If the user data are small, say under 10 gigabytes; then the distinction is pointless. But on today's machine it is very common to have over 30 gigabytes of user data and that is alot of DVDs.

    The strategy is simple:

    1. Initially, do a full system backup with DVDs when user first install or acquired their machine, i.e. before user put personal data on it. Do this only once. Verify the full system backup, test it by reinstalling your machine with the full backups.
    2. From this point onward, do full system backup with harddisk periodically. Keep multiple version of the backups, keep critical data offsite in a secure location. That is it.

    DVD backups are bootable so that it can restore the OS and its settings. Harddisks necessary because it allows for large data set without needing an attendent to change disk.

    Lastly, It is recommended that users test their contingency plan once in a while during a control environment and not wait until a disaster happens and they find out something is missing or doesn't work.

    Updated: 2007-04-04

    Back to top


  3. Data Recovery

    The recovery process depends on whether a partial restore is required or a full restore is required. For example, if a harddisk crashed then a full restore is required. If a critical file was deleted, then a partial restore is needed.

    To restore partially, use the latest version of the harddisk backup and restore to disk according to Harddisk Recovery Using Mondo Rescue below.

    To restore in full, put the DVDs in the machine and boot to restore the system first. Then, plug in the portable harddisk and restore the latest data set.

    Warning Warning: backup data are not encrypted, if you have sensitive data you must keep it in a safe or a safety deposit box. Destroy deprecated backup media completely; without killing yourself in the process of course.

    Updated: 2007-04-04

    Back to top


  4. Initial DVD Backup

    Full system backup should be done when a new system is installed or acquired. We will be using Mondo Rescue as the full backup and restoration software.

    Mondo Rescue will create a set of bootable DVDs to completely restore the system including the OS and all its settings.

    To do a full system backup, you will need to login as root to use Mondo Resue (sudo will not work). Select Application->Accessories->Root Terminal, put in the root password, then from the root prompt run:

    # mondoarchive

    The following screen should appear.

    Screen of Mondo Rescue

    Full DVD Backup Using Mondo Rescue

    Procedures:

    1. press enter at the DVD Disk option,
    2. select Maximum Compression next,
    3. verify 4380 megabyte is the diskspace - it is,
    4. change the target device to /dev/dvd,
    5. select / - the root directory to indicate you want a full system backup.
    6. should you choose to leave something out, enter the exclude path next. Excluded paths will not be restore.
    7. select verify backup after Mondo has created the media.
    8. since we are using Debian 3.0+, we are sane. Choose Yes to continue.
    9. verify that you are ready to start.
    10. Mondo Rescue will prompt you to change disk, after it completed the backup, you will be asked to reinsert each disks for verification. This may take a few hours. Make sure you label the disks with sequence numbers, date/time and host name.

    Full DVD Restore Using Mondo Rescue Disks

    Warning

    Warning: full restore will destroy all existing data on disk, make sure you can use it before proceeding. Full restore will create partitions, format into original file system (ext2/3 or reisertfs, etc.) and restore the OS and user data.

    Procedures:

    1. Put the first disk into the bootable DVD drive,
    2. reboot the computer and after a few prompts, it will completely restore your system. This also may take a few hours,
    3. after the system was restored, boot into your recovered system and restore the most recent harddisk backup.

    Updated: 2007-04-04

    Back to top


  5. Regular Harddisk Backup

    Harddisk backup requires a portable usb harddisk with substantial size. Multiple harddisk is recommended. Rotate the harddisk with each backup. Don't carry all your backups during travel for obvious reasons. We will be using Mondo Rescue as the full backup and restoration software.

    Mondo Rescue will create a new data set containing the entire system. These data set is in ISO file system. It will appear on the harddisk as an .iso file. Multiple data sets can exist on the same portable usb harddisk.

    To do a harddisk backup, Select Application->Accessories->Mondo Rescue.

    The following screen should appear.

    Screen of Hardisk Mondo Rescue

    Full Harddisk Backup Using Mondo Rescue

    Procedures:

    1. select Harddisk and press enter,
    2. select Maximum Compression next,
    3. enter the mount point /media/usbdisk. Replace usbdisk with the actual volume name on your portable harddisk. If your harddisk is unformated, exit and jump to hardisk preparation section, come backup and start from begining when finished.
    4. For the harddisk space, either enter the free space left on the portable usb harddisk in megabytes or enter 512,
    5. Enter the ISO filename prefix (e.g. 20070411),
    6. select / - the root directory to indicate you want a full system backup.
    7. Enter these exclude paths: /sys /dev/ /var/cache /var/tmp /media. You may enter additional exclude paths. Excluded paths will not be backup. Screen of Hardisk Mondo Rescue Excluding Selected Paths
    8. select verify backup after Mondo has created the media.
    9. since we are using Debian 3.0+, we are sane. Choose Yes to continue.
    10. verify that you are ready to start.
    11. Mondo Rescue will do its thing and verify after backup. At the end it will try to burn it on CD and fail. But that is okay because it will be too big for any CD/DVD.
    12. Screen of Hardisk Mondo Rescue Completed

    This may take a few hours. Check existence on mounted volume with File Browser after completion.

    Screen of file browser

    Harddisk Restore Using Mondo Resue

    Warning

    Warning: restore will destroy existing data on disk, make sure you can use it before proceeding. You can restore partial files or the entire system.

    Procedures:

    1. Plug in the usb portable harddisk,
    2. Login as root to use Mondo Restore. Select Application->Accessories->Root Terminal, put in the root password, then from the root prompt run:
      # mondorestore
    3. select Harddisk and press enter,
    4. enter the mount point /media/usbdisk. Replace usbdisk with the actual volume name on your portable harddisk.
    5. enter the ISO filename prefix (e.g. 20070411) of the most recent dataset,
    6. navigate through the file list by press enter at <Less> or <More>.
    7. Screen of Hardisk Mondo Restore filelist
    8. Press enter at <Toggle> to select a file. Press the space bar on <OK> when finish.
    9. Enter the restoration path to restore to and press enter.
    10. Check the file after you finish.

    Updated: 2007-04-04

    Back to top


  6. References

    1. Linux Complete Backup and Recovery - How To from TLDP.org
    2. Mondo Rescue - How To - official guide.
    3. Gnome Partition Editor - official website containing documentations, faqs, etc.
    4. Chapter 12 - Backup and Restore from Debian GNU/Linux System Administrator's Manual

    Updated: 2007-04-04

    Back to top