Reading Printers with PowerShell

Hi,

I am trying to get all Networkprinters from our Printservers. For this i use the following PowerShell-Command:

Get-WmiObject -class Win32_Printer -ComputerName $PrintSRV.Server | SELECT Name, Systemname

It works fine if the printserver OS is Windows Server 2016 or higher. But now the problem. We still have one old printserver with Windows Server 2008 R2. This server only gives me the local XPS Printer but not the network printers with this script. I also tryed to run it with “Invoke-Command” but with the same result.

Is there another way to get all printers from the old printserver?

 

Best regards

Christian

We donot have any Printerserver (anymore). So it is picking in the dark :slight_smile:

Does this help?

Get-CimInstance win32_printer -Computername $($PrintSRV.Server )
gwmi win32_printer -computername $($PrintSRV.Server )

It does not help. It is the same result. I don’t know why only the Windows Server 2008 R2 does this shit. :frowning:

Hello,

sometimes it is so easy. I use this and it works on all server.

Get-Printer -Computername "Printservername"

Best regards