Solved

Get-NTNXEvent limit of 1,000


Userlevel 1
Badge +12
  • Trailblazer
  • 14 replies
It appears that there's a limit to the number of events that the Get-NTNXEvent (and Get-NTNXProtectionDomainEvent) cmdlet return. Is there any way to bypass this limit of 1,000?

This limit also seems to exist from the Prism console when selecting the export to csv option.
icon

Best answer by sandeepmp 9 May 2017, 08:30

mandg

Currently, this is a hard limit which we set.
You can use the below method to grab the data and export to CSV.


$result = @()$i = 1;do{$result += Get-NTNXEvent -Page $i -count 1000$i++}until((Get-NTNXEvent -Page $i -count 1000).count -eq 0 )

$result | export-csv "Path & filname to save the csv file"

Regards,
Sandeep MP

View original

2 replies

Userlevel 7
Badge +35
Hi mandg

Thanks for sharing, I'll work on getting an answer for you

Thanks
Userlevel 4
Badge +19
mandg

Currently, this is a hard limit which we set.
You can use the below method to grab the data and export to CSV.


$result = @()$i = 1;do{$result += Get-NTNXEvent -Page $i -count 1000$i++}until((Get-NTNXEvent -Page $i -count 1000).count -eq 0 )

$result | export-csv "Path & filname to save the csv file"

Regards,
Sandeep MP

Reply