[NCLUG] ext3 versus ReiserFS?

John L. Bass jbass at dmsd.com
Wed Oct 24 18:30:20 MDT 2001


	I've found that creating a small ext2 root filesystem on another
	partition comes in handy if you run into problems with your reiser
	filesystem.  Just make sure the kernel on the ext2 filesystem supports
	reiserfs and has the necessary reiserfs debug tools.  With the price of
	large drives these days, I don't see this being a problem.

	Bryan

Most good large system admins have used dual root installs for years to minimize
server downtime. Put full base system into one root, reinstall a second idential
partition, and make sure that everything except the base OS install goes into
/export or some other facility standard partition. Setup lilo to boot either
root partition:

	[root at cwx.net /root]# cat /etc/lilo.conf
	boot=/dev/hda
	map=/boot/map
	install=/boot/boot.b
	prompt
	timeout=50
	message=/boot/message
	linear
	default=linux
	
	image=/boot/vmlinuz-2.2.16-22
	        label=linux
	        read-only
	        root=/dev/hda2
	
	image=/boot/vmlinuz-2.2.16-22
	        label=recover
	        read-only
	        root=/dev/hda1
	
Setup a script to backup key configuration and admin file to recover:

	[root at cwx.net /root]# cat backup2recover
	#!/bin/sh
	# backup only files to be transfered to /recover
	# DO NOT overwrite config files specific to /recover as root filesystem
	
	cd /
	mount /recover
	tar cvf /tmp/backup2recover.tar --totals \
	                etc/HOSTNAME \
	                etc/aliases \
	                etc/group \
	                etc/hosts* \
	                etc/httpd/conf \
	                etc/inetd.conf \
	                etc/named.conf \
	                etc/ntp* \
	                etc/passwd \
	                etc/rc.d/rc.local \
	                etc/rc.d/init.d/CWX* \
	                etc/resolv.conf \
	                etc/sendmail.* \
	                etc/shadow \
	                etc/smb.conf \
	                etc/sysconfig/network \
	                etc/sysconfig/network-scripts/ifcfg-eth[012]* \
	                etc/sysconfig/static-routes \
	                etc/syslog.conf \
	                root/backup* \
	                root/chains \
	                usr/local/mrtg \
	                var/named \
	                var/spool/cron
	
	cd /recover
	rm -f etc/sysconfig/network-scripts/ifcfg-eth[012]*
	tar xvf /tmp/backup2recover.tar
	rm -f /tmp/backup2recover.tar
	umount /recover

Each facility has there own config standards, but the above should be a good
starting point. Rsync is also good, but takes some serious hacking with exclude
lists to safely avoid things like /dev directories and /etc/fstab which are
very specific to a particular root partition.
	
This approach is particularly useful for linux router/firewalls, since you can
get the router/firewall back online with a reboot, then play with the bad filesystem
with traffic flowing. It's a little tougher with mail/web servers since you need
to syncronize/recover databases and spool directories before starting the servers
on the recover partition.

John



More information about the NCLUG mailing list