Subscribe
Accepted Solution

how to get LUNID

[ Edited ]

how can I get the lun ID of each lun that is mapped to each initiator group I created with the powershell toolkit? It will be similar to the 

 

lun show -m command

 

but in powershell

 

 

Re: how to get LUNID

[ Edited ]

Try to start with something like this (for 7-mode):

 

Get-NaLun | ? {$_.Mapped -eq $true} | % {Get-NaLunMap -path $_.Path} | ft Path,InitiatorGroupType,ALUA,InitiatorGroupName,LunId

 

Also have a look at "Get-Member", to see all properties of "NaLunMap" objects:

 

Get-NaLun | ? {$_.Mapped -eq $true} | % {Get-NaLunMap -path $_.Path} | gm

 

 

For C-Mode something like this might be sufficient:

 

Get-NcLunMap | ft Vserver,Path,InitiatorGroup,LunId

Re: how to get LUNID

Thank you. That works great