Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save timdang/c796f7b97182f395d6df2d19ab0fd8ae to your computer and use it in GitHub Desktop.
Save timdang/c796f7b97182f395d6df2d19ab0fd8ae to your computer and use it in GitHub Desktop.

Disable Device Enrollment Notification on MacOS Catalina

Restart the Mac in Recovery Mode by holding Command-R during restart

Open Terminal in the recovery screen and type:

csrutil disable

Restart Computer Normally

In the terminal, and run the following two commands:

sudo mount -uw /
sudo mkdir /System/Library/LaunchAgentsDisabled; sudo mkdir /System/Library/LaunchDaemonsDisabled;
sudo mv /System/Library/LaunchAgents/com.apple.ManagedClientAgent.agent.plist /System/Library/LaunchAgentsDisabled;
sudo mv /System/Library/LaunchAgents/com.apple.ManagedClientAgent.enrollagent.plist /System/Library/LaunchAgentsDisabled;
sudo mv /System/Library/LaunchDaemons/com.apple.ManagedClient.cloudconfigurationd.plist /System/Library/LaunchDaemonsDisabled;
sudo mv /System/Library/LaunchDaemons/com.apple.ManagedClient.enroll.plist /System/Library/LaunchDaemonsDisabled;
sudo mv /System/Library/LaunchDaemons/com.apple.ManagedClient.plist /System/Library/LaunchDaemonsDisabled;
sudo mv /System/Library/LaunchDaemons/com.apple.ManagedClient.startup.plist /System/Library/LaunchDaemonsDisabled

Restart the Mac in Recovery Mode Again

Open Terminal in the recovery screen and type:

csrutil enable

Restart Normally and Enjoy

@naeminhye
Copy link

Thanks

@hopefermi
Copy link

Tim, this fix solved the problem with Device Enrollment Notification on MacOS Catalina for me. Thanks! But it also removed "profiles" tab in System Preferences, and my sysadmin tells me that it may cause issues down the road. Is any way to resolve that issue, or add the profiles tab by myself? Thanks! Michael

@timdang
Copy link
Author

timdang commented Jun 9, 2020

@hopefermi This moves some launch processes to the disabled folder. If you ever need to properly enroll, you would need to move those files back. I did this for a personal computer that was being prompted to enroll when I joined the network at work. If your machine is company owned, you’d probably want to defer to the sysadmin.

@richievos
Copy link

Just wanted to quickly say thanks! Very helpful!

@emamm1
Copy link

emamm1 commented Sep 24, 2020

This moves some launch processes to the disabled folder. If you ever need to properly enroll, you would need to move those files back.

@timdang How can one do that to move back the file back?

@MAECTPOUA
Copy link

How to take it back. Without reinstall the macos

@muzammil22
Copy link

Does this work for Big Sur ?

@timdang
Copy link
Author

timdang commented Jan 2, 2021

@emamm1 @MAECTPOUA You can sudo mv to move the files back from the disabled back to the LaunchDaemons folder.
@muzammil22 Big Sur is different. There’s other solutions out there, but the process is even more complicated.

@MAECTPOUA
Copy link

@emamm1 @MAECTPOUA You can sudo mv to move the files back from the disabled back to the LaunchDaemons folder.
@muzammil22 Big Sur is different. There’s other solutions out there, but the process is even more complicated.

I can't find the bckp folders that I create. I think they were remove after installing update. So I decide to make a clear install, and everything is ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment