Microsoft Virtualization Discussions

Get-NcLun fails with JSON integer is too large or small for an int32

Carey_Lee
2,860 Views

This works fine to the same array under an old module 9.7.0.0 but fails with this error under 9.11.1.2208 and 9.12.1.2302

 

Get-NcLun : JSON integer 5556847471 is too large or small for an Int32. Path 'statistics.latency_raw.read', line 151,
position 24.
At line:1 char:1
+ Get-NcLun
+ ~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Get-NcLun], ArgumentException
+ FullyQualifiedErrorId : JSON integer 5556847471 is too large or small for an Int32. Path 'statistics.latency_raw
.read', line 151, position 24.,DataONTAP.C.PowerShell.SDK.Cmdlets.Lun.GetNcLun

 

 

Any ideas?

 

4 REPLIES 4

Carey_Lee
2,719 Views

To add a bit more this started after upgrading to 9.11.1p5 but I suspect any 9.11.X has this issue.  Called NetApp support they will not help and told me to come here which I had already done but no replies so I guess the powershell toolkit is not something they want to work.  Kind of disheartening to be honest.  I beleive but can't prove it now that I've upgraded all my arrays that this property "statistics.latency_raw.read" didn't exist in the old version.  When using powershell tollkit 9.11.x.x the property doesn't exists when you do a Get-NcLun | get-memebr which is why it works.

RafaelVarela
2,425 Views

Same problem here.

 

It worked fine in the old "DataONTAP" module (version 9.8 in my case) but it fails with "NetApp.ONTAP" version 9.12.1.2302

Carey_Lee
2,417 Views

Very disappointed in NetApp.  They haven't helped and have given me the official we don't support the toolkit and to come here for support.  I said wait a minute on GitHUB it says "Copyrighted by NetApp and all the developers that are taking credit work for NetApp so excuse me for thinking you might support your own product.

 

I was able to get around it by using a template that only selected what I needed and not the performance numbers that are causing the error.

 

 

#Workaround to avoid reading Statistics data which errors. Only read the below properties when reading fron Array.
$lun_template = Get-NcLun -template
$lun_template.vServer ="*"
$lun_template.Path ="*"
$lun_template.Mapped ="*"
$lun_template.Online ="*"
$lun_template.Volume ="*"

Try{
$luns = Get-NcLun -Attributes $lun_template -ErrorAction Stop
}Catch{
Write-Host "Failed Enumerating LUNs on $MyArray"
If ($Report) {"Failed Enumerating LUNs on $MyArray" | Out-File -FilePath $OutputFile -Append -Encoding utf8 }
Break
}

 

 

Hope that helps,

 

RafaelVarela
2,407 Views

Yes, it helps. Thank you very much.

Public