The transition to NetApp MS Azure AD B2C is complete. If you missed the pre-registration, you will be invited to register at next log in.
Please note that access to your NetApp data may take up to 1 hour.
To learn more, read the FAQ and watch the video.
Need assistance? Complete this form and select “Registration Issue” as the Feedback Category.

Active IQ Unified Manager Discussions

WFA Return Parameters LUN ID


Hello All,


I have created a workflow which creates a volume/lun and maps it to an existing igroup, I want it to return the LUN id used (as I dont specify it), I have played with return parameters section but I cannot find the parameter value.

Hoping I cannot be the first person wanting to do this?

Any help would be much appreciated?





Hi John,


There are a number of different methods to achieve the outcome you want. You can find the solutions in the following links:


Hope that helps



If this post resolved your issue, help others by selecting ACCEPT AS SOLUTION or adding a KUDO.


Many thanks for this, so I have cloned the certified command for map lun and added the section at the bottom then in the workflow gone to the return parameters tab and added LunId but for some reason it seems to errors with the below, i guess I am doint something wrong?


Failed to evaluate workflow return parameter value 'LunId'
Location: 'LunId' return parameter


param (
[parameter(Mandatory=$true, HelpMessage="Cluster name or IP address")]

[parameter(Mandatory=$true, HelpMessage="Storage Virtual Machine name")]

[parameter(Mandatory=$true, HelpMessage="Volume name")]

[parameter(Mandatory=$false, HelpMessage="Qtree name")]

[parameter(Mandatory=$true, HelpMessage="LUN name")]

[parameter(Mandatory=$true, HelpMessage="Name of the igroup to map the initiator to")]
[parameter(Mandatory=$false, HelpMessage="LUN id")]

Get-WFALogger -Info -message $("Connecting cluster : " + $Cluster)
Connect-WfaCluster -Node $Cluster -Vserver $VserverName

if ($QtreeName)
$LunPath = "/vol/" + $VolumeName + "/" + $QtreeName + "/" + $LunName
$LunPath = "/vol/" + $VolumeName + "/" + $LunName

Get-WFALogger -Info -message $("Mapping LUN : " + $LunName)
Add-NcLunMap -Path $LunPath -InitiatorGroup $IgroupName -VserverContext $VserverName -Id $LunId
Add-NcLunMap -Path $LunPath -InitiatorGroup $IgroupName -VserverContext $VserverName

#' return LunID to WFA
Add-WfaWorkflowParameter -Name "LunId" -Value $LunId -AddAsReturnParameter $True

NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner