Forum Discussion

saravananp's avatar
saravananp
Day Hiker I
9 hours ago

A list of useful Purity CLI commands to manage Pure Flash Storage arrays.

"pureadmin" commands
The pureadmin command displays and manage administrative accounts in Pure Flash Storage Array (22 Commands)Explanation
pureadmin create testuser --api-tokenGenerate an API token for the user testuser
pureadmin create testuser --api-token --timeout 2hCreate API Token for testuser valid for 2 hours
pureadmin create testuser --role storage_adminCreate user testuser with storage_admin role. Possible roles are readonly, ops_admin, storage_admin, array_admin
pureadmin delete --api-tokenDelete API Token for current user
pureadmin delete testuserDelete user testuser from Flash Array
pureadmin delete testuser --api-tokenDelete API Token for user testuser
pureadmin global disable --single-sign-onThis will disable single sign-on on the current array. Enabling single sign-on gives LDAP users the ability to navigate seamlessly from Pure1 Manage to the current array through a single login.
pureadmin global enable --single-sign-onThis enables single sign-on on the current array. Enabling single sign-on gives LDAP users the ability to navigate seamlessly from Pure1 Manage to the current array through a single login.
pureadmin global listList the global administration attributes like Lockout Duration, Maximum Login Attempts, Minimum Password Length, etc..
pureadmin global setattr --lockout-duration 1mSet the lockout duration to 1 minute after maximum unsuccessful login attempts.
pureadmin global setattr --max-login-attempts 3Set the maximum failed login attempts to 3 before the user get locked out.
pureadmin global setattr --min-password-length 8Set the minimum length of characters required for all the local user account passwords to 8. Minimum length allowed is 1. This will not affect the existing user accounts, but all future password assignment must meet the new value.
pureadmin listList all the users configured in the Flash Array
pureadmin list --api-tokenList all the users with api tokens configured
pureadmin list --api-token --exposeList all the users with api tokens configured and expose the api token for the current user loggedin.
pureadmin list --lockoutList all the user accounts that are currently lockout
pureadmin refresh --clearClears the permission cache for all the users
pureadmin refresh --clear testuserClears the permission cache for testuser
pureadmin refresh testuserRefresh the permission cache for testuser
pureadmin reset testuser --lockoutUnlock locked user testuser
pureadmin setattr testuser --passwordChange the password for the user testuser
pureadmin setattr testuser --role array_adminChange the role of the user testuser to array_admin role. Possible roles are readonly, ops_admin, storage_admin, array_admin
  
"purealert" commands
The purealert command manages alert history and the list of designated email addresses for alert notifications (8 Commands)Explanation
purealert flag 121212Flag an alert with ID 121212. This will appear in the flagged alert list.
purealert listList all the alerts generated in the Pure Flash Array
purealert list --filter "issue='failure'"List all the alerts generated for failures
purealert list --filter "severity='critical'"List all the alerts with Critical severity.
purealert list --filter "state='closed'"List all the closed alerts
purealert list --filter "state='open'"List all the alerts in Open state
purealert list --flaggedList all the alerts that are flagged. By default all alerts are flagged. We can unflag command once those are resolved.
purealert unflag 121212Unflag alert with ID 121212. This will not appear in the flagged alert list.
  
