Deleting Configuration Profiles through Terminal

Sometimes there’s a need to manually remove a configuration profile deployed by something like Apple’s Profile Manger; if for instance you cannot un-enroll the device, or you cannot access the ‘Profiles’ pane in System Preferences.

There’s a simple way I found to do this in Terminal.
The first command will list all the configuration profiles currently installed.
All these commands need to be run with sudo.

sudo profiles -P

This should present you with a list of all the profiles on the machine.
In my instance, I just wanted to delete all the ones installed, the following two commands will do this:

sudo profiles -d
sudo profiles -D

I found that after running these, some settings in the payloads of these profiles didn’t disappear, but a restart cleared that up completely.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s