While running below PowerShell command remotely to compress the folder into zip format, getting 'System.OutOfMemoryException'
PS > Compress-Archive -Path \\myserver1\Backup\8159 -DestinationPath \\myserver1\Backup\8159.zip
While running the same command as shown below in myserver1 machine directly then getting Exception calling "Write" with "3" argument(s): "Stream was too long."
PS > Compress-Archive -Path E:\Backup\8159 -DestinationPath E:\Backup\8159.zip
I verified below as well
Get-Item WSMan:\localhost\Shell\MaxMemoryPerShellMB
WSManConfig: Microsoft.WSMan.Management\WSMan::localhost\Shell
Type Name SourceOfValue Value
---- ---- ------------- -----
System.String MaxMemoryPerShellMB 2147483647
Get-Item WSMan:\localhost\Plugin\Microsoft.PowerShell\Quotas\MaxMemoryPerShellMB
WSManConfig: Microsoft.WSMan.Management\WSMan::localhost\Plugin\microsoft.powershell\Quotas
Type Name SourceOfValue Value
---- ---- ------------- -----
System.String MaxMemoryPerShellMB 2147483647
Could anyone help me out here?
Thanks in advance...