[NTLUG:Discuss] Bash script way to tell if a filesystem is mounted

Hank Ivy hankivy at hot.rr.com
Sat May 29 11:07:48 CDT 2010


On Saturday 29 May 2010 09:28 am Ralph Green wrote:
>  If a directory and its parent  
>  have the same filesystem identifier, then that directory
>  is not a filesystem mount point.

What will happen if you have multiple levels of mount points?

For Example (in /etc/fstab):
/dev/md17 /home2 ... 3
/dev/md18 /home2/userx ... 4

The 3 and the 4 control the order of the mounts.
If neither file system is mounted, will the return values be the same?

-- 
Hank Ivy

GPG Fingerprint:
1A0F E1CB 0160 0069 7C19 4B00 911C 92E8 F8B0 4C7C



More information about the Discuss mailing list