nfsstat -m lists all current nfs mounts, with the mount options.
authorNeil Brown <neilb@suse.de>
Fri, 6 Jun 2008 19:17:55 +0000 (15:17 -0400)
committerSteve Dickson <steved@redhat.com>
Fri, 6 Jun 2008 19:17:55 +0000 (15:17 -0400)
It does this by reading /proc/mounts and looking for mounts of type
"nfs".  It really should check for "nfs4" as well.

For simplicity, just check the first 3 characters of the type.

Signed-off-by: NeilBrown <neilb@suse.de>
Signed-off-by: Steve Dickson <steved@redhat.com>
utils/nfsstat/nfsstat.c

index aa6c961..d2cca8d 100644 (file)
@@ -716,7 +716,7 @@ mounts(const char *name)
                if (!(type = strtok(NULL, " \t")))
                        continue;
 
-               if (strcmp(type, "nfs")) {
+               if (strcmp(type, "nfs") && strcmp(type,"nfs4")) {
                    continue;
                }