dsmls

The dsmls command displays file information, such as sizes and state.

Specifically, the dsmls command displays the following information about a list of files:

  • Actual size (in bytes)
  • Resident size (in bytes)
  • Resident block size (in KB)
  • File state and recall mode
  • Name of the coupled Tivoli® Storage Manager server
  • File name

For a resident or premigrated file, the actual size and resident size are the same. For a migrated file, the actual size is the size of the original file. The resident size is the size of the stub file that remains on your local file system.

The file state for a file can have any of the following values: migrated (m), premigrated (p), or resident (r)). A dash - indicates a directory or a non-regular file; for example, a character special file or a named pipe file. For a migrated file, the dsmls command also indicates the recall mode that you set for the file:

  • If you set the recall mode to normal, additional information does not appear in the file state column.
  • If you set the recall mode to partial file recall, the notation (p) displays in the file state column.
  • If you set the recall mode to streaming, the notation (s) displays in the file state column.
Restriction:
  • Running dsmls or dsmdu on remotely mounted GPFS™ file systems might show incorrect values. Consider the following example:
Table 1. Space management for locally and remotely mounted file systems
Cluster A Cluster B
A space management client is installed A space management client is installed
File system A File system A (from Cluster A remotely mounted on Cluster B)
Mounted locally Mounted remotely
Space-managed by A Not Space-managed by B

Only file systems of the local cluster can be managed by HSM. The local Cluster A file system is space-managed by Cluster A, but cannot be space-managed by Cluster B, although it is remotely mounted on Cluster B. The Data Management Application Programming Interface (DMAPI) interface does not work for remotely mounted file systems, so incorrect values might be reported by dsmls or dsmdu.

Syntax

Read syntax diagramSkip visual syntax diagram
                           .------------------------------.   
                           V                              |   
>>-+-DSMLS-+--+---------+----+--------------------------+-+----><
   '-DLS---'  '-options-'    +-filespec-----------------+     
                             '- -FIlelist--=--file_path-'     

Parameters

options
ERRORLOGName=file_path
Specifies the path and file name of the error log file to be used by this command. Output from only this command is logged to the specified file. Other commands and daemons write output to the error log file specified by the errorlogname option in options file dsm.sys or dsm.opt, or as specified by the DSM_LOG environment variable. If any part of the path you specify does not exist, the space management client creates it.
Help
Displays syntax and options for the command. Do not specify other options when you specify the help option.
Noheader
Omits column headings from the output for this command.
Recursive
Displays information about files in subdirectories of the directory.
filespec
The path name for the files that you want to list. The default is all files in the current directory. Use wildcard characters to specify a group of files or all the files in a directory. You can enter more than one file specification in a command. If you enter several file specifications, separate each specification with one or more blank spaces.
FIlelist=file_path
Specifies the path of a file that contains a list of files to be processed by this command.
The entries in the list file must adhere to the following rules:
  • Each entry is a fully qualified path to a file or a relative path to a file.
  • No entry is a directory object.
  • Each entry is on a separate line.
The space management client ignores any entry that does not adhere to these rules.
The following rules apply to a file list for the space management client. These rules differ from the rules for backup-archive client file lists.
  • An entry can contain unprintable characters, but cannot contain a carriage return.
  • Wildcard characters are allowed.
  • A file path that contains blank spaces must be enclosed in quotation marks.
  • An entry that begins with a quotation mark and ends with a quotation mark is tolerated. The space management client assumes that the quotation marks are not needed and omits them when the space management client processes the entry. If beginning and ending quotation marks are required to identify the file, add double quotation marks before the beginning and after the end of the entry.
The following example shows a list of files within a list file:
  /home/dir/file1
  "/fs1/dir2/file3"
  "/fs2/my files/file4"
  ../tivoli/'file1'
  "'fs3'/dir3/'file.txt'"
  fs4/dir/a"file".txt
  '/fs4/dir/file.txt'
  /fs5/dir/file*with?wildcards.txt

If the list file name that you specify with the filelist option does not exist, the command fails.

Examples

Task Command
List all files in the current directory. dsmls
List all files in the /migfs2/test directory. dsmls /migfs2/test
List all files in the /migfs2/test directory and in its subdirectories. dsmls -Recursive /migfs2/test
List all files whose names begin with tf in the /migfs2/test directory. dsmls /migfs2/test/tf*
List all files in the list file named /tmp/filelist. dsmls -filel=/tmp/filelist