Quantum StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Made in the USA. Quantum Corporation provides this publication “as is” without warranty of any kind, either express or
implied, including but not limited to the implied warranties of merchantability or fitness for a particular purpose. Quantum
Corporation may revise this publication from time to time without notice.
Quantum, the Quantum logo, DLT, DLTtape, the DLTtape logo, Scalar, and StorNext are registered trademarks of Quantum
Corporation, registered in the U.S. and other countries. Backup. Recovery. Archive. It’s What We Do., the DLT logo, DLTSage,
DXi, DXi-Series, Dynamic Powerdown, FastSense, FlexLink, GoVault, MediaShield, Optyon, Pocket-sized. Well-armored, SDLT,
SiteCare, SmartVerify, StorageCare, Super DLTtape, SuperLoader, and Vision are trademarks of Quantum. LTO and Ultrium are
trademarks of HP, IBM, and Quantum in the U.S. and other countries. All other trademarks are the property of their respective
companies. Specifications are subject to change without notice.
3Contents
Quantum StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
4Contents
Introduction
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Quantum recommends using the GUI to complete most StorNext tasks, but
there might be situations where you prefer or need to use the command line
interface (CLI) instead.
This document describes commonly used StorNext File System (SNFS) and
StorNext Storage Manager (SNSM) commands. For each command, the
following information is provided:
• Description of what the command does and how it is used.
• Command syntax that shows how to compose the command.
• List of the options and arguments of the command.
Note: Some descriptions also include command examples.
This document contains the following sections:
• Viewing man Pages on page 5
• File System Commands on page 6
• Storage Manager Commands on page 20
• Contacting Quantum on page 62
On a Windows Vista system, when you run applications from the command line
that require administrative privileges, you can start the CLI application either
from an elevated shell environment or a DOS shell.
Note: For Windows Vista users only: If the CLI application is started from an
Viewing man Pages
This document summarizes information from the man pages for the included
SNFS and SNSM commands. The man pages contain detailed usage information
and examples for many StorNext commands.
alternative shell (such as those provided by cygwin,) you
that shell in an elevated mode. If you do not, CLI commands requiring
administrative privileges will fail and you will receive an error message
indicating that you do not have sufficient privileges to run the
command. To start the shell in elevated mode, right-click the icon for
Command Prompt or Cygwin and select Administrative Mode.
must
start
Use the following procedure to view the man page for a command.
1 Source the StorNext profile. Do one of the following:
•If using the bash shell, at the command prompt, type:
source /usr/adic/.profile
Introduction5
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
•If using the csh or tcsh shell, at the command prompt, type:
source /usr/adic/.cshrc
2 View the man page for a command. At the command prompt, type:
man <command>
where <command> is the command for which you want to view the man
page.
3 Press <Spacebar> to page through the man page.
4 When you are finished, type q and press <Enter> to exit the man page.
Note: Paging through man pages may work differently depending on the
File System Commands
viewer specified by the $PAGER environmental variable.
This section describes the following StorNext File System commands:
• cvadmin on page 6
• cvaffinity on page 10
• cvcp on page 11
• cvfsck on page 13
• cvfsid on page 14
• cvlabel on page 15
• cvmkdir on page 17
• cvmkfile on page 17
• cvmkfs on page 18
• cvupdatefs on page 19
• cvversions on page 20
cvadmincvadmin is an interactive utility used for general administration of a file system.
With cvadmin, you can display file system and client status, activate a file
system, view and modify stripe group attributes, administer user and group
quotas, and perform other administrative tasks.
Invoke cvadmin to start an interactive session, and then use cvadmin
commands to display and modify the active SNFS configuration. Changes
remain in effect as long as the current FSM (file system manager) is running. To
make permanent changes, edit the configuration file.
In cvadmin interactive mode (snadmin), several commands use name as an
argument. For example, the select, start, and stop commands use
file_system_name as an argument and the up and down commands use the
stripe group (groupname) as an argument. If the value of file_system_name or
groupname is identical to the snadmin command name or command keyword,
then use double quotation marks on the command argument. For example, to
start a file system named quotas where “quotas” is the snadmin command
name, the syntax is:
snadmin (localfs) > start “quotas”
Additionally, snadmin command keywords must use double quotation marks if
they are used as quota user or group names. For example, user is a snadmin
command keyword, so it would need double quotation marks:
snadmin (localfs) > quotas set group “user” 11G 10G 1440
When creating a group quota, you cannot name the group “user”.
Ta b l e 1 O p t i o n s a n d
Arguments: cvadmin
Note: cvadmin no longer supports the enable or disable commands. To
enable or disable a file system for reads/writes, modify the
configuration file and then restart the FSM.
Options / Arguments
Tab l e 1 lists options and arguments for the cvadmin command. Commands that
can be used in interactive mode are also listed.
Note: You must quote commands with more than one word. For example:
cvadmin -e ‘start snfs1’
Options / ArgumentsDescription
[ -H <FSMHostName> ]Connects to the FSM (file system manager)
on the machine FSMHostName. (By default
cvadmin attempts to connect to an FSM on
the local machine.)
[ -F <FileSystemName> ]Sets FileSystemName as the active file
system in cvadmin.
[ -f <filename> ]Reads commands from the specified file.
[ -e <command> ]Runs the cvadmin command and exits.
(Commands are listed below.)
activate
Activates the file system file_system_name.
<file_system_name>
File System Commands7
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Options / ArgumentsDescription
debug [ [ + | - ] <value> ]Views or sets SNFS debugging flags. Enter
debug with no value to return the current
settings, the location of the FSM log file, and
a legend describing what each setting does.
disks [ refresh ]Displays SNFS disk volumes visible to this
machine. If the refresh option is used, the
volumes are re-scanned.
down <groupname>Disables access to the stripe group
groupname.
fail <file_system_name |
index_number>
Initiate failover of file system
file_system_name or file system
index_number.
fsmlist
[ <file_system_name> ]
[ on [ <hostname> |
Displays the state (running or not running) of
FSM processes for the specified file system,
hostname, or IP address.
<IP_address> ] ]
filelocks [ yes | no ]Shows file record lock enforcement. (File
locks are automatically used on UNIX or
Linux.)
help <command>Displays a usage summary of command.
latency-test
[ <index_number> | all ]
Runs a network latency test between the FSM
and a client or all clients.
[ seconds ]
pathsDisplays SNFS labeled disks visible to the local
system.
proxy [ long ]Displays distributed LAN servers for the
selected file system. With the long argument,
the served disks are also displayed.
proxy who <hostname>Displays all active distributed LAN
connections for the specified host.
qosDisplays per-stripe group QOS statistics.
repofCreates a report showing all open files on the
file system.
quitDisconnects cvadmin from SNFS and exits.
quotas [ yes | no ]Enables or disables quota accounting and
enforcement. Enter quotas with no value to
see current settings.
quotas get [ user | group ]
<name>
8File System Commands
Displays current quota parameters for user or
group name.
Options / ArgumentsDescription
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
quotas set [ user | group ]
<name> <hardlim>
<softlim> <timelim>
Sets current quota parameters for user or
group name.
• hardlim: The maximum amount of space
(in bytes) the specified user or group can
use.
• softlim: The amount of space used (in
bytes) before a warning is sent. (Typically
this is 80% of the hard limit.)
• timelim: The amount of time (in minutes)
it takes for the soft limit to turn into a hard
limit.
Setting a parameter to 0 disables quota
enforcement.
quotacheckRecalculates the amount of space consumed
by all users and groups in the file system.
repquotaGenerates quota reports for all users
and groups in the file system.
select <file_system_name>Selects file system file_system_name for
viewing or modification.
show [ <groupname> ]
[ long ]
Displays all stripe groups or a specific
stripe group.
start <file_system_name>
[ <hostname> |
Starts the SNFS manager for file system
file_system_name.
<IP_address> ]
statDisplays the status of the currently selected
file system.
stop <file_system_name>Stops the SNFS manager for file system
file_system_name.
up <groupname>Enables the stripe group groupname.
whoDisplays a list of mounted clients on the
currently selected file system.
Examples
•Enter cvadmin interactive mode (snadmin):
cvadmin
• Show all stripe groups in the file system:
cvadmin -F <file_system_name> -e show
• Display which FSM debug flags are set:
cvadmin -F <file_system_name> -e debug
• Display the long version of the strip1 stripe group:
File System Commands9
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
cvaffinityThe cvaffinity command is used to set a session affinity type. When a file system
is configured, an affinity (a name describing a special media type or property)
may be created in a stripe group. Once a stripe group affinity is established for a
session, all allocations of files associated with the session are made on stripe
groups having the specified affinity in the affinity set list. If an affinity does not
exist for any of the stripe groups, then the allocation occurs on the nonexclusive data pool. If there is no non-exclusive data pool, then ENOSPC (no
space) is returned.
Command Syntax
cvaffinity [ -k <key> ] <filename>
cvaffinity [-s <key> ] <filename>
Ta b l e 2 O p t i o n s a n d
Arguments: cvaffinity
cvaffinity [ -l ] <filename>
cvaffinity [ -d ] <filename>
Options / Arguments
Tab l e 2 lists options and arguments for the cvaffinity command.
Options / ArgumentsDescription
[ -k <key> ]Indicates where the file system should place
the data file. If the key parameter is defined,
then the data file is placed on stripe groups
specified to support this parameter.
If there is no stripe group with the specified
key, the file is placed on the non-exclusive
data pool. If there is no non-exclusive data
pool, then ENOSPC (no space) is returned.
[ -s <key> ]Associate affinity key with file or directory
filename.
[ -l ]Lists the affinity for the file filename.
[ -d ]Deletes the affinity from the file or directory
filename.
<filename>File or directory name.
10File System Commands
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Examples
• Set the stripe group that supports the specified affinity key, with the mount
point of the file system as a reference handle:
cvaffinity -k 6100_n8 /usr/clips
• Turn off the stripe group affinity, using the mount point of the file system as
a reference handle:
cvaffinity /usr/clips
cvcpThe cvcp command provides a high speed, multi-threaded copy mechanism to
copy directories and tar images on and off SNFS.
The cvcp commands works in a number of modes:
• Directory-to-directory copies of regular files
• Single file-to-file copy
• Data stream to a target directory
• Single file or directory copy to an output stream
The cvcp utility can be tuned to improve performance and resource utilization
by adjusting the -b, -k, and -t options.
• -b option specifies the number of copy buffers. This option should be set
between one to three times the number of copy threads. Increasing the
number of copy buffers increases the amount of work that queues waiting
for an available copy thread, but it also consumes more resources.
• -k option specifies the size of the copy buffer. This option can be tuned to fit
the I/O characteristics of a copy. If files smaller than 4MB are being copied,
performance may be improved by reducing this setting to match the copy
buffer size to the source file size.
• -t option specifies the number of copy threads. This option is useful when
copying large directory structures. Single file copies are not affected by the
number of copy threads.
Tab l e 3 lists options and arguments for the cvcp command.
Ta b l e 3 O p t i o n s a n d
Arguments: cvcp
Options / ArgumentsDescription
<source>Source file or directory.
File System Commands11
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Options / ArgumentsDescription
<destination>Destination file or directory.
[ -A ]Disables file pre-allocation.
[ -b <buffers> ]Sets the number of I/O buffers to buffers.
Default: two times the number of copy
threads started
[ -d ]Creates a sub-directory called Source in the
Destination directory, then copies the files
and sub-directories under Source to the new
sub-directory.
[ -k <buffer_size> ]Sets the I/O buffer size to buffer_size in
bytes.
Default: 4MB
[ -l ]Copies the target of symbolic links rather
than copying the link itself.
[ -n ]Prevents recursion through subdirectories.
[ -p <source_prefix> ]Only copies files that begin with the value of
the source_prefix parameter.
[ -s ]Forces allocations to line up on the beginning
block modulus of the stripe group.
[ -t <num_threads> ]Specifies the number of copy threads.
Default: 4
[ -u ]Only copies when the source file is newer
than the destination file or the destination
file does not exist.
[ -v ]Displays verbose output about copied files.
[ -x ]Retains original permissions from the source
file.
[ -y ]Retains ownership and group information (if
set by the super user).
[ -z ]Retains original modification times.
Examples
•Copy the abc directory and its sub-directories to /usr/clips/foo. This example
uses the default number of copy threads and buffers, has a total buffer pool
size of 32MB (8 buffers of 4MB each), retains all permissions and
ownerships, and shows all files being copied.
cvcp -vxy abc /usr/clips/foo
•Within the abc directory, copy all files that start with mumblypeg:
cvcp -vxy -p mumblypeg abc /usr/clips/foo
12File System Commands
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
cvfsckThe cvfsck command is used to check and repair a file system that was
corrupted by a system crash, bad disk, or other catastrophic failure.
Tab l e 4 lists options and arguments for the cvfsck command.
Ta b l e 4 O p t i o n s a n d
Arguments: cvfsck
Options / ArgumentsDescription
[ -C ]Reset the inode free list. Use only if cvfsck
cannot repair free-list inconsistencies.
[ -d ]Enables internal debugging.
[ -e ] Reports statistics on all file extents.
[ -f ]Reports fragmentation.
[ -g ]Prints the journal recovery log.
[ -G ]Exits immediately after cvfsk completes
without waiting for a key press (Windows
systems only).
[ -j ]Executes journal recovery and exits.
[ -J ]Dumps the raw journal to stdout and exits.
[ -K ] Resets the journal and exits.
WARNING: Resetting the journal may
introduce metadata inconsistency. Exercise
extreme caution when using this option.
[ -l ]Writes information to syslog.
[ -L <inode_number> ]Reassigns orphaned files to the specified
directory rather than to the root of the file
system. The inode_number of the directory
must be a 64-bit value.
Note: Use the dc pathname command in
cvfsdb to find the 64-bit inode
number of a directory.
File System Commands13
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Options / ArgumentsDescription
[ -M ]Determines if a new metadata dump is
needed and prints an explanation. If used,
cvfsck exits with one of the following
statuses:
• 0 - Dump not needed.
• 1 - Dump needed.
• 2 - An error occurred.
[ -n ]Does not update metadata (read only).
[ -r ]Reports statistics on all files.
[ -t ]Reports on allocation covering restricted
areas of a stripe group.
[ -T <directory> ]Places temporary files in the specified
directory.
[ -v ] Displays verbose output.
[ -x ]Reports statistics for input to a spreadsheet.
<FsName>Name of the file system to check.
[ <FsPath> ]An optional, alternate file system path (other
than /usr/cvfs/data) to locate file systems.
cvfsidThe cvfsid command provides a mechanism to display the SNFS identifier for
the executing system. This identifier is submitted to the Quantum Technical
Assistance Center, which issues license authorization keys.
Command Syntax
cvfsid [ -? ] [ -h ] [ -l ] [ -n ]
Options / Arguments
Tab l e 4 lists options and arguments for the cvfsid command.
Ta b l e 5 O p t i o n s a n d
Arguments: cvfsid
Options / ArgumentsDescription
[ -? ] [ -h ]Displays command help.
[ -l ]Lists the local host’s Authorizing IDs, IP
addresses, and MACs (Linux only).
[ -n ]Displays the network information in a
compact, machine readable form.
14File System Commands
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Examples
• Display the SNFS identifier for the executing system.
cvfsid
cvlabelThe cvlabel command is used to label SNFS disk devices. One client with
visibility to all SAN disk devices must execute cvlabel -l or cvlabel -L to create a
list of disk labels. The mount_cvfs (1M) process uses the volume labels to
determine which disk drives are used for SNFS stripe group nodes.
Quantum recommends that the cvlabel command first be used with the -l
option, which presents all disk devices found on the system. The next step is to
create a label list file with the -c option.
Caution: Use the cvlabel command with extreme caution. Incorrect use of
this command may destroy any existing file system data for the
named file system.
Note: The cvlabel command is used only to view or modify disk labels. It is
not used to determine the LUNs a file system has access to. To see the
LUNs a file system can access, or the paths being used to access LUNs,
use the cvadmin command with the disks or paths option. For more
information, see cvadmin on page 6.
Tab l e 6 lists options and arguments for the cvlabel command.
Ta b l e 6 O p t i o n s a n d
Arguments: cvlabel
Options / ArgumentsDescription
-lLists available disk devices on the system
(short format).
-LLists available disk devices on the system
(verbose format).
File System Commands15
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Options / ArgumentsDescription
-u <VolumeName>Unlabels the volume VolumeName.
-U <DeviceName>Unlabels the raw disk device DeviceName.
[ -s ]Prints the disk device serial number when
used with the -l option.
[ -v ]Reports verbose output about labeling.
[ -a ]Prints unusable disk devices when used with
the -l or -L options.
[ -g ]Prints GUID information for EFI-labeled disks
when used with the -l or -L options.
[ -F <filter> ]Lists only devices whose inquiry string
contains the filter string when used with the
-c, -l, or -L option.
[ -q <tag_q_depth> ]Sets the Command Tag Queue Depth to
tag_q_depth on IRIX systems. Default: 16
[ -f ]Forces labeling (without confirmation) even if
a label exists.
-cOutputs to stdout a list of all located devices
in a format that can later be used as a
label_list file.
[ -T ]When used with the -c option, outputs to
stdout a list of devices that can be converted
from the old VTOC format to the new EFI
format.
-D <VolumeName>Writes label information of volume
VolumeName to stdout.
[ -r ]Forces a disk to be relabeled even if there are
no changes to the label information.
[ -R ]Displays the default RAID strings inquiry
table.
[ -e ]Changes the label type for disks between 1TB
and 2TB from VTOC to EFI.
[ -E ]Changes the default label type for all disks to
EFI.
<label_list>File that specifies StorNext disk labels.
Examples
• List all disk devices in a system.
/usr/cvfs/bin/cvlabel -l
• Label the disk drives.
16File System Commands
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
/usr/cvfs/bin/cvlabel /tmp/mylabelfile
• Re-label the disk drives using the force (-f) and verbose (-v) options.
/usr/cvfs/bin/cvlabel -fv /tmp/mylabelfile
cvmkdirThe cvmkdir command is used to create a SNFS directory and attach the affinity
parameter (-k <key>) to it. If no option is used and there is an existing
directory, the cvmkdir command output displays the assigned affinity. Once an
affinity is assigned to a directory, it cannot be altered. If no option is used and
the directory does not exist, the directory will not be created.
Command Syntax
cvmkdir [ -k <key> ] <dirname>
Options / Arguments
Tab l e 7 lists options and arguments for the cvmkdir command.
Ta b l e 7 O p t i o n s a n d
Arguments: cvmkdir
Options / ArgumentsDescription
[ -k <key> ]Indicates the affinity to associate with the
directory. All new sub-directories and files
beneath this directory inherit its affinity as
they are created. If the affinity is changed or
removed, only files or directories created
after the change are affected.
<dirname>Path where the directory is created.
cvmkfileThe cvmkfile command is used to create a pre-allocated file on SNFS. This is a
useful method when preparing a file for use in a real-time or streaming
environment because the entire file is represented in only one file system extent.
Additionally, a file can be placed on a specific stripe group by specifying the key
parameter (used as an affinity locator).
Tab l e 8 lists options and arguments for the cvmkfile command.
File System Commands17
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Ta b l e 8 O p t i o n s a n d
Arguments: cvmkfile
Options / ArgumentsDescription
[ -k <key> ]Indicates where the file system should place
the data file. If the key parameter is defined,
then the data file is place on stripe groups
specified to support the key parameter.
[ -p ]Forces the allocation and subsequent
expansions to fit as multiples of the
InodeExpandMin configuration parameter.
[ -s ]Forces the allocation to begin on a stripe-
aligned block.
[ -w ]Sets the file size to the value of the size
parameter.
[ -z ]Causes the file to physically zero out.
<size>[k|m|g|t]Specifies the file size in bytes. If appended
with k, m, g, or t, the value represents
kilobytes, megabytes, gigabytes, or
terabytes.
Caution: Do not include any spaces
between size value and the suffix
(k, m, g, or t).
<filename>Name of the file to create.
Examples
• Make a 1GB file with 0 (zero) length. Allocate a stripe group that favors the
media type 6100_n8.
cvmkfile -k 6100_n8 1g samplefile
cvmkfsThe cvmkfs command is used to initialize a file system and (optional) to specify
the file system name. If a file system name is not provided, a list of configured
file systems is presented. Active file systems may not be re-initialized.
Caution: Use the cvmkfs command with extreme caution. Executing this
command will destroy any existing file system data for the named
file system.
Command Syntax
cvmkfs [ -G ] [ -F ] <file_system_name>
Options / Arguments
Tab l e 9 lists options and arguments for the cvmkfs command.
18File System Commands
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Ta b l e 9 O p t i o n s a n d
Arguments: cvmkfs
Options / ArgumentsDescription
[ -G ]Bypasses “Press return to continue...” type
prompts.
[ -F ]Executes the cvmkfs command in non-
interactive mode. The user does not receive
confirmation prompts.
Warning: Executing the cvmkfs command
without prompts results in an
irreversible re-initialization of the
file system. Use extreme caution
when invoking this option.
<file_system_name>Name of the file system to reinitialize.
Examples
• Re-initialize a StorNext file system.
/usr/cvfs/bin/cvmkfs <file_system_name>
cvupdatefsThe cvupdatefs command is used to update the configuration of a file system.
This allows you to add stripe groups or expand current stripe groups to expand
the storage space available to a file system.
Note: All metadata modifications must be made on an inactive (stopped) file
Tab l e 1 0 lists options and arguments for the cvupdatefs command.
Table 10 Options and
Arguments: cvupdatefs
Options / ArgumentsDescription
[ -F ]Forces updates without prompting for
confirmation.
[ -G ]Pauses the program after displaying the exit
status (Windows only).
[ -h ]Displays command help.
[ -l ]Logs when the update finished.
File System Commands19
StorNext 4.0 CLI Reference Guide
Document 6-01688-09 Rev A
March 2010
Options / ArgumentsDescription
[ -n ]Sets metadata to read-only mode.
[ -v ]Turns on verbose reporting.
[ -c <pathname> ]Use the specified file as the original
configuration and run cvfsck before applying
updates from the new configuration file.
[ <FsName> ]Name of the file system to update.
cvversionsThe cvversions command is used to display different versions (revision, build
level and creation date) for the File System Manager and client sub-systems of
SNFS. If you contact the Quantum Technical Assistance Center, provide this
information.
Command Syntax
cvversions
Options / Arguments
None
Examples
• Display version information for a StorNext file system.
cvversions
Storage Manager Commands
This section describes the following StorNext Storage Manager commands:
Note: Storage Manager commands are available only on Linux MDC systems.
• fsaddclass on page 22
• fsaddrelation on page 25
• fschdiat on page 26
• fschfiat on page 27
• fschmedstate on page 28
• fschstate on page 29
• fsclassinfo on page 29
20Storage Manager Commands
Loading...
+ 44 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.