Jump to content

Recommended Posts

Posted

Hi there,

 

The problem we have is that due to the way our active directory OU's are setup we cannot assign printers via active directory. This way we have to log on and off several users and modify the registry on each pc manually and individually which takes a lot of time.

 

The print server we have is Server 2008 R2 and our clients are all XP based.

 

I just wondered if there was a quick and easy way to apply default printers to a computer quickly and efficiently either from the server or even the client say a quick setup program or complete working registry that we could import?

 

Any ideas?

Guest TheLibrarian
Posted

Assuming you are using standard print queues, there is a command shell utility available from Microsoft called CON2PRT.

 

I think it's part of the Windows 2000 Resource Kit.

 

Used in the login script it can add / remove network printers connected to server shares and set a network shared printer as default.

Posted

Read the wiki and it's very helpful, thank you.

 

However I do have a question, although it probably sounds stupid, you could put this in a GPO in the Computers Active Directory group, and it will apply to all my sub groups of computers yes? And I'm assuming as you can have a random group after a group that monitors the first 4 characters you could have another group in there monitoring the first 5 letters as well?

Posted

@Darryl_Wilcox: See the 'split' section at the bottom of that page for another example or inspecting the string. It's all just simple VBScript - there's more examples at http://www.technet.com

 

You run the script as a login script. Printer settings are a 'per user' setting.

Posted

We use a KIX script to deploy printers, it can deploy based on user groups as well as machine OUs.

 

All staff get the staff room connected (but not as default) and their faculty printers mapped as well (but not as default) then the printer for the room they are logging into as default.

 

Students just get the printers for the room they are logging into and set as default - if you would like to see a copy of the script, let me know ;) :D

  • Thanks 1
Posted

;#############################################

;# SET UP PRINTERS BASED ON GROUP MEMBERSHIP #

;#############################################

 

; ##############################################

; # SET UP PRINTERS FOR ALL STAFF (Staff Room) #

; ##############################################

IF INGROUP("STAFF")

? "You are in the group 'STAFF'"

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\STAFFRM$")

ENDIF

 

; ##################################

; # SET UP PRINTERS FOR PE FACULTY #

; ##################################

IF INGROUP("PE")

? "You are in the group 'PE'"

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\PEOFFICE$")

$Rcode = SETDEFAULTPRINTER ("\\SERVER24\PE Office HP2015n")

ENDIF

 

 

;###############################################

;# DIM TO LOOK UP ACTIVE DIRECTORY INFORMATION #

;###############################################

 

Dim $objSysInfo

$objSysInfo = CreateObject("ADSystemInfo")

 

 

; ##############################

; # SET UP PRINTERS FOR A05 OU #

; ##############################

If InStr($objSysInfo.computername,"ou=A5") > 0

? "Your PC is in 'A05'"

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\A05$")

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\A05C$")

$Rcode = SETDEFAULTPRINTER ("\\SERVER24\A05 HP2600n MONO")

EndIf

 

; #################################

; # SET UP PRINTERS FOR A9/A10 OU #

; #################################

If InStr($objSysInfo.computername,"ou=A9A10") > 0

? "Your PC is in 'A9/A10'"

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\A9$")

$Rcode = ADDPRINTERCONNECTION ("\\SERVER24\A9C$")

$Rcode = SETDEFAULTPRINTER ("\\SERVER24\A9-A10 HP2600n MONO")

 

EndIf

 

 

 

This is just a short snippet of the script - the actual script is massive!

But hopefully this will give you the idea. Most of all KIX is free!

  • Thanks 1
Posted
I second the use of GPP, we made use of it here after our migration, and it has worked like a real charm so far. The targetting feature as well is pretty darn amazing. It certainally saved us worrying about writing logon scripts.
  • 1 month later...
Posted

I "third" the use of GPP.

I've now got only four group policies with users and computers put into a load of groups to make targetting easier:

1. Printers targetted to users/computers

2. Software targetted to computers

3. Registry settings and file copying targetted to users/computers

4. local admin rights for computers targetted to members of staff in appropriate depts

 

The only reasons I've got more than one policy are that there is no way to target IE proxy settings or WSUS group settings (although I suppose this could be done via registry...)

 

 

Richie

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...