This is Part 2 of my review of the new Application model in Configuration Manager 2012. In Part 1, I covered Detection, what it is and the options used to detect the presence of an application.
Part 2 will cover Requirements.
This is a big area to cover!
What is a Global Condition?
A Global Condition is way to logically group business or technical requirements into a single assigned requirements for an Application. There are 10 areas to explore:
- Active Directory Query
- File System
- IIS MetaBase
- Registry Key
- Registry Value
- SQL Query
- WQL Query
- XPath Query
1. Active Directory
This uses standard LDAP or GC query syntax. Nothing special here and if you know LDAP you can quickly use this to group Business areas to their OU’s, etc.
2. Assembly – Checks in the GAC for the assembly.
3. File System – Searches the file system. Take special note here that you can use System variable including the %UserProfile%. If you do use %UserProfile% it will search all profiles. So be careful what you are identifying as a requirement. See Script option if you need to be more specific. Sorry – no UNC support here.
4. IIS MetaBase – You can check in the IIS MetaBase for a particular setting. Pretty self-explanatory.
5. Registry Key – Can check for a KEY – Both 32 and 64 bit.
6. Registry Value - Can look for a value.
7. Script – Has to be my favorite option. Here you can write in Powershell, VBScript or JScript. With scripts you can be as complex as you want. Big happy dance that you can also check to have the script run as the user.
8. SQL Query – Wow… second favorite option. SQL Query against the default instance – saves me the time from writing it in the Script option. However, take note if you are clustered. As soon as I find time, I ‘ll dedicate a few hours to discuss installation, operations and troubleshooting Configuration Manager 2012 on a SQL Cluster. By the way, have you seen time? I’ve been looking but can’t seem to find it.
9. WQL – Query WMI using this option. Excellent addition.
10. XPATH – Hmm. I’m sure this can be useful. Query XML.
Using the Global Conditions is really “big picture thinking” when it comes to deployment of Applications in an Enterprise environment. Best to use this as a way to logically group like requirements and do the work only once.
Besides the ability to create your own, Configuration Manager 20112 includes 16 pre defined default Global Conditions for you to use.
They are as follows:
- Active Directory Site
- Available internal storage
- Configuration Manager site
- CPU Speed
- Device type
- Disk Space
- Input Type
- Number of processors
- Operating system Mobile
- Operating system Windows
- Operating system language mobile
- Operating system language Windows
- Organization unit (OU)
- Primary device
- Screen resolution
- Total physical memory
Global Conditions return values are mapped as data types. For example, Boolean, String, Integer, etc.
Now onto requirements.
In each Deployment Type you can set Requirements that will be used to evaluate if the Deployment Type applies.
Note that these requirements by default are re-evaluated every 7 days. You can increase this setting as necessary. (client setting - Schedule re-evaluation for deployments)
When you start the “Create Requirement” you have three options
This allows you to pick from a previously created Global Condition or create a new one.
As an example for this review, I created a new Application XML – Notepad. I set the CPU requirement to 100 – something my test box certainly does not have.
After deploying and refreshing my policies, the Client logs files, AppDiscovery.log will show that this Deployment Type is not applicable for my client. This is due to the failure of # of processer in my requirements.
For fun (I’m strange huh), I thought it might be possible to use the Script option to run pre-distribution tasks. For example, deleted old files, etc prior to an MSI installation. While fun, that’s not a good idea as it will run on everybody.
In the following example, I created a custom condition “islegal”.
and added it to my example as such:
Now I can use this to determine if my DT targets are part of my legal team.
There are many combinations of rules that you can create. Each type and combination will have specific results.
Here this might help clarify it for you:
This will come in handy when I start talking about thread surfing; but that’s much later when I find time.
Up Next Part 3. Dependency