1

A folder called "Applications" randomly appeared on my desktop, which has been impossible to delete. The directory's contents are two baloney files of zero bites each--but neither of which I can manually-assign permission to in order to delete (even by command line). Goal: delete Applications with the two files inside it. This can't be done from Desktop--I don't have permission.

From a regular boot (logged in as myself), I run Terminal and type: sudo rm -R /Users/<me>/Desktop/Applications I give it my password. Then see this:

rm: /Users/<me>/Desktop/Applications/Karabiner-Elements.app/Contents: Operation not permitted override rwxr-xr-x root/wheel schg,uchg for /Users/<me>/Desktop/Applications/Karabiner-Elements.app?

I type "yes" [enter], and see this: rm: /Users/<me>/Desktop/Applications/Karabiner-Elements.app: Operation not permitted

Now trying same by entering Terminal by booting into Recovery mode. Using the very well-written answer provided by @klanomath here, I am somehow running amok.

For starters, my command-line prompt is: -bash-3.2#. From there, an ls command will present Macintosh HD and Macintosh HD - Data among the handful of volumes listed. But getting to my username isn't working. I get a "No Such file or directory."

I'm not a Terminal expert. If anyone knows the basic navigation maneuvers for me to get to my own desktop from Terminal in Recovery mode, I'd be grateful. Thanks in advance!

Edit: I am also following this thread and should note that I do have FileVault activated.

Edit 2: Tried Gordon's steps from his comment below.

First, his path syntax DOES work. By entering this (replacing "ryan" with my username), I end up with another prompt--probably a good thing! I was confident this would work and just backed-up my internal SSD with Carbon Copy Cloner, so went for the gusto and entered: rm -r /Volumes/Macintosh\ HD\ -\ Data/Users/<me>/Desktop/<directory to inoculate>.

What I got, was totally unexpected: it presented the same override prompts as before. I typed "yes" and enter. Then another. Then another. Then about TEN more of these, so I got tired of this and said eff it (only because I just backed up my entire HD with Carbon Copy Cloner), so I then did a rm -rf /Volumes/Macintosh\ HD\ -\ Data/Users/<me>/Desktop/<directory to inoculate>

Oh boy! Terminal then goes berserk--a few-thousand scroll through at warp speed--as though a 10GB program is being downloaded by command line. 1-2 minutes pass. I restart (to my delight, this was even possible!) but then came the blow: my desktop makes its debut with, yet again, the ever-impossible-to-delete folder called Applications.

This is becoming comical. What more can we do? Thanks in advance!!

Edit 3: pion asked for results from the mount command from normal/single-user mode. Those results are:

/dev/disk1s6s1 on / (apfs, sealed, local, read-only, journaled)
devfs on /dev (devfs, local, nobrowse)
/dev/disk1s4 on /System/Volumes/VM (apfs, local, noexec, journaled, noatime, nobrowse)
/dev/disk1s2 on /System/Volumes/Preboot (apfs, local, journaled, nobrowse)
/dev/disk1s7 on /System/Volumes/Update (apfs, local, journaled, nobrowse)
/dev/disk1s5 on /System/Volumes/Data (apfs, local, journaled, nobrowse)
/dev/disk1s1 on /Volumes/Bye Bye (apfs, local, journaled)
map auto_home on /System/Volumes/Data/home (autofs, automounted, nobrowse)
13
  • I'm confused. You've tried rm but you haven't yet identified the actual directory location? What did you try rm on? – Tetsujin Mar 14 at 18:54
  • Hi. Sorry for confusion. I am going to edit the post to provide this info. Give me a few mins. Thanks for responding! – Ryan Mar 14 at 19:03
  • 1
    In Recovery mode, you'll have to use something like cd /Volumes/Macintosh\ HD\ -\ Data/Users/ryan (or whatever your username is) to get to your regular home directory. Note that you can use Tab completion while typing this -- type in part of the path, then hit the Tab key, and it'll try to autocomplete the next part of the path for you. Very helpful for getting things like escaped spaces right. – Gordon Davisson Mar 14 at 19:04
  • 1
    Can you detail exactly how you determined that this folder only contains 2 files of 0 byte size? - It seems from the other outputs that you have quoted, that it contains for example the Karabiner Elements app. Are you sure it is not a link to your actual application folder, or something like that? ... Perhaps include the outputs of running this command in the Terminal: "ls -lha ~/Desktop/ | grep Applications" – jksoegaard Mar 14 at 20:17
  • 1
    That schg,uchg part implies that the files are locked against changes at both the user (uchg) and system (schg) levels (see the chflags man page). These locks are independent of normal file permissions, so a lot of the normal overrides won't work at all. From Recovery mode, try chflags -R nouchg,noschg /Volumes/Macintosh\ HD\ -\ Data/Users/<me>/Desktop/<directory to inoculate> and see if that makes them deletable. Note: the schg flag used to be removable only in single-user mode, so I don't know if this'll work in Recovery. – Gordon Davisson Mar 16 at 4:10

You must log in to answer this question.

Browse other questions tagged .