msls — List MSS directory contents.
msls [-project proj] [-class cos] [-full] [-CFPRSTVacdflpqrtuxz1] [path]
For each path operand that names an MSS file
(not a directory), msls writes the name of the file as well as any associated
information that is also requested. For each path operand that is a
directory, msls writes the names of the MSS files contained
within that directory and associated information you requested.
If no operands are specified, the contents of the current MSS working
directory, (the NCAR_MSSPWD environment variable), are written.
If more than one operand is
specified, filenames will be written first; directory names will
be written second.
Because of the way option processing is done, the msls
command as run by the DCS server will have the options specified by you in the
order shown in the synopsis, regardless of the order (or number of times)
you specify them. For options that are mutually exclusive, the
last option specified is used. For example, both
msls -C1
and filemsls -1C behave as though
filemsls -C1
was specified, with the file-1 option taking precedence.
proj
Supply proj as the project number for
charging. Currently, no charging is done for metadata operations, so
this option is a placeholder for when charging might be imposed.
cos
Supply cos as the list of class of service categories to display
instead of the modification time. The categories are those listed in the
msclass(1NCAR) man page, separated by commas if more than one is present. The corresponding
values will be listed in the same order as their respective keys as given
in cos, separated by commas.
The output values will be abbreviated by default.
Display the full (non-abbreviated) values for the classes of service selected
by the -class option.
Write multi-text-column output with entries sorted down the
columns, according to the ASCII collating sequence. This is the
default. A width of 80 columns is assumed. Mutually exclusive with
-1 (the numeral 1), and -l (the letter l).
Write a slash (/) immediately after each pathname that is a directory.
Use the projected purge date instead of the last modification
time for sorting (-t) or writing (-l).
(This is the last access time plus the retention period.) Mutually exclusive with
-c, -u, -p, and -z.
The -P option forces the long output format (-l).
Note that you must also use the -t option to enable sorting by
projected purge date.
Recursively list subdirectories encountered.
Sort by size, largest file first.
Display complete time information for the file, including month, day, hour, minute, second, and year. This is only effective if a long output format is automatically selected by another option.
Print out version number(s) of the software.
Has no effect, but is provided for compatibility.
The default is to write out all directory entries, including those whose names
begin with a period (.).
Use the last reference time (last touch,
read, or write)
instead of the time of the last modification (write) for sorting
(-t) or writing (-l). Mutually exclusive
with -P, -p, -u, and -z.
The -c option forces the long output format (-l).
Note that you must also use the -t option to enable sorting by
last reference time.
Do not treat directories differently than files; that is, do not list the contents of a directory specified as a operand.
Output is not sorted.
(The letter l.) Write out in long format (see below).
The -l option forces the output to be one entry per
line (-1).
Use the retention period (in days) instead of the last
modification time for sorting (-t) or writing (-l).
Mutually exclusive with -c, -u,
-z, and -P.
The-p option forces the long output format (-l).
Note that you must also use the -t option to enable sorting by
retention period date.
Force each instance of non-printable pathname characters and
tab-key characters to be written as "?"
(the question-mark character).
Reverse the order of the sort, to be oldest first.
Sort by time modified (most recently modified first) before
sorting the operands by the ASCII collating sequence. Required to enable
sorting by retention period (if -p is also selected),
projected purge date (if -P is also selected) or other
file times (if -c or -u are selected).
Use time of last access (read) instead of last modification
time for sorting (-t) or writing (-l).
Mutually exclusive with -c, -p,
-z, and -P.
The -u option forces the long output format (-l).
Note that you must also use the -t option to enable sorting by
last access time.
Print the MSS file comment. The comment will follow the pathname
and is separated from the pathname by two spaces and a colon.
The -x option forces the long output format (-l).
Use the estimated days until purge instead of the last
modification time for sorting (-t) or writing
(-l). Mutually exclusive with
-c, -p, -u,
and -P. The -z option forces
the long output format (-l). The
creation time of the file is displayed instead of the modification time.
The estimated days until purge is inserted between the creation time
field and the name field.
(The numeral 1.) Force output to be one entry per line.
path
A pathname. If path is
not found, a diagnostic message will be written to
standard error.
If a long output format is selected, information is written in the following fields, in this order for directories:
2)
0)
00000000)
0)
0, with a project number of
00000000.
For files:
If the -p option is specified, the date and time are replaced by
the retention period in days.
If the -z option is specified, the estimated days until purge is
added between the date and time field and the pathname field.
If the time is later than some date in the year 2037 (typically when the
projected purge date is displayed by the -P option), the date will
be replaced with "After 2037". This is because the
UNIX/POSIX time of day rolls over in 2037. If the time is zero
(for a file that has never been referenced), the date will be
replaced with "Never read".
When using the -P option, directories
will have the date replaced with "Not purgeable".
If a file has a read password, the other read permission will not be set. Likewise, the other write permission will not be set if a write password is present.
Example 18. List MSS files sorted by size.
msls -lRS /AUSER
Typical output:
total 0 -rw----rw- 1 AUSER 01234567 197955 Dec 8 11:01 abcd -rw-----w- 1 AUSER 01234567 24576 Dec 6 15:45 file drwx---rwx 2 0 00000000 0 Nov 29 09:46 test1 drwx---rwx 2 0 00000000 0 Aug 15 06:40 ibmhippi drwx---rwx 2 0 00000000 0 Nov 24 1993 NASABENCHMARK /AUSER/test1: total 0 -rw----r-- 1 AUSER 01234567 24576 Nov 29 09:46 foo /AUSER/ibmhippi: total 0 -rw----r-- 1 AUSER 01234567 634880 Aug 15 06:44 ipi_hippi -rw----r-- 1 AUSER 01234567 317440 Aug 15 06:40 hippi -rw----r-- 1 AUSER 01234567 126976 Aug 15 06:42 hippimc /AUSER/NASABENCHMARK: total 0 -rw----r-- 1 AUSER 01234567 663290 Nov 24 1993 mac-hfs-floppy.Z -rw----r-- 1 AUSER 01234567 153039 Nov 24 1993 npb.r3.1.tar.Z -rw----r-- 1 AUSER 01234567 130111 Nov 24 1993 iobm-v0.2.tar.Z
Example 19. List MSS files sorted by various fields.
msls -l /PAT/ocean # Sort by name msls -lS /PAT/ocean # Sort by size msls -lt /PAT/ocean # Sort by time modified msls -Pt /PAT/ocean # Sort by estimated purge date msls -ct /PAT/ocean # Sort by last referenced date msls -pt /PAT/ocean # Sort by retention period msls -ut /PAT/ocean # Sort by last read date msls -zt /PAT/ocean # Sort by estimated days until purge
Example 20. Display the file comment after the file name.
msls -lX fileTypical output:
-rw-----w- 1 AUSER 01234567 24576 Dec 6 15:45 file :A comment
Example 21. Display class of service information.
msls -R -class rel,usa /AUSER/COSTypical output:
total 140 -rw----rw- 3 AUSER 01234567 71680 ec,ba newfile drwx---rwx 2 0 00000000 0 subdir /AUSER/COS/subdir: total 220 -rw----rw- 3 AUSER 01234567 56320 st,no f1 -rw----rw- 3 AUSER 01234567 56320 ec,no f2 drwx---rwx 2 0 00000000 0 foo /AUSER/COS/subdir/foo: total 110 -rw----rw- 3 AUSER 01234567 56320 ec,no f3
See Environment Variables section of the Command Behavior and Envrionment chapter for details.
See Exit Status Codes section of the Command Behavior and Environment chapter for details.