Apple Xsan 2 (Third Edition) User Manual
Page 117

Appendix B
Using the Command Line
117
To list available LUNs:
$ sudo cvlabel -l [-s] [-v]
To list current LUN and label information you can paste into a label file:
$ sudo cvlabel -c
To label a LUN:
$ sudo cvlabel [-v] [-f] [labelfile]
To remove the label from a LUN:
$ sudo cvlabel -u lun
Parameter
Description
-l
List available LUNs.
-s
Display device serial numbers.
-v
Show progress display.
-c
Create a label template file.
-f
Relabels LUNs that are labeled.
labelfile
An optional file containing information for each
label. You can use the -c option to create this file.
lun
The LUN identified by disk name—for example:
/dev/disk4.
-u
Unlabel the specified LUN.
Creating a Folder and Assigning an Affinity (cvmkdir)
Use the
cvmkdir
command to create a folder (directory) and assign it an affinity tag so
that its contents are stored on storage pools with the same affinity tag.
$ cvmkdir -k affinity folder
Parameter
Description
-k affinity
Specifies the affinity tag to be associated with the
folder.
affinity
– the affinity tag that’s assigned to
the storage pools where you want the folder’s
contents to be stored
You can use the
show long
command of the
cvadmin
tool to see a storage pool’s affinity tag.
You can use
-k ""
to remove the folder’s affinity
tag.
folder
The path to and name of the folder.