4 assembling md devices for recovery (linux), 5 recovering md devices and logical volumes, Assembling md devices for recovery (linux) – Acronis Backup for Linux Server - User Guide User Manual

Page 27: Recovering md devices and logical volumes, P. 27)

Advertising
background image

27

Copyright © Acronis International GmbH, 2002-2014

3.6.4 Assembling MD devices for recovery (Linux)

In Linux, when performing recovery from a disk backup to an existing MD device (also called Linux
Software RAID), make sure that this device is assembled at the time of recovery.

If the device is not assembled, assemble it by using the mdadm utility. Here are two examples:

Example 1. The following command assembles the device /dev/md0 combined from the volumes
/dev/sdb1 and /dev/sdc1:

mdadm --assemble /dev/md0 -ayes /dev/sdb1 /sdc1

Example 2. The following command assembles the device /dev/md0 combined from the disks
/dev/sdb and /dev/sdc:

mdadm --assemble /dev/md0 -ayes /dev/sdb /dev/sdc

If the recovery requires the machine to be rebooted (usually, when the volumes to recover include
the boot partition), follow these guidelines:

If all parts of the MD device are volumes (a typical case, such as in the first example), make sure
that each volume type—called partition type or system ID—is Linux raid automount; the
hexadecimal code of this partition type is 0xFD. This will guarantee that the device will be
automatically assembled following the reboot. To view or change the partition type, use a disk
partitioning utility such as fdisk.

Otherwise (such as in the second example), perform the recovery from bootable media. No
reboot will be required in that case. In bootable media, you may need to create the MD device
manually or automatically, as described in Recovering MD devices and logical volumes (p. 27).

3.6.5 Recovering MD devices and logical volumes

Recovering MD devices and/or volumes created by Logical Volume Manager (logical volumes)
assumes that the corresponding volume structure will be recreated.

In Linux-based bootable media, you can choose to recreate the volume structure automatically (p.
28).

This functionality is intended primarily for bare-metal recovery of an entire machine. The software
backs up and recreates the entire logical volume structure, even if not all MD devices or logical
volumes are being backed up or recovered. Therefore, you need at least as many disks as the original
volume structure used.

Do not try to recreate the volume structure automatically in any of the following cases:

The machine has data that must be preserved. The software will destroy all data on the disks
that it chooses to recreate the volume structure on.

The machine has fewer physical disks than the original volume structure used. The software will
fail to recreate the volume structure even if the capacity of the physical disks is enough to fit all
the data being recovered.

The backup does not contain the volume structure information. This information might be
absent in backups created by Acronis Backup & Recovery 10, because saving it was optional.

In these cases, create the volume structure manually (p. 28) prior to recovery. You can do this by
using the mdadm and lvm utilities, either in Linux-based bootable media or in Linux.

Advertising