[plug] Reiserfs on Root: how I did it.

James Bromberger james at rcpt.to
Sun Apr 29 15:29:18 WST 2001



I have just transitioned my main Linux box to reiserfs on the root 
parition, and through I would share some of the experiences with you.


I was initially looking for a set of Debian boot disks that do this, but
despite several 2.4.3 + resier disks being made available recently, the
site that has them (somewhere at hypermart.net) seems to have 
disappeared.


The older disks are 2.2.17 with reiserfs, but reiserfs has undergone
some changes recently, and this image is too old. I'm only using the
unpatched 2.4 kernel and standard debian unstable reiserfs tools.


Here is my disk layout:
	20 GB old root drive: 50 MB /boot (ext2), / (ext2), and swap.
	27 GB Win2k drive (NTFS)
	40 GB new root driver: 50 MB /boot (ext2), swap, and / (reiserfs)


I am using devfs, but I'll use the traditional device file names here since
devfs is backwards compatible with the names.


My reason for this was badblocks on /dev/hda1, the old 20 GB disk's
boot parition.


I had looked at dbootstrap, which is supposed to be able to make a
Debian install on a target mount, However, after several attempts, it
seems that this tool just doesnt cut it. I had configured up and 
formatted the new disk (installed as /dev/hdc{1,2,3}), but debootstrap 
failed.


In the end, I used the following:

	mount -t reiserfs /dev/hdc3 /mnt
	mount -t ext2 /dev/hdc1 /mnt
	rsync -WDtrlpogxv --delete --delete-after --stats --progress / /mnt
	(wait a *long* while)
	vi /mnt/etc/fstab
	(change root parition from /dev/hda2 to /dev/hda3, and fs to 
	reiserfs, and options to include "notail")
	mkboot (create boot disk)
	mount -t ext2 /dev/fd0 /floppy
	vi /floppy/lilo.conf
	(change root parition to what it will be, hda3)
	lilo -b /dev/fd0 -C /floppy/lilo.conf (update floppy conf)
	halt (with floppy in drive, change the disks phycial wiring c<->a)
	(boot, with boot floppy)
	lilo  (install new boot block)


Note: I used rsync for the copy, and the "x" flag ensures that it only 
copies from the root parition. Some doco suggests:
	tar - dir dir dir| (cd /mnt; tar -xf -)

but I chose rsync because I could come back and update my duplicate afterwards 
(I was still using the machine ;) ).

And voila. Reiserfs on root. I have kept my boot parition as ext2 because
it seems there *may* be complications with lilo and booting from reiserfs
paritions this early.


Hope this helps for anyone contemplating a similar exercise. My new drive
was $340 - snap purchase when I started getting drive errors, so you may
be able to do better by shopping around at the moment.


My fsck.ext2 days are (almost, except for /boot) gone! ;)

  James

--
 James Bromberger <james_AT_rcpt.to> www.rcpt.to/~james

       * *  C u in Bordeaux - 1st Debian Conference, July 2001 * *
 Remainder moved to http://www.rcpt.to/~james/james/sig.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 227 bytes
Desc: not available
URL: <http://lists.plug.org.au/pipermail/plug/attachments/20010429/29a41a07/attachment.pgp>


More information about the plug mailing list