I installed Yosemite now and after the installation the terminal is not working. It used to work before, but after installation of the new OS X on Mavericks it is no longer working. How can I resolve this?

If I open the terminal this message is shown:

Last login: Sun Dec 28 00:42:15 on ttys000
login: /usr/local/bin/bash: No such file or directory

[Process completed]
  • Did you have any trouble during the installation? That could cause it not to be copied back. You may have to reinstall homebrew completely if it doesn't work. – 0942v8653 Dec 28 '14 at 1:28
up vote 25 down vote accepted

You installed another version of bash,right? The default login shell is /bin/bash. you can change it following these steps,

  1. go to "System Preferences" > "Users & Groups"
  2. click the "padlock" icon and authenticate
  3. right-click the icon for your user and select "Advanced Options..."
  4. change the value for "Login shell"
  • 1
    Nice, concise. Go with this one OP. – Ian C. Dec 28 '14 at 3:12
  • Bless you! I thought my OS was a goner... – trueicecold Aug 25 '15 at 19:04

Your custom installation of bash is no longer present after upgrading to Yosemite.

If you moved Homebrew aside to make the installation of Yosemite go faster, you can move it back via the Finder and things will work.

Alternatively, you can change the shell used by Terminal.app back to the system-provided bash by selecting Terminal > Preferences from the menu bar (this should still be available even though the Terminal window shows it failed to start) in the Terminal.app and under the General tab set the Shells open with: setting to Command (complete path): and enter:

/bin/bash

in to the command area like so:

enter image description here

This will allow you to open a Terminal window. Once this window is open I strongly suggest you set your default shell back to the system-provided bash by running:

chsh -s /bin/bash

Once you do this, you can change Terminal.app's preferences back to Default login shell.

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.