Script to automatically install print drivers
A while back I read the “managing print drivers” document by Wilco van Bragt. The document inspired me to take a good and hard look at our print environment. We were using the Citrix ”Printer Management” feature at that time which always reminded me of the movie “The Hunt for Red October“: Once you started using it, at one point, it would sneak away and you end up, completely losing control over it…no…what I needed was a script, a good script…
I used Wilco’s script as an example and started from there. The script I created does it job quite nicely and things were great for a while but I found that keeping track and creating driverpackages is a lot of work!
We recently replaced some printers and I was asked to install the drivers on my Terminal Servers. Since not all print drivers play a fair game (the HP3005 for example, also installs stuff in your system32 folder!), I ended up at one point, with having driverpackages copying stuff in the Windows, system32 and the spool sub-folders!
This also meant that I had to change my copy script every now and then to reflect all the locations the drivers needed to be copied. (when printers get replaced for other models)
In short…I wanted something easier to install the drivers for me. So I downloaded some sample scripts from Microsoft to see if I could mash some things together to make my life a little easier.
This script will seem pretty simple to all real scripters out there but what can I say..I’m happy with it..!
Prerequisites:
- You have to be able to install printdrivers (duh!)
- You have to be able to connect to your printerserver (test this through typing \\yourprintserver you should see your shared printers)
What is inside the zip file?
- The script of course!
- Addprinters.txt this is the input file for the script. Place your printers in this .txt file (eg: \\yourprintserver\printer1)
The default location of the addprinters.txt is C:\ You can change this but make sure you edit the script to reflect the new location.
Now..simply run the script and sit back and watch Windows automagically install the drivers for you..!
A big thanks goes out to Arne, the ICTFreak from http://ictfreak.wordpress.com/ for being “Beta-tester” and giving feedback..!
Get the script here: printdriverinstall script
EDIT: 09-08-2010 (the powershell version can be found here
If this post helped you out, help me out keeping this site alive and visit some of my sponsers on the left or right..
Thanks..!
Tags: Script, automatic, Printdriver, print driver,installation, Terminal Server
Posted: February 14th, 2008 under SBC.
Comments: 2
Comments
Pingback from | digipulse.nl
Time: March 1, 2008, 11:34 pm
[...] http://www.virtualistic.nl/ wrote a script for installing printers on a Citrix/Terminal [...]
Pingback from Script to automatically install print drivers | Video Driver Blog
Time: February 17, 2008, 10:06 am
[...] jimbob1960: [...]