Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I can not run the after rolling back my system from time machine.

Mac OS X Version 10.6.2

It displays the following error. "Your are not authorized to run this application" "The administrator has set your shell to an illegal value"

After that I have deleted the file ~/Library/Preferences/

But the same message is displayed.

I have repaired all system rights with the DiskUtility but that did not help.

share|improve this question

migrated from Nov 13 '09 at 12:46

This question came from our site for professional and enthusiast programmers.

10 Answers 10

Rebooting is the answer in OS X Lion. If you lose the ability to write to USB or network drives, the solution is the same.

I'm hoping for some swift updates to get rid of some of these annoying problems.

share|improve this answer

This value is set to /bin/bash. Nothing to change here. I have controlled these preferences. I get this error for every shell.

Finally I found the solution. In Finder I go to open folder /etc. There I found the file /private/etc/shells, which was empty. I replaced the file /private/etc/shells with the backup file /private/etc/shells~orig.

Now the /private/etc/shells contains the following:


(There are more steps needed in Finder, delete empty shells file, change permissions in the information dialog.)

Now I can start the with the /bin/bash again.

share|improve this answer
I found that my account wasn't even able to see the /etc /bin folders for some reason though I can see them from a local admin account also on the machine (my main account is a corporate domain account). Thought about using CHMOD from the admin account to change access to the /etc /bin directories. – ScottCher May 10 '11 at 21:27
Consider accepting your (or another) answer to this question. – Daniel Beck May 14 '11 at 3:35

I had the same problem after a Time Machine restore, in this case, using the backup from a MacBook Pro to restore to a MacBook.

I was able to solve the problem just using Finder (enter your password each time requested):

  • Use Go > Go to Folder to go to "/private"
  • Select "etc"
  • Command-I to bring up the Information pop-up (don't close it again till the end of this procedure)
  • Click the lock symbol in lower right corner to unlock permissions
  • Make a note of the permission setting for "Everyone"
  • Click the permission setting for "Everyone" and select "Read & Write"
  • Use Go > Go to Folder to go to "/private/etc"
  • I found that "shells" was empty, but there was a "shells~orig" with a good list of shells in it
  • Delete "shells"
  • Select "shells~orig"
  • Command-C, Command-V to copy-and-paste it; this creates "shells~orig copy"
  • Select "shells~orig copy
  • Click again to enter rename mode and change name of "shells~orig copy" to "shells"
  • Return to the Information pop-up and change the permission setting for "Everyone" back to its original value
  • Close the Information pop-up

Now that I had a "shells" file with a valid list of shells, I was able to open Terminal again.

share|improve this answer

Right-click your account name in System Preferences' Accounts pane and choose Advanced Options. Change the value for "Login shell" - I use /bin/bash, but you're free to use any installed shell.

share|improve this answer

I had the same problem; a reboot did the trick for me. Not used to having to do that on a Mac :-P

share|improve this answer
Same with me (on Lion). Other apps were acting up (like BBEdit) so I figured I'd try a restart first and it worked. – nevan king Sep 6 '11 at 10:57

I had the exact same problem too. Simple solution:

Just run Repair Disk Permission with Disk Utility :-).

share|improve this answer
Thanks. This worked for me! – pjvds Dec 28 '12 at 21:11

Changing my user account password via System Preferences fixed this for me(I changed it to the same value, which presumably just forced the OS to write some user account info to files). I use Mac OS X 10.7.3 and no files in /etc seem to have been changed.

share|improve this answer

Combining answers from Tim and chemm was useful in my case.

I used Tim's approach to bring up a terminal using a different shell. I then edited /etc/shells to include the preferred shell and then used Tim's approach again to restore the original shell path in the "Advanced Options".

share|improve this answer

I had the same problem. Time Machine for some reason turned /private/etc/shells into a zero length file during my restore. chemm's answer is pretty good, but misses some steps for Mac noobies like me.

  • To even get to /private/etc you need to use the Finder menu item Go -> Go to Folder option and type /private/etc
  • Then locate the shells file.
  • It would not allow me to edit the file at all, so I deleted it.
  • Then I used time machine to restore that file.
  • If you enter the time machine while in Finder it'll start you off in that /private/etc folder.
  • When I restored it, I could not figure out how to direct Time Machine to that folder (didn't see a go to folder option), so I restored "shells" to my desktop and then used Finder to copy/paste the file to /private/etc

You'll need to supply your password a few times to achieve the above, and I suppose you'll need to be on an administrator account.

share|improve this answer

For me, none of the standard answers was the issue - everything was as-it-shoud-be.

Quitting my Aquamacs (emacs) session fixed the problem ! When I restarted Aquamacs, Terminal continued to work fine.

I had NOT used the emacs shell command, but somehow these applications still interacted in an unfortunate way.

share|improve this answer

You must log in to answer this question.

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