I'm running the command

sudo chmod 000 /System/Library/CoreServices/AirPlayUIAgent.app/Contents/MacOS/AirPlayUIAgent

Because AirPlay mirroring is messing with one of my programs, but it tells me "Operation is Not Permitted". I'm the owner of this Mac and should definitely be permitted, some help please?

  • Do you have El Capitan? If so, did you turn of SIP? Commented Oct 11, 2015 at 23:02
  • Yeah I have El capitan, what's SIP? (I'm new to mac) Commented Oct 11, 2015 at 23:22
  • SIP (aka rootless) aims to stop you from doing what you're doing (as well as other applications). It stops anything from modifying System files. Commented Oct 11, 2015 at 23:44

2 Answers 2


You'll need to disable System Integrity Protection (SIP). It stops anything from modifying System files.

Disabling SIP: (more info in this article)

  1. Enter Recovery HD
  2. From the Utilities menu, select Terminal
  3. Type in csrutil disable

Turning Off Rootless System Integrity Protection in Mac OS X Again, the vast majority of Mac users should not disable rootless. Disabling rootless is aimed exclusively at advanced Mac users. Do so at your own risk, this is not specifically recommended.

Reboot the Mac and hold down Command + R keys simultaneously after you hear the startup chime, this will boot Mac OS X into Recovery Mode

When the “MacOS Utilities” / “OS X Utilities” screen appears, pull down the ‘Utilities’ menu at the top of the screen instead, and choose “Terminal”

Type the following command into the terminal then hit return:

csrutil disable

You’ll see a message saying that System Integrity Protection has been disabled and the Mac needs to restart for changes to take effect.

Then execute reboot and the Mac will then reboot itself automatically, just let it boot up as normal


Hint: If it does not work on the first time, then close the terminal and reboot, then try again.

WARNING: You should enable it again once you are done, otherwise you are opening a big security hole.

Enable it with csrutil enable

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .