diff options
author | iedowse <iedowse@FreeBSD.org> | 2003-07-18 17:43:13 +0000 |
---|---|---|
committer | iedowse <iedowse@FreeBSD.org> | 2003-07-18 17:43:13 +0000 |
commit | 5502303d772f926e775bfaf06a469b714fcae0cf (patch) | |
tree | 772d8d08438bc69dc11be45347c350d3f3aa2539 /sbin/mount/mount.c | |
parent | 8e8000965f7d1e6948aa129479a27405d8ef5914 (diff) | |
download | FreeBSD-src-5502303d772f926e775bfaf06a469b714fcae0cf.zip FreeBSD-src-5502303d772f926e775bfaf06a469b714fcae0cf.tar.gz |
When mount(8) is invoked with the `-v' flag, display the filesystem
ID for each file system in addition to the normal information.
In umount(8), accept filesystem IDs as well as the usual device and
path names. This makes it possible to unambiguously specify which
file system is to be unmounted even when two or more file systems
share the same device and mountpoint names (e.g. NFS mounts from
the same export into different chroots).
Suggested by: Dan Nelson <dnelson@allantgroup.com>
Diffstat (limited to 'sbin/mount/mount.c')
-rw-r--r-- | sbin/mount/mount.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sbin/mount/mount.c b/sbin/mount/mount.c index bb4579d..6cfe79b 100644 --- a/sbin/mount/mount.c +++ b/sbin/mount/mount.c @@ -508,7 +508,7 @@ void prmount(sfp) struct statfs *sfp; { - int flags; + int flags, i; struct opt *o; struct passwd *pw; @@ -535,6 +535,9 @@ prmount(sfp) if (sfp->f_syncreads != 0 || sfp->f_asyncreads != 0) (void)printf(", reads: sync %ld async %ld", sfp->f_syncreads, sfp->f_asyncreads); + printf(", fsid "); + for (i = 0; i < sizeof(sfp->f_fsid); i++) + printf("%02x", ((u_char *)&sfp->f_fsid)[i]); } (void)printf(")\n"); } |