You can archive UNIX File System data and manage archiver stubs created by the old CDR driver or the new FAN driver by using the GXHSMUtil command line utility. Use this utility to test FAN and CXFS based FSDM implementations.
The utility is located in the software_installation_directory/Base folder. For example, /opt/commvault/Base/.
Print the Name of the Currently Configured Driver
To prints the name of the currently configured driver: FAN or CXFS, run the following command:
GXHSMUtil --get-driver
Example
# /opt/commvault/Base/GXHSMUtil --get-driver
FAN
Enumerate and Print All Locally Mounted Subsystems Being Watched for Changes
To enumerate and print all locally mounted subsystems that are also being watched for changes, run the following command:
GXHSMUtil --list
Example
# /opt/commvault/Base/GXHSMUtil --list
trigon.devemc.commvault.com:/nfsshare /trigon-nfsshare
/dev/mapper/centos_centos78a-home /home
centos78a:/opt/commvault/Base#
Start Monitoring FS Containing Specified File or Directory
To start monitoring FS containing the specified file or directory, run the following command:
GXHSMUtil --start-watch dnameExample
#/ opt/commvault/Base/GXHSMUtil --start-watch /extra
Stop Monitoring FS Containing Specified File or Directory
To stop monitoring FS containing the specified file or directory, run the following command:
GXHSMUtil --stop-watch dnameExample
#/ opt/commvault/Base/GXHSMUtil --stop-watch /extra
Check if Specified File is a Stub and Provide Output
To check if the specified file is a stub or not, and provide YES or NO outputs accordingly, run the following command:
GXHSMUtil --is-stub fnameExample
# /opt/commvault/Base/GXHSMUtil --is-stub ./installac.log
YES
Recursively Scan Specified Directory to Print Stub Names and Metadata
To recursively scan the specified directory and print the names of the stubs found with the enclosed metadata, run the following command:
GXHSMUtil --get-stub-report dirExample
# /opt/commvault/Base/GXHSMUtil --get-stub-report /home/archiver-SP37/.
/home/archiver-SP37/./AutoInstall.log: 1:190971474:188:429107:0:2:32:cf9ac0feb75b8abfbaeddbbeedd0c1b8:5319:6E894478-F06C-4127-AEA1-316B0F478424:2468713|1730509303
/home/archiver-SP37/./ClMgrS.log: 1:190971474:188:429107:244388:2:32:773c93f7b8f539a72ddaca3d0bcf6fa6:5319:6E894478-F06C-4127-AEA1-316B0F478424:3902312|1730509303
Pass the Specified Config Setting to the Driver
To pass the specified <name>=<value> config setting to the driver., run the following command:
GXHSMUtil --set-config name valueRemember Specified Short Names of Processes for Transparent Access to Monitored FS.
To remember the specified list of short names of processes that should have transparent access to all files on all monitored FS, run the following command:
GXHSMUtil --set-tprocs proc1 ... procNCheck if FS Containing Specified File or Directory and Provide Output
To check if the FS containing the specified file or directory is being monitored and provide YES or NO outputs accordingly, run the following command:
GXHSMUtil --is-watched dnameExample
# /opt/commvault/Base/GXHSMUtil --is-watched /extra
YES
# /opt/commvault/Base/GXHSMUtil --is-watched /space
NO
Add Volume Containing Specified File to be Automatically Monitored When Services Start
To add a volume containing the specified file or directory to the list of volumes that get automatically monitored whenever services start, run the following command:
GXHSMUtil --add-volume dnameRemove Volume with Specified File from being Automatically Monitored When Services Start
To remove a volume containing the specified file or directory from the list of volumes that get automatically monitored whenever services start, run the following command:
GXHSMUtil --del-volume dnameCheck if Specified File is a Stub and Provide Status and Embedded Metadata
To check if the specified file is a stub or not, and provide its status and embedded metadata as output, run the following command:
GXHSMUtil --read-stub fnameReplace Specified File Based on Conditions
Replace the specified file with a stub containing <meta>. If <ref_time> and <ref_inode> are not 0, they will be used to check that the current file's mtime and inode match before stubbing. Run the following command:
GXHSMUtil --stub-file fname meta ref_time ref_inodeNotify FSDM Driver to Treat Specified File as Regular File
To notify the FSDM driver that the specified file should be treated like a regular file rather than a stub, run the following command.
If <success> is "1" or is missing, the I/O for all processes waiting for the file to become unstubbed will resume, and the stub turns into a regular file. If <success> is "0", all waiting processes will get an I/O error, and the file remains as a stub.
GXHSMUtil --unstub-file fname [success]Produce Backup Image of Specified Stub and Store it in Backup.
To produce a backup image of the specified <stub> and stores it in <backup>, run the following command:
GXHSMUtil --backup-stub stub backupRestore Specified Stub Using Previously Obtained Stub Backup Image
To restore the specified stub using a previously obtained stub backup image, run the following command:
GXHSMUtil --restore-stub stub backupOpen Specified File in Transparent Mode and Pause Activity
To open the specified file in transparent mode and pause activity, run the following command:
GXHSMUtil --tran-open fnameLoop Waiting for New Recall Requests and Print Them
To loop waiting for new recall requests, get and print them to stdout, run the following command.
If --recall has been provided too, the requests are processed by writing bogus data into the files and unstubbing them.
Note: This does not involve ClMgrS, does not set up recall PL and does not bring back the actual data.
GXHSMUtil --poll [--recall]
Switch FS Containing Specified File to Strict Locking Mode
To switch the FS containing the specified file to "strict locking mode", run the following command.
This makes FSDM drivers on all cluster nodes clear their regular file caches and start probing actual file contents in every open().
GXHSMUtil --strict-lock-mode fnameRecursively Scan Specified Directory for Stubs and Attempt Recalls
To recursively scan the specified directory for stubs and attempt to trigger their recalls by reading the first few KB of data, run the following command.
Optional
The number of threads (default is 1) can be specified to stress-test the recall service.
Note: Contrary to the "--poll" option above, this brings the actual original file's data back. The utility does not talk to the driver directly and instead, pretends to be a regular application trying to open and read files. The names of all successfully recalled files are provided as output and the utility is aborted as soon as it runs into an error.
GXHSMUtil --recall dname [threads]