wiki:Documentation

Version 5 (modified by Bruno Cornec, 14 years ago) ( diff )

--

This page is targetted at providing a more living documentation for MondoRescue vs the current HOWTO.

Backup

Restoration

Boot parameters

The file README.bootparam of the mindi package provides all the parameters one can use at boot time during a MondoRescue restoration.

pre and post parameters

In 2.2.9, mindi introduced 2 new parameters at boot prompt, pre and post. They are used to respectively launch a script just before launching mondorestore, and after its execution.

The main goal is to allow for the pre option to configure for example the HDD layout differently, and to re-configure the systems (static IP address e.g.) for the post option.

If the mastering of the target systems is regular, you can even create a /etc/mindi/mindi.conf configuration file on the master, which could redefine the MINDI_ADDITIONAL_BOOT_PARAMS variable of mindi like this:

cat >> /etc/mindi/mindi.conf << EOF
MINDI_ADDITIONAL_BOOT_PARAMS="devfs=nomount noresume selinux=0 barrier=off udevtimeout=10 pre=/tmp/isodir/pre.sh post=/mnt/RESTORING/tmp/post.sh"
EOF

Of course, these params can be passed at the boot prompt.

And the scripts could contain as an example:

cat > /path/to/nfs/pre.sh << EOF
sed -i -e "/vg02/ d" /tmp/mountlist.txt
sed -i -e "/vg03/ d" /tmp/mountlist.txt
EOF
cat > /tmp/post.sh << EOF
mount /proc
mount /sys
vgcfgrestore vg02
vgcfgrestore vg03
sed -i -e "s/IPADDR=.*/IPADDR=x.y.z.t/" /mnt/RESTORING/etc/sysconfig/network-scripts/ifcfg-eth0
EOF

Of course, those scripts could make more dynamic requests to improve the resulting deployment.

Manual restoration

In the case of a problem during restoration, you have to know that your data are stored in an open format so that you can lways have access to them.

A first way to do it is to use the mondorestore command manually on a system where it is installed, and point it to the media containing you data, and then interactively select the files you want to restore in the tree displayed and the place in which mondorestore will re-create them.

A second even more manual way to do it, is to mount your media (if not tape) and extract from it with afio the content you want to restore. A quick howto would be:

# mount /dev/hdb /cdrom

(or if you have the iso-image you use: mount -o loop mondo.iso /cdrom)

Locate the wanted files in /cdrom/archive/filelist.* If you want to find the file fstab:

# grep fstab /cdrom/archives/filelist.*

That might return something like this:

    /cdrom/archives/filelist.13:/etc/fstab

Once you know which number has your wanted files:

mkdir /tmp/mondoextract ; cd /tmp/mondoextract
cat /cdrom/archives/13.afio.lzo | cpio -idvm --verbose

If you used bzip2 instead of lzo, then unpack with:

afio -ZP bzip2 -i /cdrom/archives/13.afio.bz2
Note: See TracWiki for help on using the wiki.