Query Archive

The query archive command displays a list of your archived files and the following information about each file: file size, archive date, file specification, expiration date, and archive description.

If you use the detail option with the query archive command, the client displays the following additional information:
  • Last modification date
  • Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsLast access date
  • Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsLast file attributes (inode) change date
  • Windows operating systemsCreation date
  • Compression type
  • Encryption type
  • Mac OS X operating systemsWindows operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient-side data deduplication
  • Retention initiation
  • Whether the file is on hold
  • Linux operating systemsAIX operating systemsSize of ACL metadata (IBM Spectrum Scale), for AIX® and Linux® clients
  • Linux operating systemsAIX operating systemsServer storage information (media class, volume ID, and restore order), for AIX and Linux clients

The following example shows sample output when the query archive command is issued with the detail option:.

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systems
Size Archive Date - Time File - Expires on - Description
---- ------------------- -------------------------------
219 B 08/15/2016 09:32:13 /Volumes/Data/info.txt 08/16/2016
Archive Date: 08/16/2016
RetInit:STARTED Obj
Held:NO
Modified: 03/02/2016 19:43:00 Accessed: 03/03/2016 09:31:23 Inode changed: 03/02/2016 19:43:00
Compression Type: LZ4 Encryption Type: None Client-deduplicated: YES
ACL Size: 0  Media Class: Fixed  Volume ID: 0008  Restore Order: 00000000-0000001F-00000000-00600774
Windows operating systems
Size Archive Date - Time File - Expires on - Description
---- ------------------- -------------------------------
219 B 03/03/2016 09:32:13 \\halley\m$\tsm620c.0901fa\debug\bin\
winnt_unicode\dsm.opt 03/03/2016 
Archive Date: 03/03/2016 
RetInit:STARTED Obj
Held:NO
Modified: 03/03/2016 19:43:00 Created: 03/01/2016 15:31:23
Compression Type: LZ4 Encryption Type: None Client-deduplicated: YES

For more information about the compression type, see Compression.

Supported Clients

This command is valid for all clients.

Syntax

Read syntax diagramSkip visual syntax diagramQuery ARchive options filespec {filespacename}filespec filespec "filespec"

Parameters

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsfilespec
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsSpecifies the path and file name that you want to query. Use wildcard characters to specify a group of files or all the files in a directory. If you use wildcard characters, enclose the file specification in double quotation marks. Specify an asterisk (*) to query all archived files in the current directory.
Windows operating systemsfilespec
Windows operating systemsSpecifies the path and file name that you want to query. Use wildcard characters to specify a group of files or all the files in a directory.

If you include filespacename, do not include a drive letter in the file specification. Drive label names are only used for removable media.

Windows operating systems{filespacename}
Windows operating systemsSpecifies the file space (enclosed in braces) on the server that contains the file that you want to query. The file space is the name on the workstation drive from which the file was archived. The following example is valid for specifying a UNC name: {'\\machine\C$'}.
Use the filespacename if the name was changed or if you are querying files that were archived from another node with drive labels that are different from yours.
Note: You must specify a mixed or lowercase NTFS filespacename that is enclosed in quotation marks within braces, for example, {"NTFSDrive"}. Single quotation marks or double quotation marks are valid in loop mode. For example: {"NTFSDrive"} and {'NTFSDrive'} are both valid. In batch mode, only single quotation marks are valid.
Table 1. Query Archive command: Related options
Option Where to use
Windows operating systemsdateformat Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsdateformat Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
description Command line only.
detail Command line only.
dirsonly Command line only.
filelist Command line only.
filesonly Command line only.
fromdate Command line only.
fromnode Command line only.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsfromowner Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsCommand line only.
fromtime Command line only.
Windows operating systemsnumberformat Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsnumberformat Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
querysummary Command line only.
Windows operating systemsscrolllines Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsscrolllines Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
Windows operating systemsscrollprompt Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsscrollprompt Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
Windows operating systemssubdir Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemssubdir Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
Windows operating systemstimeformat Windows operating systemsClient options file (dsm.opt) or command line.
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemstimeformat Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsClient user-options file (dsm.opt) or command line.
todate Command line only.
totime Command line only.

Examples

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsTask
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsDisplay a list of all your archived files in the current working directory.

Command: q archive "*"

Windows operating systemsTask
Windows operating systemsDisplay a list of all your archived files in the c:\proj directory.

Command: q ar c:\proj\*

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsTask
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsDisplay a list of all your archived files in the /devel directory and all of its subdirectories.

Command: query archive "/devel/*" -subdir=yes

Windows operating systemsTask
Windows operating systemsDisplay a list of archived files from your c: drive with the description "January Ledgers".

Command: query archive c:\ -su=y -descr="January Ledgers"

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsTask
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsDisplay a list of all your archived files in the current directory. Use the dateformat and timeformat options to reformat the dates and times.

Command: q ar –date=5 –time=1 "*"

Windows operating systemsTask
Windows operating systemsDisplay a list of all your archived files in the c:\proj directory. Use the dateformat and timeformat options to reformat the dates and times.

Command: q ar –date=5 –time=4 c:\proj\*

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsTask
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsDisplay a list of all your archived files in the current directory. Use the detail option to display the last modification date and the last access date of each file.

Command: q ar -detail "*"

Windows operating systemsTask
Windows operating systemsDisplay a list of all your archived files in the c:\dir1 directory. Use the detail option to display the last modification date and the creation date of each file.

Command: q ar -detail c:\dir1\*

Windows operating systemsTask
Windows operating systemsDisplay a list of archived files in the c:\proj directory that contains a file extension of .dev. Use the dateformat and timeformat options.

Command: q ar –date=5 –time=4 c:\proj\*.dev

Windows operating systemsTask
Windows operating systemsRecently you changed the label of your c:\ drive to store and archive some files. Then, yesterday the label was changed to dev and some more files were archived. Display a list of all the files you archived in the c:\proj directory when the label was store.

Command: q ar {store}\proj\*

Windows operating systemsTask
Windows operating systemsRecently you archived files from a diskette labeled docs. Display a list of all the files you archived.

Command: q ar {docs}\*

Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsTask
Mac OS X operating systemsOracle Solaris operating systemsLinux operating systemsAIX operating systemsDisplay a list of archived files in the /home/proj directory whose first four characters of the file name begin with proj.

Command: q ar "/home/proj/proj*"