When you log in to an account in OS X, the Finder process opens and allows you to browse files within that account, organize them, delete them, or open them for editing if needed. However, if you can't log in to the account, then browsing its files may be a bit more difficult.
If a problem occurs in a user account in OS X that prevents it from logging in correctly, then often the solution is simply to remove preference files, caches, or other files that the account loads at log-in. This can be done with the Terminal if you are familiar with Unix commands, but sometimes this can be cumbersome even to experienced users. This is especially true if you're having to move and delete multiple files and folders.
Even if you can log in to another account on the same system, the permissions settings for OS X will prevent you from using Finder to browse files belonging to the first account. In other words, if you're logged in and you try to open a folder that belongs to another user account, you'll get an error message telling you you don't have permission to access it. Apple has so far not made it possible in OS X to allow a Finder window opened in one account to be authenticated as a different account.
To get around this, you can get information on folders and change the permissions settings on them to allow your account access, but doing this and then undoing these changes can be frustrating. Ultimately what is needed is a way to quickly browse and manage another user account's files without altering too many aspects of the system.
Fortunately, OS X's multiuser setup does allow for this to be done (to an extent) by launching an instance of the Finder in the name of the account you are trying to access, or in the name of the "root" account on the system.
Using the root account
The root account in OS X is the main top-level account that has access to all aspects of the system, and as a result can be used to browse any files. It does need to be purposefully enabled, and bear in mind that because it has full access to the system it can be dangerous to use or keep active.
First open the Directory Utility program either in the /Applications/Utilities/ folder or in the /System/Library/CoreServices/ folder in later versions of OS X. Then in the Edit menu choose the option to "Enable root user" and give the user a password. Once that's done, ensure the system's log-in window is set to display a name and password instead of a list of users (done in the Users & Groups or Accounts system preferences).
At this point, log out of the system and then log in with "root" as the username and your new root password. You should now be able to browse any user account and modify or move files.
Launching the Finder under another user account
To avoid using the root account, you can instead open a new Finder instance under the name of the target account, thus getting past the permissions hurdles.
- Quit and close all applications to reveal the desktop.
- Open the Terminal.
- Run the following command to see the active user account, which should be the short name of your current account (this step is optional, but informative).
- Run the following command, replacing USERNAME with the short name of the account you are trying to troubleshoot. Provide the password for this account when prompted.
- Now that you have switched users (su) to the new account, you can confirm that you've done so by again running the following command (as with the first instance, this is optional but a good idea):
- Now run the following command to make sure the Finder preferences for the new account are set to show hard disks on the desktop:
defaults write com.apple.finder ShowHardDrivesOnDesktop -bool true
- With this setting in place, open a new instance of the Finder by running the following command:
At this point you may see a new window appear that has the Finder running in the new account, or you may not; however, you should see a new icon for the hard drive appear on your desktop. It may be in front of or behind other icons, but you can move them out of the way to reveal it and then open it.
With the new Finder window open, you can then navigate to the /Users directory, where you will see the account folder for the target account now looks like a house, indicating that the Finder identifies it as the home directory. From here you can browse through the account's files without any permissions errors blocking your access.
While you will now be able to view the files in the account, there are some limitations to this. The Finder is built so only one instance runs at a time, and as a result its interaction with the mouse when running in this manner has limitations, so while you can browse the files in the account, delete them, and rename them, there are some things you cannot do.
The main limitation is you will not be able to drag and drop files to organize them. However, to overcome this you can spawn another Finder window under the new account (press Command-N with the current window open) and then use keyboard commands to copy or move files, open them, rename them, or trash them.