Creating dynamic groups for objects which exist behind a gateway in OpsMgr Part 1

Even when you spend years working on a specific technology occasionally you are pleasantly surprised to find out that something already exists in the product but you are unaware of it.

At the MVP summit one discussion that we had was how we were working on a method in PowerShell to populate groups for objects which exist behind a gateway. Daniele and Bob pointed me to several links which I have included at the end of this blog post. These blogs discuss how you can use a SiteName field when installing a gateway to auto-create groups which include the computer that report to the gateway.

From my tests it appears that it is simple to create a group of objects behind a gateway using this switch during the gateway approval process. The group is auto-created with the name site/<SiteName> and it includes the computer object and the Microsoft.SystemCenter.ManagementService objects. This is totally cool, extremely useful and really not all that well known in the community (as evidenced by a few of our group being aware of this, and myself sitting there picking up my jaw from the floor).

What does the SiteName gateway installation parameter do?

When you install the gateway using this parameter it auto-creates a group using the name that you provide prepended with "Site/" as shown below.

Groups01.png

What objects does this group include?

This group includes the computer object and the Microsoft.SystemCenter.ManagementService objects which report to the gateway.

Groups02.png

 

Resources explaining how to use the "SiteName" gateway parameter:

https://nocentdocent.wordpress.com/2012/05/25/the-road-to-operations-manager-2012-sites-and-gateways/

https://social.technet.microsoft.com/Forums/systemcenter/en-US/f52e8ec0-0a34-444f-a6c7-2b35508ae695/gateway-site-names-as-site-under-user-security?forum=operationsmanagergeneral

http://blogs.technet.com/b/michaelpearson/archive/2010/06/11/gateway-approval-tool-what-is-the-sitename-property-for.aspx

http://blogs.technet.com/b/momteam/archive/2013/11/20/how-to-remove-an-opsmgr-2012-gateway-server-that-is-associated-with-a-site.aspx

 

Summary: Are you looking for a quick way to auto-group computers which report to a specific gateway? Try out the /SiteName parameter when using the gateway approval tool.

 

In the next part of this series I will look at a more complicated example where the requirement is to create auto-populated groups for a variety of objects which exist behind a gateway server including IIS instances, SQL Servers and more!

Leave a Reply

x

We use cookies to ensure the best possible experience on our website. Detailed information on the use of cookies on this site is provided in our Privacy and Cookie Policy. Further instruction on how to disable our cookies can be found there.