Smart Groups and Model criteria/operator values?

cfsievers
New Contributor

I'm attempting to create a Smart Group for "desktop Macs." We have a number of different iMacs and minis in our environment. But it appears I have to choose from predefined models (e.g., "Model IS iMac Intel (21.5-Inch, Late 2015) OR Model IS iMac Intel (21.5-inch, Mid 2017)," etc., in order to start seeing the Smart Group get populated.

I was hoping/expecting to be able to construct criteria such as "Model LIKE 'iMac' OR Model LIKE 'Macmini' OR Model Like 'MacPro'" since the official Model Identifiers under the hood all use such strings, and they're unique enough across product lines. That way it wouldn't matter what exact iMac or mini models I've got in our environment, and don't have to add new Model criteria when, say, the M3 minis start showing up at some point.

I don't think I'm missing anything obvious, but it wouldn't be the first time something escaped my eye.

2 ACCEPTED SOLUTIONS

sdagley
Esteemed Contributor II

@cfsievers I'm using the criteria "Model" operator "not like" value "Book" to identify desktop Macs. There's some debate on if that's the "proper" way to do it, but it's working for iMacs, Mac Pros, and Mac minis. To identify laptop Macs it'd be criteria "Model" operator "like" value "Book".

View solution in original post

kgam
Contributor

Were using "Model like iMac" or "Model like Mac mini" and so on which is working okay. Just had to update it now after reading this thread as I realized the Mac Studio had been released after last modifying this smart group.

sdagley's method is perhaps more flexible as it will assume that everything not including "book" will be a desktop model so you don't have to update it when new desktops are released.

Screenshot 2023-02-28 at 15.26.48.png

View solution in original post

5 REPLIES 5

sdagley
Esteemed Contributor II

@cfsievers I'm using the criteria "Model" operator "not like" value "Book" to identify desktop Macs. There's some debate on if that's the "proper" way to do it, but it's working for iMacs, Mac Pros, and Mac minis. To identify laptop Macs it'd be criteria "Model" operator "like" value "Book".

kgam
Contributor

Were using "Model like iMac" or "Model like Mac mini" and so on which is working okay. Just had to update it now after reading this thread as I realized the Mac Studio had been released after last modifying this smart group.

sdagley's method is perhaps more flexible as it will assume that everything not including "book" will be a desktop model so you don't have to update it when new desktops are released.

Screenshot 2023-02-28 at 15.26.48.png

cfsievers
New Contributor

Thanks to the both of you; hard to select either response as the solution when they both work. 🙂

I guess I was overthinking it and didn't consider that Jamf is essentially allowing "friendly" names for that field value.

sdagley
Esteemed Contributor II

@cfsievers Part of the Jamf Pro learning process is discovering how to use all of the selection criteria to fine tune what you're looking for, and the addition of regular expression criteria a few years ago brought a major improvement in flexibility. If you have the opportunity to take any of the Jamf certification courses I highly recommend them as a great way to learn a lot quickly.

Regarding marking a response as a solution, you can tag more than one.

kgam
Contributor

Yes, definitely look into regular expressions if you haven't already. They have a bit of a learning curve to them but they are quite powerful and great for checking version numbers and such. Lots of resources online for learning the syntax and you can use sites like https://regex101.com to test and fine-tune your expressions.