Network printer installation ran as a job

brandono04's picture

I am having a ton of trouble writing a script to install network printers to all users by dropping a job with this script included. Here is the script im trying to get working.

rundll32 printui.dll,PrintUIEntry /ga /q /n\\server\printer
:: restart print spooler
START /WAIT SC STOP spooler
START /WAIT SC START spooler

After looking through the switches, im using /ga to add it for all users which is very crucial, /q for not displaying error messages, and /n to to out to the network for the printer. I also added the restart of the print spooler on the bottom.

This script sais its completed successfully in the Deployment Console, but no matter who's logged on to the domain, ththis printer doesn't show up. I have tried several other commands such as /in as well as /y and I cannot get it to work.

Any suggestions would be greatly appreciated.

Thank you,

=Brandon

Terry_Reese's picture

Network printer installation ran as a job

Brandon,

Have you verified that the printer may only be getting installed under the profile of the altiris account you are using to do the push?

Though I think this is just a limit to installing this way if I remember correctly.

If that is the case. I would create a job to copy the file down to the workstation and then chain it to a job to create a line in RunOnce in the registry to run your installation script and that way every user who logs in would run it and that would be a work around.

Basically it becomes a login script.

Here is a link also for using that /qa switch:
http://members.shaw.ca/bsanders/NetPrinterAllUsers...

Hope this helps.

~Terry

ericcray's picture

Here is a vbscript I used

Here is a vbscript I used to use:

Option Explicit
Dim objPrinter
Set objPrinter = CreateObject("WScript.Network") 
objPrinter.SetDefaultPrinter "\\printserver\printer"
' End of example VBScript
nrhudson's picture

The script will only truly

The script will only truly run in DS if you run it with a user account instead of the system account. the system account does not have access to a network printer.

Nate Hudson
Senior Systems Engineer
West Bend Mutual Insurance

Nate Hudson
Senior Systems Engineer
West Bend Mutual Insurance

mlkoziol's picture

You may want to adding some

You may want to adding some quotes for your script. The command will not see your switchs due to the space.

START /WAIT "SC STOP spooler"
START /WAIT "SC START spooler"

jasonla's picture

Working in a print media

Working in a print media company we've networked out photo printers so that photographers can print quicker to them. I just saw a commercial on tv for wifi printers with a family sitting on a couch with laptops and cat5 running to their office comp. I have to laugh at this since it's easier and i think more secure just sharing it and connecting rather then having one more wireless device you need to worry about broadcasting.

viddect's picture

why are you not using pct to deliver printer settings and driver

pct would be the easy way to go. You can just capture the printer settings and drivers and deploy that to multiple machines through the deployment console.

Linux Man
Viddect