Skip to main content
Jamf Nation, hosted by Jamf, is a dynamic and knowledgeable community of Apple-focused IT admins and Jamf Pro users. Join us in person, in October, for the annual Jamf Nation User Conference (JNUC) to discover new and better ways to manage Apple devices.
CCT Badge CCA Badge CCE Badge Integrator Badge

A script to Remove Existing Meraki Components and Unenroll from SystemsManager

Are you migrating from CiscoMerkai SystemsManager? Here's a script that @HCSTech wrote (with a tiny bit of help from me) to remove both the agent and the profile.

Also you might want to see this article on how to add this as a preinstall script to your QuickAdd package.

#!/bin/sh

####################################################
## Remove Existing Meraki Components and Unenroll MDM
####################################################

#!/usr/bin/env bash 

launchctl unload /Library/LaunchDaemons/com.meraki.agentd.plist
/bin/rm -f /usr/sbin/m_agent /usr/sbin/m_agent_upgrade
/bin/rm -rf '/Library/Application Support/Meraki/'
/bin/rm -f /Library/LaunchDaemons/com.meraki.agentd.plist

/usr/bin/profiles -R -p com.meraki.sm.mdm


exit 0    ## Success
exit 1    ## Failure
Like Comment
SOLVED Posted: 7/17/17 at 12:30 AM by saul.herman

We just went through the same change and put together almost exactly the same script. Works really well!

Like
SOLVED Posted: 8/24/17 at 12:48 PM by mrben

Thank you @arekdreyer. So far so good over here.

Like