Beginning with the 0.9.1 builds of the munki tools, Munki can query a webserver to determine if there are available seats for licensed software (or any software you wish to make available via optional_installs, yet control the number of deployed copies). In order to use this wonderful new feature here are the things you need.

  • lient running munkitools 0.9.1.x or later
  • Web service that is tracking available seats and that provides information in a specific format in response to queries. One such server is MunkiWebAdmin as of 16 July 2013.

If you have a running instance of MunkiWebAdmin, make sure you’ve updated to the latest code. See this post for instructions on how to update MunkiWebAdmin.

This new functionality is basically a set of stored queries that query the inventory items database to count the number of machines that have a specific thing installed. To add items to the license seat tables, login to the admin interface (http:/your.munkiwebadmin.server/admin) — you may need to use your superuser account).

Click on “Licenses”.

Click the “Add license” button.

tem name contains the name of the thing you are tracking. To take advantage of upcoming integration with the Munki client and Optional installs, this should be the same as the name of the related pkginfo item.

Total is the total number of seats you have available (values seen here are fake).
Cost per seat can be used to track your “per seat” license cost (values seen here are fake).

The next four fields control the query that will be done to find entries in the inventory items table.

Inventory name matches the name of the item in the inventory items table. This is the application name part of the path (minus .app).
Inventory version is the version number of the item. This value supports * as a wildcard to allow you to match all items starting with a major version number.
Inventory bundleid is the CFBundleIdentifier of the item
Inventory bundlename is the CFBundleName of the item
Inventory path is the full pathname of the item.

For any given item, you would use one of Inventory name Inventory bundleid Inventory bundlename Inventory path and optionally Inventory version.

In the example above, the query would be for all items with bundleid=”com.apple.iWork.Keynote” and version starting with “5.” Machines with this item are considered to have iWork09 installed.

For each item you wish to track, you need to specify a unique item to count. For single applications, this is straightforward. For application “suites” this can be a bit trickier and may require some judgement calls.

For Adobe CS4, CS5, and CS6 installs, I am using the presence of the _uninstaller_ application as the thing to count. This allows the mechanism to distinguish between the various suites and individual products.

Outside of the admin interface, tracked installs display like this

How does this work?
During a managedsoftwareupdate run that includes checking with the server for updates, if there are any uninstalled optional_installs, Munki crafts one or more queries of the form:

LicenseInfoURL?name=ItemOne&name=ItemTwo&name=ItemThree

