[Ilugc] reiserfs RHEL

  • From: girishvenkatachalam@xxxxxxxxx (Girish Venkatachalam)
  • Date: Wed Sep 27 14:42:18 2006

On Wed, Sep 27, 2006 at 01:57:21PM +0530, km wrote:

After compiling the kernel module, do i need to recompile mkfs ? to add 
support for reiserfs?

No need. If the kernel supports the file system mount automatically invokes the 
right file system routines reading the superblock magic.

I think your reqmt is not at all complicated. 

Just run these commands and you are done. Provided you have reiserfs support 
built into the kernel.

Figure out the device on which you wish to mount /home. Say /dev/hda2

Now, run this. You need reiserfstools package. 

#mkreiserfs /dev/hda2

#mount /dev/hda2 /home

#mount

Now, if you are able to see this line, you are done.
/dev/hda2 on /home  type reiserfs (rw)


After that, just add this line to your /etc/fstab file.
/dev/hda2       /home        reiserfs    rw,auto         0       1

This ensures that everytime you reboot the /dev/hda2 is mounted as /home 
partition.

You need to RTFM mount to know more, but this shud work.

I have attached my sample run for your reference. HTH.

(But don't do my way, I was just testing :-)

Best,
Girish

# dd if=/dev/zero of=reiser count=100024 bs=1024
100024+0 records in
100024+0 records out
102424576 bytes transferred in 7.271094 seconds (14086543 bytes/sec)

# losetup /dev/loop1 reiser 
# mkreiserfs /dev/loop1
mkreiserfs 3.6.19 (2003 www.namesys.com)

A pair of credits:
Edward Shushkin wrote the encryption and compression  file plugins,  and the V3
journal relocation code.

Vladimir Demidov wrote the parser for sys_reiser4(), the V3 alpha port, part of
the V3  journal  relocation code,  and helped  Hans keep  the business  side of
things running.


Guessing about desired format.. Kernel 2.6.17.3 is running.
Format 3.6 with standard journal
Count of blocks on the device: 24992
Number of blocks consumed by mkreiserfs formatting process: 8212
Blocksize: 4096
Hash function used to sort names: "r5"
Journal Size 8193 blocks (first block 18)
Journal Max transaction length 1024
inode generation number: 0
UUID: 12e7c933-fdcd-4710-a42b-175b15d932a4
ATTENTION: YOU SHOULD REBOOT AFTER FDISK!
ALL DATA WILL BE LOST ON '/dev/loop1'!
Continue (y/n):y
Initializing journal - 0%....20%....40%....60%....80%....100%
Syncing..ok

Tell your friends to use a kernel based on 2.4.18 or later, and especially not a
kernel based on 2.4.9, when you use reiserFS. Have fun.

ReiserFS is successfully created on /dev/loop1.

# mount /dev/loop1 /scratch/

#mount
/dev/hda2 on / type ext3 (rw,errors=remount-ro)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/hda4 on /storage type ext3 (rw,noexec,nosuid,nodev)
/dev/hda1 on /mnt type ntfs (ro,uid=1000)
tmpfs on /dev type tmpfs (rw,size=10M,mode=0755)
localhost:/var/lib/cfs/.cfsfs on /var/cfs type nfs 
(rw,port=3049,intr,nfsvers=2,addr=127.0.0.1)
/dev/sda on /usb type vfat (rw)
/dev/loop1 on /scratch type reiserfs (rw)


Other related posts: