Let’s see how to Create SCCM Collection based on the Direct Membership Rule. The direct membership rules can be scripted using automation via PowerShell or admin services.
SCCM Collections are critical in the SCCM environment. We should be careful while creating or modifying collections. The collections can create performance issues in your environment.
I have a couple of posts about How to create collections (static and dynamic) in this series of posts. This post is part of the SCCM Education series of posts! In this post, we will discuss SCCM collections (static).
Related Post – SCCM Collection based on Active Directory OU | The Easy Way.
SCCM Education Posts
- Walkthrough of SCCM Console
- How to Promote Pre-Production SCCM Client to Production
- What is Collection, How to Create SCCM Static Collections Part 1(this post)
- How to create dynamic collections? Create Collection Folders Part 2
- Create AD Group Based SCCM Collection
What are SCCM Collections?
Collections help you to organize SCCM resources. The SCCM resources in this context are devices and users. You can manage or tag SCCM resources into manageable units using the Collection.
Collections = Manageable Units
Collections can be created to match your client management requirements. These collections can be used to perform operations on multiple resources at one time.
SCCM Resources = Devices & Users
What are the Types of SCCM Collections?
This question is tricky. I can’t claim that I’m giving you the correct answer. But following are my thoughts. There are two types of collections Built-in collections and Custom collections.
- SCCM admins create custom collections.
- Built-in collections are out-of-box collections that will already be there when you install an SCCM environment.
More details about identifying built-in collections are explained in the video tutorial below. Also, other different types of groups in SCCM are described below.
We have other types of collections: Static collections and dynamic collections. Static collection SCCM is explained in the below section of this post.
Built-in Collections = Collections created at the time SCCM installation
Custom Collections = Created by SCCM Admins
Video Tutorial – How to Create Static SCCM Collection
What are User and Device SCCM Collections?
Device and User collections are other different types of collections. Device collections are only for managing devices. User collections are for managing users.
We can’t add user resources into device collection and device resources into user collection. A group can contain users or devices. But a collection cannot have both the user and devices. Static collection SCCM is explained in the below section of this post.
User Collection = Only for Users
Device Collection = Only for Devices
What are the types of SCCM Collection Membership rules?
The membership rules are the brain of the Collection. Collection membership rules define the character of each Collection. Membership rules define which user or Device should be part of a particular collection.
Depending on the logic given in the membership rule, a device or user will get added to a particular collection. Static Collection SCCM is explained in the below section.
Members of a collection are specified using direct rules, query rules, or both.
Following are the membership rules
- Direct rule – Choose the users or computers you want to add to a collection. This membership does not change unless you remove a resource from SCCM.
- Query rule – Dynamically update the membership of a collection based on a query that SCCM runs on a schedule.
- Include the collection rule- Include other collection members in an SCCM collection.
- Exclude collection rule – The exclude collection rule lets you exclude the members of another collection from an SCCM collection.
What is Static SCCM Collection?
There are two types of Collection in SCCM. Built-in and custom collections are those two(2) types of collections. We can’t edit or change the built-in collections. However, we can create custom collections as per our business requirements.
I don’t recommend creating two(2) separate Install and Uninstall collections for each application.
Try to avoid creating many loads of collections; this could impact the entire SCCM environment’s performance. We can discuss Collection Best practices in next week’s post.
There are two(2) types of collections in Custom Collections. Static collections and Dynamic collections are those two types of collections. In this post, we will discuss the static Collection in SCCM. Members of a collection are specified using direct rules, query rules, or both.
Static collection SCCM is a group of devices or users that won’t change dynamically. The static Collection uses direct membership rules, and the direct membership rule defines a specific resource.
The members of the static Collection will remain CONSTANT unless there is immediate action to change the membership. We can manually or programmatically adjust the members of the Collection. But SCCM won’t change it automatically.
Static Collection = Direct Membership Rule
How to Create Static SCCM Collections?
As I explained in the video tutorial, you need to use a direct membership rule to create a static collection. In the following sections, I will explain how to develop Static Collections in SCCM. You can use the same method to develop direct Device and static User collections.
Navigate to the SCCM console – Assets and Compliance – Device Collections. You need to Right-click and select “Create Device Collection” from the Device Collections node.
On the General page, provide a Name and a Comment. Then, in Limiting Collection, choose to Browse to select a limiting collection. The Collection will only contain members from the limiting Collection.
On the Membership Rules page of the Create Device Collection Wizard, select the type DIRECT membership rule for this Collection in the Add Rule list. You can configure multiple rules for each Collection.
On the Membership Rules page of the Create Device Collection Wizard, select Direct Rule in the Add Rule list.
Create Direct Membership Rule Wizard
Check the drop-down options for the Resource class: Select the type of resource you want to search for and add it to the Collection.
- Select from System Resource values to search for inventory data returned from client computers.
- Check the drop-down options for Attribute name: Select the attribute associated with the selected resource class that you want to search for.
NOTE! If you want to select computers by their NetBIOS name, select System Resource in the Resource class list and NetBIOS name in the Attribute name list.
I didn’t select the option. But I would recommend testing this in your environment before choosing this option. Select Exclude resources marked as obsolete – If a client computer is marked as outdated, do not include this value in the search results.
I didn’t select the option. But if it’s required for your environment, feel free to use this option. Exclude resources that do not have the SCCM client installed – there won’t be displayed in the search results.
Enter the Value: Enter a value for which you want to search the selected attribute name. You can use the percent character % as a wildcard. For example, to search for computers with a NetBIOS name beginning with “Win11”, enter Win11% in this field.
Select Resources, select the resources you want to add to the Collection in the Resources list and then choose Next.
Click on Close to complete the Create Direct Membership Rule Wizard.
Click on the Next, Next, and Close buttons to complete the creation of the static Collection with the direct membership rule.
How to Manually add a Device or a User to Static Collection in SCCM?
Now, let’s see the easiest way to add additional or new devices to a static collection using the direct membership rule.
Right-click on the Device or user you want to add to an existing device or user collection. Click on the option called “Add Selected Items.”
Select the following option depending on “Add Selected Items to Existing Device Collection” or “Add Selected Items to Existing User Collection.”
Best Practices – Static or Direct Membership Rule-based SCCM Collections
Wait for 2-3 minutes to get members populated in the Collection. Don’t take any actions like Update Membership or Refresh immediately after collection creation.
Do NOT use the “Use Incremental updates for this collection” option for static collections. No Need to Enable – “Schedule a full update on this collection.” I don’t think this option makes much sense for a fixed group.
ConfigMgr Collection Full Incremental Evaluation Status Summary from Console | SCCM or Check and evaluate your collections with the Collection Evaluation Viewer tool https://www.anoopcnair.com/collection-evaluation-viewer
- Introduction to collections in SCCM
- Create SCCM Static Collections (Programmatically or using a script)
- Best Practices of Collection by Roger
Anoop is Microsoft MVP! He is a Device Management Admin with more than 20 years of experience (calculation done in 2021) in IT. He is Blogger, Speaker, and Local User Group HTMD Community leader. His main focus is on Device Management technologies like SCCM 2012, Current Branch, and Intune. He writes about ConfigMgr, Windows 11, Windows 10, Azure AD, Microsoft Intune, Windows 365, AVD, etc.