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 run OS X.

Following these directions (Installing MySQL on Mac OS X) I added a file to /usr and the contents were


Actually I was trying to get the mysql command to work now I cannot access terminal. All I get is a cursor but no command line. I also cannot find the file I created in the Finder. I used command shift G to find the folder /usr and the file is not there.

share|improve this question
You could try installing another terminal emulator and try to fix the situation through it. – lanzz Jun 5 '12 at 20:34
Note that you can open the Terminal preferences and under Startup tab, you can set Shell open with to /bin/bash. – Harold Cavendish Jun 5 '12 at 20:46
I tried Harrold's suggestion and it did nothing. You might be right that this is not what caused the problem. Around this time I was also logging into mysql directly through its path in /usr/local/mysql/bin/mysql – user138304 Jun 5 '12 at 20:53
.profile perhaps? I was following these directions Step 6 – user138304 Jun 5 '12 at 20:55
Please answer your own question as soon as you can (i.e. in a couple of hours). There's a button below for that. Don't put the solution into the question. Thanks for sticking around! – slhck Jun 5 '12 at 21:31

Why is your bash not starting up?

If your bash is not starting up correctly, one of its configuration files is borked. These are:

  • /etc/profile

And after that, the first one of these it can find:

  • ~/.bash_profile
  • ~/.bash_login
  • ~/.profile

If you followed that tutorial correctly, you created the ~/.profile file. But not in /usr. It should reside in your $HOME directory, which is at /Users/your-username, and known as ~ to the shell. You can put anything you want into /usr and it wouldn't affect bash starting.

Let's remove ~/.profile

Try to go into settings and changing the following:

The command you want to execute is:

/bin/rm /Users/your-username/.profile

Don't forget to untick Run inside shell. Of course, change your-username to your actual short user name. Once you open that Terminal profile, your existing .profile file will be deleted.

You can then uncheck the Run command field and try to start over.

Other means of debugging

If the above didn't help, from the same Run command field, try running:

/usr/bin/tail -n 10 /Users/your-username/.bash_history

This will trace back your last steps, which would be valuable information to add to your post.

Your Terminal shows Could not open a new pseudo-tty?

In that case, a reboot is needed. Somehow you created too many forks, exceeding the file system limits. This should be restored by simply rebooting your Mac.

share|improve this answer
Here is my history /usr/local/mysql/bin/mysql cd /usr/local/mysql ls ls ls ls ls /usr/local/mysql/bin/mysql cd ~ vi .profile However I restarted and the problem went away. Apparently it helps. – user138304 Jun 5 '12 at 21:24
How far did you get with vi? Were you able to save and quit? Well, anyway, if your problem is solved … – slhck Jun 5 '12 at 21:25
I was able to save and quit. – user138304 Jun 5 '12 at 21:27
up vote 1 down vote accepted

I Solved the problem by restarting my computer. I am really not sure what the problem was.

I got the idea because Could not open a new pseudo-tty. appeared in my terminal after following slhck directions to remove my .profile file. then i searched google and found this;


share|improve this answer

You must log in to answer this question.

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