Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

r_stranger

macrumors newbie
Original poster
Jan 26, 2019
14
2
Hello,

I cannot completely empty my trash. I was solving a network issue last month and had to delete these network files:

AirPortBrcmNIC-MFG.kext
SystemConfiguration [folder] containing: com.apple.Boot.plist

My network is fine now, but these files are still in my trash. When I try to delete them, this is what I get:

“AirPortBrcmNIC-MFG.kext” can’t be modified or deleted because it’s required by macOS.
“SystemConfiguration” can’t be modified or deleted because it’s required by macOS.
“com.apple.Boot.plist” can’t be modified or deleted because it’s required by macOS.


I tried to empty the trash via terminal with this command:

sudo rm -R [path for trash files]

I would get this message:

override rw-r--r-- root/admin restricted for /Users/xxx/.Trash/SystemConfiguration/com.apple.Boot.plist?

I entered 'y' and pressed return.

Then came this message:

rm: /Users/xxx/.Trash/SystemConfiguration/com.apple.Boot.plist: Operation not permitted


–Does anyone know how I can delete these files?? It's been like this for one month and I don't have the knowledge to fix this.

Thank you.
 
I really don't understand why you want to remove kernel extensions, but I'd say the first step is to disable SIP (System Integrity Protection). Then try and see if your Terminal method from your post works. Also, try lsof [path to files] to see if any processes rely on the files to terminate those processes before deletion.
 
  • Like
Reactions: r_stranger
Thanks for you response. I deleted those files while following instructions to troubleshoot networking issues. Supposedly they are recreated on reboot. I hope this is the case. My network is working fine, so I'm guessing that is true.

I tried to use lsof in terminal. It doesn't give me any info/results. Sits for a couple of seconds, then returns to the original prompt with my username.

I'm not sure that I should disable SIP/empty trash until I know for sure that it won't affect anything, however, I'm not sure how to determine this...
 
Thanks for you response. I deleted those files while following instructions to troubleshoot networking issues. Supposedly they are recreated on reboot. I hope this is the case. My network is working fine, so I'm guessing that is true.

I tried to use lsof in terminal. It doesn't give me any info/results. Sits for a couple of seconds, then returns to the original prompt with my username.

I'm not sure that I should disable SIP/empty trash until I know for sure that it won't affect anything, however, I'm not sure how to determine this...


Well, check to see if there's a version of the kext where it should be as well as in the trash. If there is, it will be no issue deleting it. It probably did recreate it on its own
 
Yes, I've been looking. I couldn't find it, so I'm assuming that there are somehow in use while being in the trash. I moved them back to their original locations, however, it copied them rather than moving them. So... back to square one with not being able to delete the extra copies in the trash.

From here, I imagine that it's safe to disable SIP and try to delete them now.
 
Yes, I've been looking. I couldn't find it, so I'm assuming that there are somehow in use while being in the trash. I moved them back to their original locations, however, it copied them rather than moving them. So... back to square one with not being able to delete the extra copies in the trash.

From here, I imagine that it's safe to disable SIP and try to delete them now.

Go for it. If issues occour you can always just revert back with TimeMachine or reinstall macOS
 
  • Like
Reactions: r_stranger
Turning off System Integrity Protection worked. I was able to completely empty the trash.

I've turned SIP on again, and all is well. Thank you.
 
  • Like
Reactions: internetrando
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.