"purearray" commands
The purearray command displays attributes and monitors I/O performance in Pure Flash Storage Array (24 Commands)Explanation
purearray connect --management-address 10.0.0.1 --type async-replication --connection-keyConnects the local array to remote array 10.0.0.1 for asynchronous replication using the connection key. The Connection key will be prompted to enter.
purearray connect --management-address 10.0.0.1 --type sync-replication --connection-keyConnects the local array to remote array 10.0.0.1 for synchronous replication using the connection key. The Connection key will be prompted to enter.
purearray connect --management-address 10.0.0.1 --type sync-replication --replication-transport ip -- connection-keyConnects the local array to remote array 10.0.0.1 for synchronous replication via Ethernet transport using the connection key. The Connection key will be prompted to enter.
purearray disable phonehomeDisable phonehome or dialhome feature of array.
purearray disconnect 10.0.0.1Disconnects array 10.0.0.1 from the local array connected for remote replication.
purearray enable phonehomeEnable phonehome or dialhome feature of array.
purearray listDisplay the array name,serial number and firmware version
purearray list --connectDisplay remotely connected arrays for replication
purearray list --connect --pathDisplay arrays connected for remote replication along with connection paths
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 list --controllerList all the controllers connected to the Array. This will also display the model and status of each controller
purearray list --ntpserverList the NTP servers configured
purearray list --phonehomeDisplay the dial home configuration status of the Array
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 --syslogserverList the syslog server names configured to push the logs in pure array
purearray monitor --interval 4 --repeat 5Display the array-wide IO performance of a Flash Array in every 4 seconds for 5 times.
purearray remoteassist --statuscheck the Remote Assist is active or inactive
purearray rename MYARRAY001Set the name of the array to MYARRAY001
purearray setattr --ntpserver ''Remove all the NTP servers configured for pure array
purearray setattr --ntpserver time.google.comSet the NTP server
purearray setattr --syslogserver ''Remove all the syslog server servers configured for pure array
purearray setattr --syslogserver log.server.comset the syslog server for pure array
  
"pureaudit" commands
The pureaudit command displays and manages the audit logs record details in Pure Flash Storage Array (7 Commands)Explanation
pureaudit listDisplay the list of audit records. Audit trail records are created whenever administrative actions are perfromed by a user (for eg: creating, destroying, eradicating a volume)
pureaudit list --filter 'command="purepod" and subcommand="create"'List all the audit records for purepod create command executed in the array
pureaudit list --filter 'command="purepod" and user="pureuser"'List all the audit records for purepod commands executed by pureuser in the array
pureaudit list --filter 'command="purepod"'List all the audit records for purepod command executed in the array
pureaudit list --filter 'user = "root"'Display the list of audit records for the root user
pureaudit list --limit 10Display the first 10 rows of audit records
pureaudit list --sort userDisplay the list of audit records sorted by the user field. By default the records are sorted by the time field
  
"pureconfig" commands
The pureconfig command provides commands to reproduce the current Pure Flash Storage Array configuration (4 Commands)Explanation
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.
pureconfig list --allDisplays all the commands required to reproduce the current FlashAarray configuration of hosts, host groups, pods, protection groups, volumes, volume groups, connections, file systems and directories, alert, network, policies, and support.
pureconfig list --objectDisplays the object configuration of the FlashArray including hosts, host groups, pods, protection groups, volumes, volume groups, and connections, as well as file systems and directories if file services are enabled.
pureconfig list --systemDisplays the system configuration of the flah array including network, policies, alert and support
puredns commandsThe puredns command manages the DNS attributes for an arrays administrative network. (4 Commands)
  
"puredns" list
Display the current DNS parameters configured in the array. This includes the domain suffixes and IP addresses of the name serversExplanation
puredns setattr --domain ""Removes the domain suffix from Purity//FA DNS queries
puredns setattr --domain test.com --nameservers 192.168.0.10,192.168.2.11Add the IPv4 addresses of two DNS servers for Array to use to resolve hostnames to IP addresses, and the domain suffix test.com for DNS searches.
puredns setattr --nameservers""Unassigns DNS server IP addresses from the DNS entry. This will stop making DNS entries.
  
"puredrive" commands
The puredrive command provides information about the Flash Drives and NVRAM modules in Pure Flash Storage Array (6 Commands)Explanation
puredrive admitAdmit all drive modules that have been added or connected but not yet admitted to the array. Once successfully admitted, the status of the drive modules will change from unadmitted to healthy.
puredrive listList all the flash drive modules in an Array. This will also display the capacity of each module.
puredrive list --specList all the flash drive modules in an Array along with Protocol( SAS/NVME) information
puredrive list --totalList all the flash drive modules in an Array with the total capacity figure
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
No RepliesBe the first to reply