Add-PrinterDriver on Windows Server 2012


this question in addition following thread marked answered:

http://social.technet.microsoft.com/forums/windowsserver/en-us/7a2db68a-659d-4ba2-b732-52b55b9688cd/addprinterdriver-infpath?forum=winserverpowershell

here's i'm trying achieve:

we're using 10 printserver appliances publishing 1k printer queues ad , making them available users. sometime year printserver appliances have replaced windows printserver, because of ongoing problems regularly encounter current solution.

i tried create powershell script migrate printers appliances windows server, checks published queues in ad, installs needed drivers on windows server , installs printers last step.

i rather happy see new cmdlets introduced server 2012 seemed pointed @ wanted achieve.

here's current problem:

using add-printerdriver didn't work should majority of our printers drivers not available in windows driver store default.

using add-windowsdriver didn't work allows drivers installed offline images, not running system.

using pnputil add driver driver store worked great, although feels break in technology usage when calling powershell.

but, down core problem, add-printerdriver doesn't seem recognize x86 driver in driver store if added pnputil. here's example hp postscript universal printer driver (commands taken script mentioned earlier):
ps c:\windows\system32> pnputil -a $availablex64drivers[$printer.drivername].driver microsoft pnp utility  processing inf :            hpcu155v.inf driver package added successfully. published name :            oem11.inf   total attempted:              1 number imported: 1   ps c:\windows\system32> pnputil -a $availablex86drivers[$printer.drivername].driver microsoft pnp utility  processing inf :            hpcu155d.inf driver package added successfully. published name :            oem16.inf   total attempted:              1 number imported: 1   ps c:\windows\system32> add-printerdriver $printer.drivername -printerenvironment "windows x64" -erroraction stop  ps c:\windows\system32> add-printerdriver $printer.drivername -printerenvironment "windows nt x86" -erroraction stop add-printerdriver : specified driver not exist in driver store. @ line:1 char:1 + add-printerdriver $printer.drivername -printerenvironment "windows nt x86" -erro ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + categoryinfo          : notspecified: (msft_printerdriver:root/standardcimv2/msft_printerdriver) [add-printerdriver], cimexception     + fullyqualifiederrorid : hresult 0x80070705,add-printerdriver    ps c:\windows\system32> 

the file hpcu155v.inf confirmed correct x64 driver , file hpcu155d.inf confirmed correct x86 driver. both work correctly when installing them using printer driver wizard.

hi,

when adding x86 printer drivers x64 print server, we need manually install since 32bit drivers not stored on 64bit server.

please refer below similar thread:

adding x86 printer drivers x64 print server

http://social.technet.microsoft.com/forums/windowsserver/en-us/6067a35d-d9ac-4f52-8beb-9aca3f116e9e/adding-x86-printer-drivers-to-x64-print-server?forum=winserverprint

regards,

yan li


regards, yan li



Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

Error: 0x80073701 when trying to add Print Services Role in Windows 2012 Standard

Disconnecting from a Windows Server 2012 R2 file sharing session on a Windows 7,8,10 machine

Windows 2016 RDS event 1306 Connection Broker Client failed to redirect the user... Error: NULL