WMI Filter Best Practice

Posted on 2014-08-28
Last Modified: 2014-09-15
are there any do`s and dont`s? when to use and when not?
Question by:DukewillNukem
    LVL 38

    Expert Comment

    In what context?  Group Policy?
    LVL 34

    Accepted Solution

    WMI Filters are best used by Group Policies
    U can define if particular condition is True, apply GPO else skip.

    WMI filters are best suited when you have single OU containing multiple objects (Say WinXP\ win 7 \win8 computers) underneath multiple OUs, in that case it is easy to put GPO on top level OU and apply WMI filter on GPO to apply specific policy to specific objects
    For Ex: specific registry you want to apply on to windows XP machines only you can apply policy with registry settings which will apply to WinXP machines only based on WMI query

    Do not use multiple WMI filters \ queries in single GPO, it will hamper performance because every WMI filter will be evaluated against condition and if it proved to be true, then only GPO will apply and this may increase startup \ logon time

    As far as possible you should keep your GPO structure simple and use WMI filters only when it is really required, there are other options also available which you can explore like security filtering.

    There are some tools available to test WMI filters before you deploy it in production which will help you to make WMI query accurate

    finally when you cannot segregate your AD objects in separate OUs due to some limitations and you want to apply specific policy to specific objects based on matching criteria, WMI filters are best friend.
    LVL 65

    Assisted Solution

    There aren't really best practice processes for WMI, but there are some gotchas that can prevent them working the way you expect, which are described here:
    Gotcha #1: What does that value look like?
    Gotcha #2: What’s the property name I need?
    Gotcha #3: What does the operator look like?

    The one don't I try to avoid is using the Win32_Product class to query installed software
    How to NOT Use Win32_Product in Group Policy Filtering

    Try and always use the forward only enumerator, as it is a bit faster

    I also don't use CIM_DataFile as it can be very slow, and the syntax is very confusing to get right.

    And lastly I would say test, test, test with as many scenarios you can.


    LVL 34

    Expert Comment

    One more thing with GP preferences you can use item level targeting more effectively rather than WMI filters.
    GP preferences item level targeting use WMI queries only but with more control.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Join & Write a Comment

    To effectively work with Diskpart on a Server Core, it is necessary to write some small batch script's, because you can't execute diskpart in a remote powershell session. To get startet, place the Diskpart batch script's into a share on your loca…
    You might have come across a situation when you have Exchange 2013 server in two different sites (Production and DR). After adding the Database copy in ECP console it displays Database copy status unknown for the DR exchange server. Issue is strange…
    This tutorial will walk an individual through locating and launching the BEUtility application and how to execute it on the appropriate database. Log onto the server running the Backup Exec database. In a larger environment, this would generally be …
    This tutorial will walk an individual through setting the global and backup job media overwrite and protection periods in Backup Exec 2012. Log onto the Backup Exec Central Administration Server. Examine the services. If all or most of them are stop…

    746 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

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now