Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

How can one explain multiple occurrence of /dev/root device containing different filesystems in /proc/mounts ?

# cat /proc/mounts
rootfs / rootfs rw 0 0
/dev/root / ext3 rw,data=ordered 0 0
/dev /dev tmpfs rw 0 0
/proc /proc proc rw 0 0
/sys /sys sysfs rw 0 0
/proc/bus/usb /proc/bus/usb usbfs rw 0 0
devpts /dev/pts devpts rw 0 0
/dev/hda1 /boot ext3 rw,data=ordered 0 0
tmpfs /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0
sunrpc /var/lib/nfs/rpc_pipefs rpc_pipefs rw 0 0
/etc/auto.misc /misc autofs rw,fd=7,pgrp=2161,timeout=300,minproto=5,maxproto=5,indirect 0 0
-hosts /net autofs rw,fd=13,pgrp=2161,timeout=300,minproto=5,maxproto=5,indirect 0 0
nfsd /proc/fs/nfsd nfsd rw 0 0
/dev/root /var/lib/nfs ext3 rw,data=ordered 0 0

OK. Here we have two. One for / partition (/proc/cmdline: ro root=/dev/VolGroup00/LogVol00) and one for /var/lib/nfs. BUT:

# ls -la /var/lib/nfs
total 68
drwxr-xr-x  8 root    root    4096 Aug  7 09:45 .
drwxr-xr-x 32 root    root    4096 Aug  3 09:32 ..
-rw-r--r--  1 root    root       0 Feb 25 16:26 etab
-rw-r--r--  1 root    root       0 Feb 25 16:26 rmtab
drwxr-xr-x  2 root    root    4096 Feb 25 16:26 rpc_pipefs
drwxr-xr-x  2 root    root    4096 Aug  7 08:03 sm
drwxr-xr-x  2 root    root    4096 Aug  7 08:03 sm.bak
drwxr-xr-x  4 root    root    4096 Aug  7 09:45 sm.ha
drwx------  4 rpcuser rpcuser 4096 Aug  3 06:52 statd
-rw-------  1 root    root       0 Feb 25 16:26 state
drwxr-xr-x  2 root    root    4096 Feb 25 16:26 v4recovery
-rw-r--r--  1 root    root       0 Feb 25 16:26 xtab

The contents of root filesystem and /var/lib/nfs is different. How could one block device /dev/root reflect different filesystems? And why /dev/root used for /var/lib/nfs at all?

share|improve this question

1 Answer 1

Sorry for bothering you but I've fount the answer myself by accident. /etc/mtab explains things:

# cat /etc/mtab
/dev/mapper/VolGroup00-LogVol00 / ext3 rw 0 0
proc /proc proc rw 0 0
sysfs /sys sysfs rw 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
/dev/hda1 /boot ext3 rw 0 0
tmpfs /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0
sunrpc /var/lib/nfs/rpc_pipefs rpc_pipefs rw 0 0
nfsd /proc/fs/nfsd nfsd rw 0 0
/var/lib/nfs /var/lib/nfs none rw,bind 0 0

/dev/root is also used for bind mounts. Don't ask me why /var/lib/nfs bind-mounted on top of itself :)

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.