Finding unused scripts in the JSS

mconners
Valued Contributor

Hello Everyone,

I know we can find smart groups, thanks to the work of others, and the attached policies and profiles they may be assigned to. However, I cannot find a way to see this with scripts. Over the years, we have added quite a few scripts to the JSS and now, I wonder how many of these are still valid or even used.

Do any of you have any idea how to locate these "unused" scripts? I suppose I can methodically go through each one comparing it to what is used and where. Granted this could be done and will work, just very time consuming.

Ideally, we should be able to do clean up internally to the JSS and we could have a page we enter in the policy, script, group or other ID and find out where it is being used. Maybe I need to create a feature request, but until then, just curious what others are doing.

3 REPLIES 3

tomhastings
Contributor II

+2
I will be moving to a new Jamf Pro server and would also like have a way to discover many unused items so they are not transferred.
I started by going to Settings > Jamf Pro Information > Jamf Pro Summary and exported: - Computers: - Policies - macOS Configuration Profiles
- Computer Management - Scripts
I have the data but I too see that it will be time consuming to weed out the unused scripts. Hope someone has a better way.

mm2270
Legendary Contributor III

I suggest looking at Spruce here. It takes some time to run, but it will give you a good text based summary of all unused items in your Jamf Pro setup - scripts, packages, policies with no scope, smart groups not attached to anything. That sort of stuff. Then you can take that list and go back to locate them and delete what you want.

mconners
Valued Contributor

Thank you @mm2270 I will get looking at this ASAP! This looks promising for us.