| SCConnection |
Set up the connection between the Spectrum Connect server and the IBM Storage Automation Plug-in for PowerShell. Before using the PowerShell client,
create a PowerShell interface user. |
New-SCConnection -ConnectionUri <String> [-Credential] <PSCredential>
[<CommonParameters>] New-SCConnection -ConnectionUri <String>
[-UserName] <String> [-Password] <String> [<CommonParameters>]
- ConnectionUrl <String> Alias L. The connection URL for Spectrum Connect server in the
https://SCIPAddress:ServicePort(8440) format.
- Credentials <PSCredential>. User credentials for connection to the
Spectrum Connect server.
- UserName <String>Alias U. User name and password for the Spectrum Connect server connection must be specified. The
user can be created on the Spectrum Connect GUI, when
creating a PowerShell interface. Other non-PowerShell-interface users are limited to access some Spectrum Connect functions.
- Password <String> Alias P. The corresponding password.
For example, connect to the Spectrum Connect
server at 9.115.250.45 with user name powershell and password
admin2: PS C:\>$client=New-SCConnection -ConnectionUri https://9.115.250.45:8440 -UserName powershell -Password admin2
Note: If
the token is expired, re-issue New-SCClient to establish a new
connection.
|
| SCSpace |
Retrieve information about all storage spaces or show the detailed information according to
space ID or name. |
Get-SCSpace [[-SpaceID] <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCSpace [-SpaceName] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
- SpaceID <String>. Get the space details via the space ID.
- SpaceName <String>. Get the space details via the space name.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, display the detailed information, using space
ID: PS C:\>Get-SCSpace -SCConnection $client -SpaceID efbd54ac-70c8-4693-ad7f-3df1cf56c187
id : efbd54ac-70c8-4693-ad7f-3df1cf56c187
num_services : 0
unique_identifier : efbd54ac-70c8-4693-ad7f-3df1cf56c187
name : Default_Space
description : Space used as the default.
storage_array_metadata : {}
|
| SCService |
Retrieve information about storage services delegated to the existing PowerShell
interfaces. |
Get-SCService [[-ServiceID] <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCService [-ServiceName <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCService [-SpaceID <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCService [-SpaceName <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
- ServiceID <String>. The service ID or its unique identifier.
- ServiceName <String>. The service name.
- SpaceID <String>. Retrieve service information via its storage space
ID.
- SpaceName <String>. Retrieve service information via its storage
space name.
- SCConnection <SCConnection>. The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, display the detailed information, using service
ID: PS C:\>Get-SCService f69be4d0-b56c-449b-a3ae-a727a6ba972d -SCConnection $client
id : f69be4d0-b56c-449b-a3ae-a727a6ba972d
unique_identifier : f69be4d0-b56c-449b-a3ae-a727a6ba972d
name : service_vvol
description :
container : 7af7432d-172d-495b-a287-a1df2d2f4b77
capability_values :
type : vvol
physical_size : 214748364800
logical_size : 214748364800
physical_free : 214748364800
logical_free : 214748364800
total_capacity : 214748364800
used_capacity : 0
max_resource_logical_free : 214748364800
max_resource_free_size_for_provisioning : 214748364800
num_volumes : 0
has_admin : True
|
| SCHost |
Retrieve information about hosts. |
Get-SCHost [[-HostID] <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCHost [-ArrayID] <String> [-HostName] <String> [-SCConnection
<SCConnection>] [<CommonParameters>]
Get-SCHost [-ArrayID] <String> [-Initiator] <Object> [-SCConnection
<SCConnection>] [<CommonParameters>]
Get-SCHost [-ArrayID] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
- HostID <String>. The host ID unique to the Spectrum Connect server.
- ArrayID <String>. The ID of the managed storage system.
- HostName <String>. The host name. This string is case-sensitive.
- Initiators <Object>. iSCSI or FC ports of the host.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, display the detailed information about a single
host: PS C:\>Get-SCHost -ID 6
id : 6
array_type : 2145
array : 00000200AE62F4E4
name : fakeFCHost
port_count : 2
iogroup_count : 4
status : offline
host_type : generic
storage_cluster :
physical_host :
iogroups : {2, 3, 4, 1}
initiators : {21000024FF2DAFF6, 21000024FF2DAFF5}
|
| SCVolume |
Perform volume operations:
- Retrieve information about volumes managed by the PowerShell interfaces.
- Create a volume via the services delegated to the PowerShell interface.
- Resize a volume.
- Remove a volume.
|
Get Get-SCVolume [[-VolumeID] <String>] [[-SCConnection]
<SCConnection>] [<CommonParameters>]
Get-SCVolume [-VolumeName]
<String> [[-ArrayID] <String>] [-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCVolume [-ArrayID] <String>
[<CommonParameters>] Get-SCVolume [-ServiceID] <String> [-SCConnection
<SCConnection>] [<CommonParameters>]
Get-SCVolume [-ScsiID]
<String> [-SCConnection <SCConnection>] [<CommonParameters>]
- VolumeID <String>. The volume ID, its unique identifier or alias
ID.
- VolumeName <String>. The volume name or alias name. The
VolumeName is not unique, especially when multiple storage systems are managed
by same Spectrum Connect instance. To identify the
volume on certain storage system, the combination VolumeName and
ArrayID can be used.
- ArrayID <String>. The ID of the managed storage system. This
parameter can be used separately, or together with VolumeName.
- ServiceID <String>. The ID of the service managing the volume.
- SCConnection <SCConnection>. The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, retrieve detailed information of a volume on a managed storage
system: PS C:\>Get-SCVolume -VolumeName SCVOL304 -ArrayID 00000200AE62F4E4 -SCConnection $client
scsi_identifier : 6005076802B98BD390000000000000AD
array_type : 2145
array : 00000200AE62F4E4
array_name : V7K_71
id : 6005076802B98BD390000000000000AD
pool_name : SC61_THIN
pool_id : 3
max_extendable_size : 6596353938773
service_compliance : True
domain_name :
service_name : ThinProvisionService
container_name : DemoSpace
service_id : 8d4b6c91-670f-40bd-8d69-901e4a1219f9
container_id : 4cfc8298-965f-4f90-b23f-4d04fe70d9ee
storage_model : Storwize V7000
volume_id : 24
name : SCVOL304
logical_capacity : 10737418240
|
| |
|
New New-SCVolume [-VolumeName] <String> [-Size] <Int64>
[[-SizeUnit] <String>] [-ServiceID] <String> [[-Initiator] <Object>]
[[-SCConnection] <SCConnection>] [<CommonParameters>]
- VolumeName <String>. The name of a new volume.
- Size <Int64>. The size of a new volume. This parameter is together
with SizeUnit.
- SizeUnit <String>. The unit of the new volume size (Byte, GB, GiB,
TiB). Default setting is GB.
- ServiceID <String>. The ID of the service managing the volume.
- Initiators <Object>. iSCSI or FC ports of the host to be mapped to
the new volume. System.Collections.ArrayList object or just a
Object[] can be used for multiple initiators.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, create a new volume for a specific
service: PS C:\>New-SCVolume -Name DemoThin04 -Size 1 -SizeUnit GiB -ServiceID $service.id |ft array_name,id,name,pool_name,service_name, logical_capacity
array_name : cim75
id : 6005076801A707416800000000000B76
name : DemoThin04
pool_name : SCReserved
service_name : SVCThinService
container_name : DemoSpace
logical_capacity : 1073741824
|
| |
|
Resize Resize-SCVolume [-VolumeID] <String> [-NewSize] <Int64>
[[-SizeUnit] <String>] [-SCConnection <SCConnection>] [<CommonParameters>]
- VolumeID <String>. ID of the volume to be resized.
- NewSize <Int64>. The new size of the volume. This parameter is
together with SizeUnit.
- SizeUnit <String>. The unit of the new volume size (Byte, GB, GiB,
TiB). Default setting is GB.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, create a new volume for a specific
service: Resize-SCVolume -ID 6005076801A707416800000000000B76 -NewSize 2 -SizeUnit GiB|ft name,id,logical_capacity
name id logical_capacity
---- -- ----------------
DemoThin03 6005076801A707416800000000000B74 2147483648
|
| |
|
Remove Remove-SCVolume [-VolumeID] <Object> [[-Force]] [-SCConnection
<SCConnection>] [<CommonParameters>]
- VolumeID <String>. ID of the volume to be removed.
- Force <SwitchParameter>. Deletes mapping relations of the volume to
be removed.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, remove a
volume: PS C:\>Remove-SCVolume -VolumeID 6005076801A707416800000000000B85 -SCConnection $client
True
|
SCHostVol Mapping |
Perform volume mapping operations:
- Retrieve information about host-volume mapping.
- Map the volume to the host.
- Unmap the volume from the host.
|
Get Get-SCHostVolMapping [[-HostVolMappingID] <String>]
[-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCHostVolMapping [-HostID] <String>
[-SCConnection <SCConnection>]
[<CommonParameters>]
Get-SCHostVolMapping [-VolumeID] <String>
[-SCConnection <SCConnection>] [<CommonParameters>]
- HostVolMappingID <String>. The mapping relation ID, its unique
identifier or alias ID.
- HostID <String>. Displays mapping relations of the host with the
specified ID.
- VolumeID <String>. Displays mapping relations of the volume with the
specified ID.
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, display mapping relations for the host with ID
5: PS C:\>Get-SCHostVolMapping -HostID 5 -SCConnection $sc|ft
id volume host lun_number
-- ------ ---- ----------
113 6005076802B98BD390000000000000AC 5 2
3 6005076802B98BD39000000000000018 5 1
4 6005076802B98BD39000000000000017 5 0
111 6005076802B98BD390000000000000AB 5 7
107 6005076802B98BD390000000000000A8 5 5
|
| |
|
New New-SCHostVolMapping [-VolumeID] <String> [-HostID]
<Object> [-SCConnection <SCConnection>]
[<CommonParameters>]
New-SCHostVolMapping [-VolumeID] <String>
[-HostName] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
New-SCHostVolMapping [-VolumeID] <String>
[-Initiators] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
- VolumeID <String>. ID of the volume to be mapped.
- HostID <String>. ID of the host that the specified volume will be
mapped to.
- Initiators <Object>. The host endpoint (iSCSI or FC).
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, map a single volume to multiple
hosts: PS C:\>New-SCHostVolMapping -VolumeID 6005076801A707416800000000000B76 -HostIDs 22,21,1
{@{id=21; volume=6005076801A707416800000000000B76; host=22; lun_number=1}}{@{id=21; volume=6005076801A707416800000000000B76; host=22; lun_number=4}, @{id=20;
volume=6005076801A707416800000000000B76; host=21; lun_number=4}, @{id=19;
|
| |
|
Remove Remove-SCHostVolMapping [-VolumeID] <String> [-HostID]
<Object> [-SCConnection <SCConnection>]
[<CommonParameters>]
Remove-SCHostVolMapping [-VolumeID]
<String> [-HostName] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
Remove-SCHostVolMapping [-VolumeID]
<String> [-Initiators] <String> [-SCConnection <SCConnection>]
[<CommonParameters>]
- VolumeID <String>. ID of the volume to be unmapped.
- HostID <String>. ID of the host that the specified volume will be
unmapped from.
- Initiators <Object>. The host endpoint (iSCSI or FC).
- SCConnection <SCConnection>The client handle for Spectrum Connect server.
It can be created via
New-SCConnection. If the SCConnection is not specified, a
most recently used SCConnection is utilized by default. The connection can be found via the global
variable $Global:DefaultConnection. If multiple Spectrum Connect servers are connected, you must explicitly
specify the SCConnection parameter.
For example, unmap a volume from two
hosts: PS C:\>Remove-SCHostVolMapping -VolumeID 6005076801A707416800000000B76 -HostIDs 22,21 -SCConnection $client
|