Quantcast
Channel: Print/Fax forum
Viewing all articles
Browse latest Browse all 1589

Adding network printers to 2003 print cluster

$
0
0

Hi Alan/All,

I am working to add some hand picked print queues from various different servers in our environment and trying to add them to the 2003 print cluster. (around 600 Print Queues) 

Found this power shell command which i believe will help me achieve the same with minimum efforts

function CreatePrinterPort { 
$server = $args[0]  
$port = ([WMICLASS]"\\$server\ROOT\cimv2:Win32_TCPIPPrinterPort").createInstance() 
$port.Name = $args[1] 
$port.SNMPEnabled = $true 
$port.SNMPCommunity = "CHDMread" 
$port.Protocol = 1 
$port.Portnumber = "9100" 
$port.HostAddress = $args[2] 
$port.Put()  

function CreatePrinter{ 
$server = $args[0] 
$print = ([WMICLASS]"\\$server\ROOT\cimv2:Win32_Printer").createInstance() 
$print.Drivername = $args[1] 
$print.PortName = $args[2] 
$print.Shared = $true 
$print.Published = $true 
$print.Sharename = $args[3] 
$print.Location = $args[4] 
$print.Comment = $args[5] 
$print.DeviceID = $args[6] 
$print.Put() 

however even though I am using the print cluster IP, i see the printers are getting added to the printer node where the printer cluster is currently present and not on the cluster.

or else is there a better way to add the network printers remotely to a cluster server :) 




Viewing all articles
Browse latest Browse all 1589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>