Networker

Re: [Networker] Disaster recovery plan using NetWorker

2008-03-17 10:18:01
Subject: Re: [Networker] Disaster recovery plan using NetWorker
From: Yaron Zabary <yaron AT ARISTO.TAU.AC DOT IL>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Mon, 17 Mar 2008 16:11:12 +0200
That is our Linux bare bone recovery HowTO (some of the thing are irrelevant, but it shows the basic procedure):

* Boot from Alon's LiveCD (CentOS4.4_legato.iso). If recovering to a xen based guest the config will look like that:

 boot = "d"
disk = [ "file:/images/repin.img,hda,w", "file:/root/CentOS4.4_legato.iso,hdc:cdrom,r" ]

    * Use ifconfig eth0 to assign an IP address.
    * Edit /etc/resolv.conf to add a nameserver and domain.
* Use fdisk to create partitions on your new hard disk (say /dev/hda1 for linux and /dev/hda2 for swap):

[root@repin ~]# fdisk -l

Disk /dev/hda: 255 heads, 63 sectors, 1274 cylinders
Units = cylinders of 16065 * 512 bytes

   Device Boot    Start       End    Blocks   Id  System
/dev/hda1             1      1095   8795556   83  Linux
/dev/hda2          1096      1274   1437817+  82  Linux swap

* Use mkfs.ext2 (or mkfs.ext3) to create a new file system on the partition you created.
    * Use mkswap on /dev/hda2.
    * Mount the new partition.
    * Start portmap:

/etc/init.d/portmap start

    * Start Legato's process:

/bin/nsrexecd -s legato.tau.ac.il

* Use recover -c client-name -s legato.tau.ac.il to recover the system (add / and then relocate to the mount point you created). Notice that sometimes when there are other file systems on the system, they need to be recovered seprately, as the 'add /' will not select files not in the root file system. * If you are trying to copy over a live machine (a-la P2V), you may use rsync to bring the files over. It is recommended that the following command will run when the source is in single user mode, and that you will manually mount all local file systems, ifconfig and sshd.

 rsync -v -rptgolDH --delete --exclude=/proc root@manray:/ /r

    * Use chroot to use the new file system as your root.
    * Fix /etc/fstab to reflect possible changes in file system layout.
    * Run mkdir /proc
* Use grub-install (or lilo) to install the boot loader. Make sure to fix /etc/grub.conf or /etc/lilo.conf to reflect changes to the disk layout.

NOTES:

* If you recover on a different hardware, make sure to run 'kudzu' and reconfigure it. * Update /etc/modprobe.conf (or /etc/modules.conf on older systems) if needed. Check in /etc/sysconfig/hwconf to know what modules are used for the newly found by kudzu devices. * If the recovered system is much older than CentOS4, the newly generated file system might have "unsupported features" and fail to run fsck. In this case, before running fsck, the file system should be fixed - there's a need to run:

debugfs -w /dev/hda1 -R "features ^resize_inode ^ext_attr"

* Some kernels might not have the kernel module for the Realtek 8139 Ethernet card provided. This will require compilation of the kernel module:

cd /usr/src/linux-2.4.23
make menuconfig

Choose to compile the modules for all Realtek 8139 related cards. Save the new configuration.

make dep
make modules
make modules_install

You may now run modprobe to see if the module is recognized.





Kenneth Holter wrote:
Hi.


I'm new to the list, as well as new to NetWorker.

We're using NetWorker to on our Red Hat Enterprise Linux 4/5 servers to
perform backup. I'm in need of a disaster recovery plan for our servers, and
could need some advice on how to use NetWorker for this purpose.

If a server chrashes or for some other reason goes down, I'll need to
replace the servers with a new one. Naturally, I must make sure that the new
server is identical to the old one, i.e. having the same partitions, files,
etc.

What is the best practice when it comes to this scenario? How can I make
sure that the new server is identical? I'm hoping there is a solution in
which I can boot the new server with a rescue CD, restore (the whole hard
drive including partitions) from the old server's backup, and that's it. I'm
not sure if this is at all realistic, but would very much appreciate
alternative approaches if not.

Regards,

Kenneth Holter

To sign off this list, send email to listserv AT listserv.temple DOT edu and type 
"signoff networker" in the body of the email. Please write to networker-request 
AT listserv.temple DOT edu if you have any problems with this list. You can access the 
archives at http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER


--

-- Yaron.

To sign off this list, send email to listserv AT listserv.temple DOT edu and type 
"signoff networker" in the body of the email. Please write to networker-request 
AT listserv.temple DOT edu if you have any problems with this list. You can access the 
archives at http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER

<Prev in Thread] Current Thread [Next in Thread>