ADVERTISEMENT
Pure Storage CLI Questions
The How to guide for Pure Storage CLI Commands
- purearray listDisplay the array name and firmware version
- purearray list --connectDisplay remotely connected arrays for replication
- purearray list --controllerList all the controllers connected to the Array. This will also display the model and status of each controller
- purearray list --spaceDisplay the capacity and usage statistics information of the Array.
- purearray list --space --historical 30dDisplay the capacity and usage statistics information of the Array since last 30 days
- purearray list --phonehomeDisplay the dial home configuration status of the Array
- purearray list --connect --throttleDisplay the replication throttle limit
- purearray list --connection-keyDisplay the connection key that can be used to connect to the array
- purearray monitor --interval 4 --repeat 5Display the array-wide IO performance of a Flash Array in every 4 seconds for 5 times.
- purearray rename MYARRAY001Set the name of the array to MYARRAY001
- purehw listList all the hardware components along with information like status, temperature, voltage etc.
- purehw list --specList all the hardware components along with information like Model name, Part number and serial number
- purehw list CT0.FC0Display information about FC port 0 on controller 0. Port status and speed also be displayed.
- purehw list CT0 --specDisplay model, part number, and serial number of Controller 0
- purehw list --type fcList all the FC ports in an Array with status and speed information
- purehw list --type bayList all the Drive modules in an Array
- purehw list --type bay --specList all the Drive modules in an Array along with part number and serial number
- purehw list --type ctList all the Controller in an Array
- purehw list --type ethList all the Ethernet ports in an Array
- puredrive listList all the flash drive modules in an Array. This will also display the capacity of each module.
- puredrive list --totalList all the flash drive modules in an Array with the total capacity figure
- puredrive list --specList all the flash drive modules in an Array along with Protocol( SAS/NVME) information
- puredrive list CH0.BAY10Display information about flash drive BAY10 in CH0
- puredrive list CH0.BAY10 --packDisplay information about flash drive BAY10 in CH0 and all other drives in the same pack
- purevol create --size 10G MY_VOLUME_001Create a Virtual volume called MY_VOLUME_001 of size 10GB
- purevol create --size 10G MY_VOLUME_001 MY_VOLUME_002Create Virtual volumes MY_VOLUME_001 and MY_VOL_SIZE_002 of size 10GB
- purevol create --size 10G MY_VOLUME_001 --bw-limit 10MCreate a Virtual volume MY_VOLUME_001 of size 10GB and limit is bandwidth to 10MB/s
- purevol rename MY_VOL_001 MY_VOL_002Rename virtual volume MY_VOL_001 to MY_VOL_002
- purevol setattr --size 2G MY_VOL_001Increase the size of MY_VOL_001 to 2GB
- purevol setattr --bw-limit 1M MY_VOL_001 MY_VOL_001Change the bandwidth limit of MY_VOL_001 to 1MB/s
- purevol setattr --bw-limit 1M MY_VOL_001 MY_VOL_002Change the bandwidth limit of MY_VOL_001 and MY_VOL_002 to 1MB/s
- purevol setattr --size 2G MY_VOL_001 MY_VOL_001Increase the size of MY_VOL_001 and MY_VOL_002 to 2GB
- purevol destroy MY_VOL_001Destroy virtual volume MY_VOL_001. This volume can be recovered within 24hrs. After that, physical storage occupied this volume will be reclaimed.
- purevol recover MY_VOL_001Recover virtual volume MY_VOL_001 which is destroyed earlier.
- purevol eradicate MY_VOL_001Eradicate virtual volume MY_VOL_001 which is destroyed earlier. This will fully destroy the volume and not be able to recover further.
- purevol truncate --size 1G MY_VOL_001Reduce the size of MY_VOL_001 to 1GB
- purevol listList all the Virtual Volume
- purevol list --snapList all the snap shots
- purevol snap MY_VOL_001Create snap shot of MY_VOL_001. If it is first snap then MY_VOL_001.2 will be created
- purevol snap MY_VOL_001 --suffix PRDCreate snap shot of MY_VOL_001 with PRD as a suffix. MY_VOL_001.PRD will be created
- purevol list --pendingList all the Virtual Volumes including destroyed but pending for eradication
- purevol list --pending-onlyList all the destroyed Virtual Volumes pending for eradication
- purevol copy MY_VOL_001 MY_VOL_002Create a copy MY_VOL_001 and name it as MY_VOL_002. If MY_VOL_002 already exists this will throw and error.
- purevol copy MY_VOL_001 MY_VOL_002 --overwriteCopy data from MY_VOL_001 to an existing volume MY_VOL_002. Contents of MY_VOL_002 will be overwritten.
- purevol list MY_VOL_001List information about MY_VOL_001
- purevol list MY_VOL*List all the Virtual Volumes prefixed with MY_VOL
- purehost create MY-SERVER-001Create a host object called MY-SERVER-001. HBA wwns can be added later using purehost setattr command.
- purehost create MY-SERVER-001 --wwnlist 1000000000000001,10:00:00:00:00:00:00:01Create a host object called MY-SERVER-001 and add HBA wwns to it
- purehost setattr MY-SERVER-001 --wwnlist 1000000000000003Update the contents of an existing host with new wwn 1000000000000003
- purehost setattr MY-SERVER-001 --wwnlist ""Remove all wwns from MY-HOST-001
- purehost create MY-SERVER-001 MY-SERVER-002Create hosts MY-SERVER-001 and MY-HOST-002
- purehost delete MY-SERVER-001Delete host MY-SERVER-001
- purehost delete MY-SERVER-001 MY-SERVER-002Delete hosts MY-SERVER-001 MY-SERVER-002
- purehost rename MY-SERVER-001 YOUR-SERVER-001Rename host MY-SERVER-001 to YOUR-SERVER-001
- purehost setattr MY-SERVER-001 --addwwnlist 1000000000000003Add new HBA wwn 1000000000000003 to host MY-HOST-001. 1000000000000003 should not be part of any other host.
- purehost setattr MY-SERVER-001 --remwwnlist 1000000000000003Remove HBS wwn 1000000000000003 from host MY-SERVER-001
- purevol connect MY_VOL_001 --host MY-SERVER-001Connect volume MY_VOL_001 to host MY-SERVER-001. This will Provide the R/W access to the volume.Next available lun address will used by default.
- purevol connect MY_VOL_001 --host MY-SERVER-001 --lun 10Connect volume MY_VOL_001 to host MY-SERVER-001 and assign LUN id 10. This will Provide the R/W access to the volume.
- purevol disconnect MY_VOL_001 --host MY-SERVER-001Disconnect volume MY_VOL_001 from host MY-SERVER-001. This will remove the visibility of the volume to the host.
- purehost connect MY-SERVER-001 --vol MY_VOL_001Connect volume MY_VOL_001 to host MY-SERVER-001. This will Provide the R/W access to the volume.Next available lun address will used by default.
- purehost connect MY-SERVER-001 --vol MY_VOL_001 --lun 10Connect volume MY_VOL_001 to host MY-SERVER-001 and assign LUN id 10. This will Provide the R/W access to the volume.
- purehost disconnect MY-SERVER-001 --vol MY_VOL_001Disconnect volume MY_VOL_001 from host MY-SERVER-001. This will remove the visibility of the volume to the host.
- purevol connect MY_VOL_001 MY_VOL_002 --host MY-SERVER-001Connect volumes MY_VOL_001 and MY_VOL_002 to host MY-SERVER-001
- purevol discconnect MY_VOL_001 MY_VOL_002 --host MY-SERVER-001Disconnect volumes MY_VOL_001 and MY_VOL_002 from host MY-SERVER-001
- purehost connect MY-SERVER-001 MY-SERVER-002 --vol MY_VOL_001Connect volume MY_VOL_001 to hosts MY-SERVER-001 and MY-SERVER-002
- purehost disconnect MY-SERVER-001 MY-SERVER-002 --vol MY_VOL_001Disconnect volume MY_VOL_001 from hosts MY-SERVER-001 and MY-SERVER-002
- purehgroup create MY-HOSTSCreate a hostgroup called MY-HOSTS
- purehgroup delete MY-HOSTSDelete empty hostgroup MY-HOSTS.
- purehgroup create MY-HOSTS -hostlist MY-HOST-001,MY-HOST-002Create hostgroup MY-HOSTS and add existing hosts MY-HOST-001 and MY-HOST-002 in to it
- purehgroup delete MY-HOSTS_1 MY-HOSTS-2Delete empty hostgroups MY-HOSTS-1 and MY-HOSTS-2
- purehgroup setattr MY-HOSTS --addhostlist MY-HOST-002,MY-HOST-003Add MY-HOST-002 and MY-HOST-003 to existing hostgroup MY-HOSTS
- purehgroup setattr MY-HOSTS --remhostlist MY-HOST-002,MY-HOST-003Remove MY-HOST-002 and MY-HOST-003 from hostgroup MY-HOSTS
- purehgroup setattr MY-HOSTS --hostlist MY-HOST-002,MY-HOST-003Replace members of MY-HOSTS with new hosts MY-HOST-002 and MY-HOST-003
- purehgroup rename MY-HOSTS YOUR-HOSTSRename hostgroup MY-HOSTS with YOUR-HOSTS
- purehgroup connect MY-HOSTS --vol MY_VOL_001Connect volume MY_VOLUME_001 to hostgroup MY-HOSTS
- purehgroup disconnect MY-HOSTS --vol MY_VOL_001Disconnect volume MY_VOLUME_001 from hostgroup MY-HOSTS
- purehgroup connect MY-HOSTS --vol MY_VOL_001 --lun 100Connect volume MY_VOLUME_001 to hostgroup MY-HOSTS and assign LUN id 100
- purehgroup listList all the hostgroups a with member hosts
- purehgroup list --connectList all the hostgroups and connected volumes
- purevol connect MY_VOL_001 --hgroup MY-HOSTSConnect volume MY_VOL_001 to hostgroup MY-HOSTS
- purevol disconnect MY_VOL_001 --hgroup MY-HOSTSDisconnect volume MY_VOL_001 from hostgroup MY-HOSTS
- purevol destroy MY_VOL_001 MY_VOL_002Destroy virtual volumes MY_VOL_001 and MY_VOL_001. These volumes can be recovered within 24hrs. After that, physical storage occupied these volumes will be reclaimed.
- purevol eradicate MY_VOL_001 MY_VOL_002Eradicate virtual volumes MY_VOL_001 and MY_VOL_002 which are destroyed earlier. This will fully destroy the volumes and not be able to recover further.
- purehgroup list --spaceList all the hostgroups with the total capacity of volumes provisioned to each and the consumption
- purehgroup setattr MY-HOSTS --hostlist ""Remove all the hosts from hostgroup MY-HOSTS
- pureconfig listDisplay list of commands to reproduce the volumes, hosts, host groups, connections, network, alert and array configurations. Copying this and running in another array will create an exact copy.
Most viewed articles
Pure Storage CLI CommandsA quick reference to the Pure Storage Commands
Pure FlashArray ModelsA quick reference to all the Flash Array models of Pure Storage