VOLSCAN(8) | AFS Command Reference | VOLSCAN(8) |
volscan - Produces detailed information about AFS volumes
volscan
[-checkout]
[-partition <AFS partition name or id>]
[-volumeid <Volume id>]
[-type <Volume types (rw, ro, bk)>+]
[-find <Objects to find (file, dir, mount, symlink, acl)>+]
[-output <Column>+]
[-delim <Output field delimiter>]
[-noheading]
[-ignore-magic]
[-help]
The volscan command displays volume meta-data stored on AFS file servers. The output is intended for debugging purposes and is meaningful to someone familiar with the internal structure of AFS volumes. The volscan command must be issued directly on a file server machine as the root superuser. The volscan command does not modify volume information.
The volscan command will produce output for all the volumes on the file server by default. To display output for the volumes in one partition only, include the -partition argument. To display output for one volume only, include the -partition and -volumeid arguments.
The volscan command will produce output for read-write, read-only, and backup volumes by default. To limit the output to particular types of volumes, include the -type argument with one or more volume types ("rw", "ro", "bk").
The volscan command will produce output for each type of vnode object found in the volumes scanned. The command will output information for files, directories, AFS mount points, and symbolic links by default. The volscan command can output access control lists (ACLs) for directory vnode objects scanned. To limit the output to particular types of vnode objects, or to output access control lists (ACLs), include the -find argument with one or more object types ("file", "dir", "mount", "symlink", "acl").
The output of the volscan command is tabular. The output consists of an optional heading line, followed by zero or more lines of delimiter separated values. By default, the output values are the file server hostname ("host"), the object type ("desc"), the vnode FID ("fid"), the vnode data version ("dv"), and the directory path ("path"). The directory path is relative to the root directory of the volume. When "acl" is included as an argument to "-find", the default output values also include the user/group id ("aid") and the access rights ("arights"). To specify different output values, include the "-output" argument with one or more column names. See OUTPUT for the column names.
Values are space delimited by default. To use a different delimiter character, include the -delim argument. Include the -noheading flag to suppress the output heading line.
This argument can be omitted if the current working directory is the mount location for an AFS server partition. If the current working directory is not the mount location for an AFS server partition, the command produces output for every volume on all local AFS server partitions.
The default output columns are the file server hostname ("host"), the object type ("desc"), the vnode FID ("fid"), the vnode data version ("dv"), and the directory path ("path"). When "acl" is included as an argument to "-find", the default output values also include the user/group id ("aid") and the access rights ("arights").
The following column names are valid for the -output argument:
The following command displays the FID, data version, and relative path for each vnode object in a volume.
# volscan -partition a -volumeid 536870916 HOST DESC FID DV PATH fs1 dir 536870916.1.1 3 / fs1 mount 536870916.2.2 0 /test fs1 mount 536870916.4.3 0 /xyzzy
The following command displays the AFS mount points in all the read-write volumes on the file server. For each mount point the following is shown: the volume containing the mount point, the type of mount point, regular ("#") or read-write ("%"), the target cell (or "-" if not a cellular mount point), the name of the target volume, the path of the mount point within the volume (relative to the volume root directory).
# volscan -type rw -find mount -output vid mtype mcell mvol path -noheading 536870915 # - test /test 536870912 # example.com root.cell /example.com 536870912 % example.com root.cell /.example.com
The following command displays access control lists for a volume.
# volscan -partition a -volumeid 536870918 -find acl \ -output fid aid arights path -delim : -noheading 536870918.1.1:-204:+rlidwka:/ 536870918.1.1:-101:+rl:/ 536870918.3.3:-204:+rlidwka:/xyzzy 536870918.3.3:-101:+rl:/xyzzy 536870918.3.3:1027:+rlidwk:/xyzzy
The following commands find files which have unix permissions bit 04000 ("suid") or 02000 ("sgid"):
# volscan -find file -output fid mode -noheading | \ perl -lane 'print if oct($F[1]) & 06000'
The issuer must be logged in as the local superuser "root".
Copyright 2014 Sine Nomine Associates. All Rights Reserved.
This documentation is covered by the BSD License as written in the doc/LICENSE file. This man page was written by Michael Meffie for OpenAFS.
2022-12-22 | OpenAFS |