where LicenseInfoURL is the license info URL (for MunkiWebAdmin, that’s something like https://mwaserver/licenses/available/) and ItemOne, ItemTwo and ItemThree are names of pkginfo items.

The server then looks up license seat info for ItemOne, ItemTwo and ItemThree and responds with a plist

curl "https://mwa:8444/licenses/available/?name=MicrosoftOffice2008&name=MicrosoftOffice2011&name=FooBarBaz"

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "https://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>MicrosoftOffice2008</key>
	<false/>
	<key>MicrosoftOffice2011</key>
	<true/>
</dict>
</plist>

The returned plist should contain key/value pairs, where the key is the item name and the value is a boolean: true if there are available seats, false otherwise. If the server has no information for an item (as is the case for item “FooBarBaz”) it is acceptable to return nothing. A request and response for only “FooBarBaz” looks like this

curl "https://mwa:8444/licenses/available/?name=FooBarBaz"

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "https://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
</dict>
</plist>

The returned results are recorded in /Library/Managed Installs/InstallInfo.plist. Any optional_installs item with license seat info gets a new key — licensed_seats_available:

<dict>
	<key>description</key>
	<string>Installs Adobe Photoshop CS5 and related components.</string>
	<key>display_name</key>
	<string>Adobe Photoshop CS5</string>
	<key>installed</key>
	<false/>
	<key>installed_size</key>
	<integer>1028875</integer>
	<key>installer_item_size</key>
	<integer>1028875</integer>
	<key>licensed_seats_available</key>
	<true/>
	<key>name</key>
	<string>AdobePhotoshopCS5</string>
	<key>uninstallable</key>
	<true/>
	<key>version_to_install</key>
	<string>12.0.0.0.0</string>
</dict>

When Managed Software Update is displaying Optional Software, any item with a licensed_seats_available key equal to false will have its checkbox greyed out, preventing a user from selecting it for install. Additionally, the Status column will read “No available licensed seats”.

Note that there is no explicit mechanism for a client to notify the server that it has installed an item (or will install an item). Instead, the client submits an updated ApplicationInventory.plist to the server. The server uses this information to determine the number of installed seats. (A server other than MunkiWebAdmin is free to use some other method to determine the number of installed seats.)

AI Usage Transparency Report

Pre-AI Era · Written before widespread use of generative AI tools

AI Signal Composition

Tone Struct List Instr
Repetition: 0%
Tone: 33%
Structure: 52%
List: 8%
Instructional: 10%
Emoji: 0%

Score: 0.03 · Low AI Influence

Summary

Munki can query a webserver to determine if there are available seats for licensed software.

Related Posts

Fontrestore, Apple’s fix for your fonts

FontAgent Pro is a great font management solution for OS X. One of the best things about it is that its 100% cloud based. You can run the entire thing hosted in their cloud instance or you can run it on your own server. It's a great solution for font management, and does everything from managing your font licenses, users, libraries, and sets. The one problem however is the fact that when deploying a new font solution, you find yourself in a quandary over the right way to deploy it....

Read more

Munki Report-PHP, the new old kid on the block

I have used SCCM for a while now and have to say that I find it very very powerful. The fact that collects plenty of information from the clients, uploads it to a SQL db and keeps a history, plus the ability of create dynamic computer collections based on querys to the SQL and then target those groups with tasks makes it extremely useful in an enterprise environment. Plus the amazing reports you can get if you have an SQL guru around!

Read more

Deploying Printers with Munki on 10.9 Mavericks

You can use Profile Manager to manage printer lists but the functionality is limited. One major issue with managing printer lists with Profile Manager is if you add a printer to an Profile Manager client’s printer list, and the driver file for that the printer isn’t installed on the client system, the printer will be added using the Generic Printer Driver. Even if the printer driver file is installed later the printer continues to use the Generic Printer Driver.

Read more

Updating Munki Web Admin on 10.9 Mavericks Server

Discover the Power of MUNKI: A Robust Solution for Your Mac Management Needs MUNKI is a highly acclaimed product that has earned its place as a top choice among Mac administrators, thanks to its strong community backing and impressive track record. With support from industry giants like Disney and Google, this reliable solution has consistently delivered results across all versions of OSX since its inception. Whether you're managing a small fleet or a large enterprise, MUNKI's robust features and seamless integration make it an ideal choice for any Mac management...

Read more

Packaging & Deploying VMWare Fusion 5.0.1 – 6.0.2

If you're like me and need to deploy VMware in your environment and are unsure of the approach to use, then you have several options. If you use Casper, JAMF has come out with a PDF outlining the best methods for packaging and deploying VMware, its preferences and VMMachines. Since VMWare Fusion 5 however, VMware has included a nice manageable way to deploy VMware to all your machines. This alternative method eliminates the need for third-party tools or scripts, making it a straightforward solution for those who prefer a more...

Read more

10.9 Deploying Mac App Store Packages

If your like me then your happy that Apple has made several of their wonderful software titles free recently, specifically iLife and iWork for Mavericks. Apple has a defined workflow for deployment of these systems. Their method is to have companies enroll into their Volume Licensing Program once enrolled you can download apps from the app store and the iOS store and deploy these seamlessly to your devices with Profile Manager for Mavericks.

Read more

10.9 Mavericks, AutoDMG a match made in heaven

If your like me then you have an entire organization of users who are itching to get their hands on the latest Mavericks operating system and have been told to wait, we are testing. Truth is that its already been tested. I tested it all through the various developer builds and the issues have for the most part been very minimal which is great for a .0 release. However the issue really has been how are we going to deploy it.

Read more

10.9 Auto Enrollment Profile Manger Package

Many years ago when I was managing a fleet of computer using 10.6, I thought that I was a master systems administrator because I had all my computers managed by MCX. It took me years to get MCX working properly across all my systems, but it saved me countless hours of time and energy managing preferences and remote settings for new and existing systems. This made my life so much easier, as I no longer had to manually configure each system individually.

Read more

Backup your website data securely to Amazon S3

Your websites and your systems are only as good as the backup strategy that you have for them. While managing Mac’s you may think that having a strategy for website data backup is not relevant or important. Until you realize all of the technologies that you use on a daily basis that are actually moving to the web platform or cloud. For example OSX Wiki Server and Profile Manager 2 are all 100% web based technologies. If you use a web based ticketing system like Web Help Desk or Spiceworks...

Read more

Roll your own DNS monitoring with DIG, Bash & CRON

If your like me your always looking for ways to be notified of things changing in your IT Environment. There are many tools that you can use to help do this. StatusCake is a great free online tool for monitoring website and IP level uptime and downtime with baked in email notifications. Zeonoss and NAGIOS are great tools that can offer the same with SNMP Monitoring baked in as well.

Read more