/etc /usr /bin /sbin /tmp /var private /core all showing up in Macintosh HD

This is on a default erase and install. I have tried to disable viewing of hidden files but its already off. Any ideas?

-Ron

MacBook Pro 2.4, Mac OS X (10.5.1)

Posted on Dec 24, 2007 8:44 AM

Reply
6 replies

Dec 24, 2007 2:37 PM in response to Mark Jalbert

On my system the "hidden" flag is set for those files and there is no /.hidden file.

From the terminal type:

stat /bin
234881057 546211 drwxr-xr-x 40 root wheel 0 1360 "Dec 22 08:25:38 2007" "Nov 10 13:24:25 2007" "Dec 24 14:16:32 2007" "Sep 10 15:35:37 2002" 4096 0 0x8000 /bin

The "hidden" flag is the 0x8000 (bit 15 set) just before /bin -- I can turn that flag off...

sudo chflags nohidden /bin

stat /bin
234881057 546211 drwxr-xr-x 40 root wheel 0 1360 "Dec 22 08:25:38 2007" "Nov 10 13:24:25 2007" "Dec 24 14:25:39 2007" "Sep 10 15:35:37 2002" 4096 0 0 /bin

The hidden flag is now off (the "0" just before /bin) and the "bin" directory now shows up in the finder.

To make it hidden again:

sudo chflags hidden /bin

stat /bin
234881057 546211 drwxr-xr-x 40 root wheel 0 1360 "Dec 22 08:25:38 2007" "Nov 10 13:24:25 2007" "Dec 24 14:27:34 2007" "Sep 10 15:35:37 2002" 4096 0 0x8000 /bin

And the hidden flag is set again and bin no longer is visible in the finder.

I don't know why those flags are not set in your system, but it appears that Leopard uses those flags instead of the .hidden file (even though the .hidden file seems to still work).\

BTW you can hide any directory or file by setting the hidden flag.

Dec 24, 2007 3:51 PM in response to Ernest Klein

FWIW, an easier way to see the flags is with the "ls -lO" command, where "ls" is the list command, "l" is the lower case letter 'ell' requesting long-form output option & "O" is the upper case letter 'Oh' requesting the command option to show the flags.

For the root level, the complete command would be:

ls -lO /

with the "/" following the final space being the usual forward slash notation for the root directory.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

/etc /usr /bin /sbin /tmp /var private /core all showing up in Macintosh HD

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.