I am trying to download all device configurations (latest versions) to local drive. Here is the script I tried based on modified sample scripts.
if (! (Get-PSSnapin | where {$_.Name -eq "SwisSnapin"})) { Add-PSSnapin "SwisSnapin" } $hostname = "xxxxx" $username = "xxxxx" $password = New-Object System.Security.SecureString $cred = Get-Credential $swis = Connect-Swis -v2 -host $hostname -cred $cred $ip = 'xxxxx' $nodeId = get-swisdata $swis "SELECT NodeID FROM Cirrus.Nodes WHERE AgentIP=@ip" @{ip=$ip} $script = "show clock" $nodeIdList = New-Object -TypeName "System.Guid[]" 1 $nodeIdList[0] = $nodeId $configType = "Running" Invoke-SwisVerb $swis Cirrus.ConfigArchive Download @($nodeIdList, "Running", $username) | Out-Null |
But I am getting the below error message in response. What is the problem? Can anyone guide me? I am language agnostic, any solutions in Perl, Python or Powershell is OK.
Invoke-SwisVerb : Retrieving the COM class factory for component with CLSID {FD7ADF54-44AC-4129-A8B1-7833F06418FD} failed due to the following error: 8007000e Not enough storage is available to complete this operation. (Exception from HRESULT: 0x8007000E (E_OUTOFMEMORY)). At line:1 char:1 + Invoke-SwisVerb $swis Cirrus.ConfigArchive Download @($nodeIdList, "Running", $u ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : InvalidOperation: (:) [Invoke-SwisVerb], FaultException`1 + FullyQualifiedErrorId : SwisError,SwisPowerShell.InvokeSwisVerb |