[PVFS-developers] PVFS and mount

Robert Ross rross@mcs.anl.gov
Mon, 23 Oct 2000 11:28:25 -0500 (CDT)


Hey,

I checked into how mount works a bit more.  Here's what I found:

- mount is part of util-linux (if you're looking for it try:
ftp.win.tue.nl:/pub/linux/util),

- There is already support in the "mount" binary for calling external
programs to mount file systems.  It does so for smb and ncp types.  

- Around line 569 of mount.c, there are defines which determine if mount
will try to call an external program for any unknown type, or just for a
couple of known ones.  If we were to compile mount with ALWAYS_STAT
defined, it would try to call /sbin/mount.pvfs when it encountered a PVFS
fs type.  This path is hardcoded in, presumably to avoid users trying to
exploit mount.

- /sbin/mount.smb is a shell script that actually calls smbmount.  From
this it is pretty easy to discern that the arguments are of the form:
<executable> <remote fs> <local dir> -o <options>

Example:
  /sbin/mount.pvfs ccsto1:/pvfs /mnt/pvfs -o port=3000,rw

So with a little bit of work on mount.pvfs and a #define in mount, we
should be able to get mount to do all the mtab stuff for us.

Any takers?

Maybe we'll eventually have enough credibility that we can get into the
short list of file systems with external support :).

Rob
---
Rob Ross, Mathematics and Computer Science Division, Argonne National Lab