create print server port via command line error Win 8

Posted by Benjamin Jones on Super User See other posts from Super User or by Benjamin Jones
Published on 2013-07-01T15:31:13Z Indexed on 2013/07/01 16:24 UTC
Read the original article Hit count: 410

Filed under:
|
|
|

I need to create a Print Server Port via commandline in Windows 8

Per Google search I should be using prnport.vbs script to do so:

cscript c:\Windows\System32\Printing_Admin_Scripts\en-US\prnport.vbs -a -s \\192.168.113.253 -r Xerox_192.168.113.253

However I get this error: **

Unable to connect to WMI service Error 0x800706BA The RPC Server is unavailable.

**

I looked at local services and both RPC and WMI services are started . Also I made sure add remote admin rule to Windows Firewall via command line without success!:

netsh advfirewall firewall set rule group="windows management instrumentation (wmi)" new enable=yes

netsh advfirewall firewall set rule group="remote administration" new enable=yes

NOTE: If I use the GUI to create the print server port then add the printer via command line: rundll32 printui.dll,PrintUIEntry /if /b "Xerox WorkCenter 7535" /F C:\Windows\Inf\WC7545-7556_PCL6_x64_Driver\x2DNORX.inf /r "Xerox_192.168.113.253" /m "Xerox WorkCentre 7535 PCL6" THE PRINTER IS SUCCESSFULLY ADDED.

So its NOT the printer it self!

So how can I successfully add a print server port via command line? Thanks

© Super User or respective owner

Related posts about windows-8

Related posts about vbscript