To any of you writing Powershell to consume data from Qualys you may run into error with out of memory issues in Powershell. I finally got feed up and determined it was the Powershell process that ran out of memory.
I looked at this link: Learn How to Configure PowerShell Memory | Hey, Scripting Guy! Blog
And using the following steps with and Powershell command prompt with Admin Priv I did these steps.
- sl WSMan:\localhost\Shell
- Set-Item WSMan:\localhost\Shell\MaxMemoryPerShellMB 4096
- Restart-Service winrm
This boosted the memory allocated to powershell up to 4GB and then my powershell had no issue consuming large files. Change is system wide and permanent.
Mileage may vary let me know if anyone has issues.