Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How to move system in AD to another group with GPO

Posted on 2016-09-23
2
Medium Priority
?
87 Views
Last Modified: 2016-10-03
I have systems that I need to have move to a group when they join the domain based on the system name format.  

so if a systems name begins with pc- I need to be able to have them automatically moved to a group when they are added to the domain.

thanks
0
Comment
Question by:rdefino
2 Comments
 
LVL 14

Expert Comment

by:Schnell Solutions
ID: 41812581
The most that AD can do natively is to put all new systems in a specified OU. By default it is the 'Computer' container, and you can change it to something else. However, you want to modify the group membership according to the system name used to join the computer.

One way to achieve it is to create a manual script that reads the computers that are located in the OU/Container of new PCs and then this scripts read the names there and according to the name it changes the system membership and move the computer somewhere else (it will avoid further processing of the same system). Then you can configure that script to run on a regular basis.
0
 
LVL 6

Accepted Solution

by:
sAMAccountName earned 2000 total points
ID: 41812623
If you are grouping clients based on what role they play (i.e. workstation vs server), Its more reliable to use the "OperatingSystemVersion" property on the object:
PS C:\> (get-adcomputer servername -Properties OperatingSystemVersion).OperatingSystemVersion
6.3 (9600)

Open in new window


I wouldnt rely on a naming convention.  As stated above, the way to solve this is through a task/job which queries the default computers container or some other target (i.e. domain root) for computers which arent in your wanted groups and add them to the right one based on OS version.

Ive done almost identical work at a few different places to good effect.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Group policies can be applied selectively to specific devices with the help of groups. Utilising this, it is possible to phase-in group policies, over a period of time, by randomly adding non-members user or computers at a set interval, to a group f…
In the absence of a fully-fledged GPO Management product like AGPM, the script in this article will provide you with a simple way to watch the domain (or a select OU) for GPOs changes and automatically take backups when policies are added, removed o…
This Micro Tutorial will teach you how to change your appearance and customize your Windows 7 interface to your unique preference. This will be demonstrated using Windows 7 operating system.
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…
Suggested Courses

916 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question