ConfigMgr 2012 R2 – Device Collections

Following on from this post: http://www.deploymentshare.com/post/ConfigMgr-2012-R2-User-Collections, I will now go ahead and create some Device Collections to use with my environment.

If you open up the ConfigMgr Console and navigate to Assets and Compliance / Overview / Device Collections you should see a default collection for All Systems.  Double click on it to open the node.  Select an object and chose Properties from the right click menu to examine it.

image

image

From this window you are interested the System Resource resource class and the properties that are listed below in this windows.  As before, you’re faced with selecting a property that can uniquely identify your needs.  In this example I am interested in creating device collections based on Operating System therefore the Operating System name and Version property of the System Resource class.  It is important to remember that this property includes the name and the version.  I’ll explain why a little further in the post. Let’s go ahead and create the collection.

In the ConfigMgr Console, navigate to Assets and Compliance / Overview / Device Collections and right click on Device Collections selecting Create Device Collection.

image

The Create Device Collection Wizard will start.  Give the collection a Name and under Limiting collection click Browse… and choose the All Systems collection then click on Next.

image

In this example I’m interested in Servers that have a 2012R2 operating system.  On the next step of the wizard you need to add in a Query rule similar to the way I did with User Collections on my previous post.  Click on Add Rule and select Query Rule.

image
The Query Rule Properties wizard will open, now give your query a name and click on Edit Query Statement…
image

The Query Statement Properties wizard will open, from the windows click on the Criteria tab and then the ‘yellow sun’ as I call it image which represents a new criteria and opens the Criterion Properties window.

image

Click on Select… from the Criterion Properties windows and you’ll see the Select Attribute Window.  Now remember the class I selected earlier?  The System Resource Class?  well, now I need to select it and also the attribute of Operating System Name and Version like so.

image

When you click on OK you will return to the Criterion Properties box where you must select your operator and a value.  In this example I’m going to select the is like comparison and use a wildcard as before.    Here is a list of OS Names and Versions to use with your search

Operating System Name | Version
Windows Server 2012R2 & Windows 8.1 | 6.3
Windows Server 2012 & Windows 8 | 6.2
Windows Server 2008 R2 & Windows 7 | 6.1
Windows Server 2008 & Windows Vista | 6.0
Windows 2003 & Windows XP 64-bit | 5.2
Windows XP | 5.1

Notice there is a client and a server operating system tied to the version number?  Earlier I said this would be important to remember.  A server operating system property with present like this “Microsoft Windows NT Server 6.3” (this one represents Server 2012R2) whereas a client operating system will present something like this “Microsoft Windows NT Workstation 6.2” (this one represents Windows 8).  So I’m going to construct my queries with two wild carded searches using the same class and property.

Lets do the first one together.  So above you selected the System Resource Class and the attribute of Operating System Name and Version having clicked on OK it will return us to the Criterion Properties windows where you now set an Operator of is like and a Value of %server% which will first tell the query to pick out servers.

image

When you click OK you should go back to the Query Statement Properties window where you can click on the Criteria tab and then the ‘yellow sun’ to add a second query.  Following through the exact same steps only this time adding a Value of %6.3%.

image

Same Attribute Class and same Attribute for the query.

Now lets examine the Criteria tab of the Query Statement Properties window and look at the query.  You can see that there are two separate queries with an and operator.  If you require to change the and  to an or operator, you can simply click on the button show in this picture.

image

Click OK until you return to the Create Device Collection Wizard windows where you will hit Next > twice and finally Close to create the collection.

One final thing I wanted to show you.  If you have already undertaken your client push, the ConfigMgr database will have collection a list of operating systems available to you so you could chose to do exact matches.  When you are on the Criterion Properties page you can click on the Values… button and this will show you a list of values already in the database, you can select one and chose an Operator of is equal to like this:

image

image

Of course you can get as granular as you wish.  It all depends on your needs.

Repeat the process for the other collections you with to create.  Device collections and User collections are very granular, you can create conditions and use operators to seek out whatever you wish, plenty of collections have been documented on line but I will start a reference page as soon as can and come back to drop a link in place.

Jonathan