Linux Physical System DR / Restore

Build the base system following using modifications noted here:

a. Disk Partitioning (create minimum of these four partitions):

i. boot (150 MB)

ii. / (1.5GB) Make sure that ‘/boot’ and ‘/’ are on the same physical drive

iii. /restore (At least same size as the original server; see the bridge doc)

iv. /restore/boot (See the bridge doc) Make sure that ‘/restore’ and ‘/restore/boot’ are on the same physical drive

v. Create the swap partition (See bridge doc)

vi. Create any other partitions per the bridge doc

b. Network Setup: (See the bridge doc)

i. Name: (See the bridge doc)

ii. IP: (See the bridge doc)

iii. Mask: (See the bridge doc)

iv. GateWay: (See the bridge doc)

v. DNS: (See the bridge doc)

vi. DNS2: (See the bridge doc)

vii. On Boot: Yes

c. Package Selection

i. Install a minimal package (RHAS 2.1) and the kernel development tools ( RHEL4 / RHEL3 / RHAS 2.1)

Install and configure the net backup client

From the Linux client server download the installation files as follows:

cd /tmp

wget Netbackup5.1/linuxclient.tar

Extract the installation files in /tmp with follwing commands:

tar xvpf linuxclient.tar

Install the NetBackup client into the /usr/openv directory structure with the following:

/bin/sh /tmp/bp/bin/client_config

Verify that the new client has the correct CLIENT_NAME entry in

/usr/openv/netbackup/bp.conf. Edit the bp.conf file if necessary.

Perform an alternate path restore:

d. Restore the system to /restore

build the new kernel

e. Examine /restore/boot/grub/grub.conf and determine the default kernel the system is running with i.e. vmlinuz-2.4.21-47.0.1.ELsmp

f. copy /restore/lib/modules/<DEFAULT KERNEL> directory to /lib/modules for example:

cp -r /restore/lib/modules/2.4.21-47.0.1.ELsmp/ /lib/modules/

g. build the new kernel image to the boot partition

i. cd /lib/modules

ii. uname -r to confirm Kernel Version

iii. mkinitrd /boot/initrd-<Kernel Version>-vmware.img <Kernel Version> i.e. initrd-2.4.21-47.0.1.ELsmp.img

Replace the modules.conf of the restored system with the base systems

h. cp /restore/etc/modules.conf /restore/etc/modules.conf.restore

i. cp /etc/modules.conf /restore/etc/modules.conf

Replace the sysctl.conf of the restored system with the base systems

j. cp /restore/etc/sysctl.conf /restore/etc/sysctl.conf.restore

k. cp /etc/sysctl.conf /restore/etc/sysctl.conf

Edit the grub configuration on the boot partition

l. Open /boot/grub/grub.conf in your favorite editor

m. Edit the existing default stanza changing the name of the kernel initrd image to the new initrd-<Kernel Version>-vmware.img

For example:

title Red Hat Enterprise Linux AS (2.4.21-47.0.1.ELsmp)

root (hd0,0)

kernel /vmlinuz-2.4.21-47.0.1.ELsmp ro root=LABEL=/

initrd /initrd-2.4.21-47.0.1.ELsmp.img

Edit the /restore/etc/fstab file

n. Comment out /restore and /restore/boot partition but do not comment out ‘/boot’ ‘swap’ ‘/’ ‘/mnt/cdrom’ ‘/mnt/floppy’ or any other file systems (like /backupfs) for which you created a physical partition in step 1

For example fstab should similar to following:

LABEL=/ / ext3 defaults 1 1

LABEL=/boot /boot ext3 defaults 1 2

/dev/sdb1 /u01 ext3 defaults 1 3

/dev/sdb2 /u02 ext3 defaults 1 4

/dev/sdc1 /apps ext3 defaults 1 5

/dev/sdd1 /backup_fs ext3 defaults 1 6

LABEL=/u03-logs /u03-logs ext3 defaults 1 7

LABEL=/u04 /u04 ext3 defaults 1 3

none /dev/pts devpts gid=5,mode=620 0 0

none /proc proc defaults 0 0

none /dev/shm tmpfs defaults 0 0

/dev/sda3 swap swap defaults 0 0

/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,r

o 0 0

/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0

Ora df output example:

/dev/sda2 9.8G 6.3G 3.1G 68% /

/dev/sda1 99M 46M 48M 50% /boot

/dev/sdb1 20G 8.2G 11G 44% /u01

/dev/sdb2 20G 12G 7.0G 63% /u02

/dev/sdc1 7.9G 5.1G 2.5G 68% /apps

/dev/sdd1 30G 9.0G 20G 32% /backup_fs

/dev/sde1 9.9G 1.5G 8.0G 16% /u03-logs

/dev/sdf1 9.9G 6.7G 2.8G 72% /u04

none 1.8G 0 1.8G 0% /dev/shm

o. Change the physical devices for the uncommented mount points to the correct new mount points

i. Where needed replace the labels with the actual names device id’s eg replace LABEL=/ with /dev/sda5 or /dev/ida/c0d0p4

From : LABEL=/ / ext3 defaults 1 1

To: /dev/sda2 / ext3 defaults 1 1

From: LABEL=/boot /boot ext3 defaults 1 2

To: /dev/sda1 /boot ext3 defaults 1 2

Reboot the Server.

No comments: