You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Get-MgUser fails for a tenant with a large number of users, but Get-MgUser -All -PageSize 400 succeed. #1192
changed the title [-]Get-MgUser fails fo a tenant with a large number of users, but Get-MgUser -All -PageSize 400 succeed.[/-][+]Get-MgUser fails for a tenant with a large number of users, but Get-MgUser -All -PageSize 400 succeed.[/+]on Apr 5, 2022
We've traced the bug to a recursion depth issue in PS 5.1 when there are more than ~250 pages to be fetched. Thanks, Kutsuzawa Ryo (@mr-oliva), and the team, for the memory dumps.
The workaround is to increase the -PageSize to something like Get-MgUser -All -PageSize 400 to reduce the number of pages or upgrade to PowerShell 7.x.
I'm sorry for my late response and understand that there is a problem.
Thank you for check this issue.
I'll try again after update autorest.powershell.
Activity
[-]Get-MgUser fails fo a tenant with a large number of users, but Get-MgUser -All -PageSize 400 succeed.[/-][+]Get-MgUser fails for a tenant with a large number of users, but Get-MgUser -All -PageSize 400 succeed.[/+]peombwa commentedon Apr 14, 2022
Thanks for bringing this to our attention. We are investigating the root cause of this error as it is isolated to PowerShell 5.1.
peombwa commentedon Apr 21, 2022
We've traced the bug to a recursion depth issue in PS 5.1 when there are more than ~250 pages to be fetched. Thanks, Kutsuzawa Ryo (@mr-oliva), and the team, for the memory dumps.
The workaround is to increase the
-PageSizeto something likeGet-MgUser -All -PageSize 400to reduce the number of pages or upgrade to PowerShell 7.x.We will provide a fix in the upcoming release.
peombwa commentedon Apr 21, 2022
A fix will be provided by Azure/autorest.powershell#932.
mr-oliva commentedon Apr 25, 2022
I'm sorry for my late response and understand that there is a problem.
Thank you for check this issue.
I'll try again after update autorest.powershell.
peombwa commentedon May 6, 2022
Kutsuzawa Ryo (@mr-oliva), we've just release version 1.9.6 with the fix - https://github.com/microsoftgraph/msgraph-sdk-powershell/releases/tag/1.9.6. Please give it a try and let us know if the issue persists. Thanks!
watahani commentedon May 10, 2022
Peter Ombwa (@peombwa) Thank you for your assistance. It works fine for me!
mr-oliva commentedon May 11, 2022
Peter Ombwa (@peombwa) I confirmed that the problem has been resolved. Thanks!