Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Group policy question 1

Status
Not open for further replies.
Feb 10, 2003
2,749
0
0
US
2003 Server. 6 XP workstations.

Why someone implemented VBS scripts and multiple group policies for mapping 3 drives and 2 printers is beyond me. Such a small network.

Anyways, I have created a login script to clean up drive mappings for this small network.

The problem is, every time I reboot one of these machines, the default printer switches to a printer that I do not want to be the default printer.

I believe this is a group policy setting on the server, although I suppose it could be something done locally to each machine as well in the past.

Any suggestions as to what setting would cause this?
Thank you in advance.

Matt

Please always take the time to backup important data and verify that backup, before making any changes suggested.
 
You can set the default printer via VBS, not through GPO.

We use a script to attach the relevant printers to the right computers and set the default printer for that system. If you would like I'll dig it out and paste it on here tomorrow.
 
Could you? Thanks.

There are 2 VBS scripts on the server, and I don't see any statements that would seem to set a default printer. But then again, I don't use VBS scripts.

I don't see any calls locally on each workstation that would execute a VBS script, I believe there is a GPO on the server that is possibly executing something every login.

That is how their mapped drives were happening, a login.vbs script was executing upon login, via group policy. The same for a printer.vbs, I just did not see a statement to set the default printer.

Matt

Please always take the time to backup important data and verify that backup, before making any changes suggested.
 
Yes, the login.vbs is being implemented via GPO, probably on the User Configuration (since it is called login.vbs) of a GPO.

I would combine the scripts into a single script if you can and reduce the code down as much as possible.

I'll post ours up tomorrow and I'll let you have the mappings and printing as a complete package to see how we do this.

There is a tool for setting the printers and default printer within Server 2003 SP2 so you may have this running but it is unreliable. Scripting is still the best way forward.
 
I appreciate it. And if you can give me info on that tool with SP2 that would also appreciate it. This tool sets the default printer on workstations, or just on the server itself?

Matt

Please always take the time to backup important data and verify that backup, before making any changes suggested.
 
Sorry for the delay. I was called to anunexpected meeting on the 13th and then have been away for the weekend. Anyhow, here's the code. I have trimmed it down so have removed drive definitions etc but the printer elements are all correct and work.



---------------------------------------------------

FOR LOOP_COUNTER = 0 TO objPrinters.Count - 1 Step 2
IF Left(objPrinters.Item(LOOP_COUNTER +1),2) = "\\" THEN
objNetwork.RemovePrinterConnection objPrinters.Item(LOOP_COUNTER +1),TRUE,TRUE
END IF
NEXT

SELECT CASE left(strComputer,4)
CASE "JUPI"
objNetwork.AddWindowsPrinterConnection "\\hermes\JUPITER_COLOUR"
objNetwork.SETDefaultPrinter "\\hermes\JUPITER_COLOUR"
CASE "RMR4"
objNetwork.AddWindowsPrinterConnection "\\hermes\RMR4_BLACK"
objNetwork.SETDefaultPrinter "\\hermes\RMR4_BLACK"
CASE "SATU"
objNetwork.AddWindowsPrinterConnection "\\hermes\SATURN_BLACK"
objNetwork.SETDefaultPrinter "\\hermes\SATURN_BLACK"
CASE "RM17"
objNetwork.AddWindowsPrinterConnection "\\hermes\RM17_BLACK"
objNetwork.SETDefaultPrinter "\\hermes\RM17_BLACK"
CASE "ILCG"
objNetwork.AddWindowsPrinterConnection "\\ILCG-00\ILCG_BW"
objNetwork.SETDefaultPrinter "\\ILCG-00\ILCG_BW"
CASE "ILCD"
objNetwork.AddWindowsPrinterConnection "\\hermes\ILC_BLACK"
objNetwork.SETDefaultPrinter "\\hermes\ILC_BLACK"
CASE "RMM1"
objNetwork.AddWindowsPrinterConnection "\\hermes\M1_COLOUR"
CASE "RMS3"
objNetwork.AddWindowsPrinterConnection "\\hermes\S3_BLACK"
objNetwork.SETDefaultPrinter "\\hermes\S3_BLACK"
CASE ELSE
END SELECT
 
No sweat. Going to be awhile before I have to worry about this now. But thank you for the post, it is appreciated.

Matt

Please always take the time to backup important data and verify that backup, before making any changes suggested.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top