admfsinfo(1M) DG/UX 5.4.2 admfsinfo(1M)
NAME
admfsinfo - display information about files and directories
SYNOPSIS
admfsinfo -o find [ -a days ] [ -m days ] [ -n name ] [ -t type ] [
-b bytes ] [ -u user ] [ -g group ] [ -flqv ] [ -c count ]
[ -s how ] [ directory ... ]
admfsinfo -o check [ -lqv ] [ directory ... ]
admfsinfo -o diskuse [ -lqv ] [ directory ... ]
DESCRIPTION
admfsinfo displays information about files and file systems.
Operations
find Display all files in directory and its sub-directories
which match all of the specified attributes. At most count
lines are produced. Output can be sorted either by file
size, last access or modification time, or by name. If not
specified, directory defaults to the root directory.
check Display all files in directory and its sub-directories
which are "suspicious" from an administrator's view point.
These files should be inspected as possible administration
errors or security breaches. Two problems are reported -
(1) device files outside of /dev and (2) files owned by
root with the setuid mode enabled. If not specified,
directory defaults to the root directory.
diskuse Display the total number of blocks and inodes and the
number of free blocks and inodes of each mounted file
system. The percentages of blocks and inodes that are in
use are also reported. If directory is specified,
statistics are reported only for the file system containing
the specified directory. Otherwise, information about all
file systems is reported.
Options
The following options are accepted with the find operation:
-a days Minimum number of days since last access.
-m days Minimum number of days since last modification.
-n name Simple file name (shell wildcard characters may be used if
quoted).
-t type Type of file (see find(1)).
-b bytes Minimum size in bytes.
-u user Owner's login name or uid.
Licensed material--property of copyright holder(s) 1
admfsinfo(1M) DG/UX 5.4.2 admfsinfo(1M)
-g group Owner's group name or gid.
-f Restrict the search to the file system containing the
directory.
-c count Maximum number of lines of output, not including the header
line (default is unlimited).
-s how How to sort, one of the following:
accessed time of last access, oldest first
accessed:r
time of last access, newest first
modified time of last modification, oldest first
modified:r
time of last modification, newest first
size file size, largest first
size:r file size, smallest first
name file name
If this option is not specified, the output will be
unsorted.
All operations allow the following:
-l Consider only local file systems, excluding remote mounted
file systems.
-q Quiet, do not print headers or extraneous information in
reports.
-v Verbose, include headers and additional report information
(this option is enabled by default).
OUTPUT
The find operation displays the following information, one line per
file, for each file that meets the selection criteria:
- owner of the file
- file size in bytes
- last access day and time
- file name
The check operation displays the following information, one line per
file, for each file with a suspected security problem:
- problem identification
- file name
The diskuse operation displays the following information, one line
per file system:
- file system name
- number of free inodes
Licensed material--property of copyright holder(s) 2
admfsinfo(1M) DG/UX 5.4.2 admfsinfo(1M)
- total inodes
- percent of inodes in use
- number of free blocks
- total blocks
- percent of blocks in use
EXAMPLES
To show the 25 largest regular files owned by root on all local file
systems, use:
admfsinfo -o find -l -u root -t f -s size -c 25
To show the 50 largest regular files in the /opt and /usr/opt file
systems, last accessed more than one day ago, use:
admfsinfo -o find -t f -a 1 -s size -c 50 /opt /usr/opt
DIAGNOSTICS
Warnings
- Some (but not all) directories specified for the find or check
operations do not exist of cannot be examined.
Errors
- Cannot create a temporary file.
- Directory specified for the diskuse operation does not exist
or cannot be examined.
- All directories specified for the find or check operations do
not exist or cannot be examined.
Exit Codes
0 The operation was successful.
1 No files were found to match the selection criteria; all
specified directories do not exist or cannot be examined.
2 The operation failed due to access restrictions.
3 There was an error in the command line.
REFERENCES
The find operation handles the fileage (-m), filename (-n), and
filesize commands of osysadm(1M). fileage sorts by time (-s time)
and defaults to 90 days (-m 90). filesize sorts by size (-s size)
and defaults to printing the 10 largest (-c 10) regular files (-t f).
filename is unsorted. The current filesize uses a separate utility
to provide the size information for the sort.
The check operation handles osysadm's filescan commands.
The diskuse operation handles osysadm's diskuse command. The
specification of a directory is new.
Licensed material--property of copyright holder(s) 3
admfsinfo(1M) DG/UX 5.4.2 admfsinfo(1M)
SEE ALSO
df(1M), du(1), find(1), sysadm(1M).
Licensed material--property of copyright holder(s) 4