PDA

View Full Version : Terminal failure :(




bamboo123
Aug 31, 2010, 10:12 AM
I was following this tutorial

http://www.devarticles.com/c/a/Apache/Using-Apache-and-PHP-on-Mac-OS-X/

and I got to the part where it wants me to type my password, I was unsure so I just quit my Terminal. Something popped out and ask me if I'm sure I want to quit it, I just press yes and my Terminal just quitted. But when I tried to open it again, it don't have the welcome thingy and everything I type don't seem to work :(

Has my Terminal got a bug?

Thanks a lot!! :D



balamw
Aug 31, 2010, 10:19 AM
it don't have the welcome thingy and everything I type don't seem to work :(

There's a welcome thingy? ;) By any chance do you mean the command prompt itself? Could be something in your .bashrc that is getting hung up...

Do you have X11 on your machine? you could use that to run an alternative terminal.

B

bamboo123
Sep 1, 2010, 08:02 AM
There's a welcome thingy? ;) By any chance do you mean the command prompt itself? Could be something in your .bashrc that is getting hung up...

Do you have X11 on your machine? you could use that to run an alternative terminal.

B

what do you mean by this? "By any chance do you mean the command prompt itself?" and this? ".bashrc"? xD

yes I do, but when I use it to open terminal (( command+N right? :s )), the terminal won't work... :(

my terminal (( without using X11 )) looks like this when I open it... without the welcome thingy :(

http://a.imageshack.us/img192/6953/terminalp.png

as empty and white as a white paper :( (( fail remark xD ))

ianray
Sep 1, 2010, 08:16 AM
Type "Control-C". Does anything happen?

balamw
Sep 1, 2010, 08:18 AM
as empty and white as a white paper :( (( fail remark xD ))

OK. No command prompt in Terminal.app or Xterm. So it seems like the problem is in your shell (default shell is bash).

I was hoping it was something to do with the last login stuff Terminal does, but Xterm doesn't, but no such luck.

.bashrc or .bash_profile is a file that controls what the shell does on launch. If something is in there that is hanging you could never get to the command prompt. (a.k.a. welcome thingy).

You could try finding that file (hidden) in your home folder /Users/username or possibly try changing your shell if bash is somehow broken beyond simple repair.

Do you have another user account on the machine you could login to?

EDIT: Try this: From Terminal.app -> Shell -> New Command -> /bin/sh.

This should open a new shell using sh instead of bash. Does that work?

B

bamboo123
Sep 1, 2010, 09:17 AM
.bashrc or .bash_profile is a file that controls what the shell does on launch. If something is in there that is hanging you could never get to the command prompt. (a.k.a. welcome thingy).

You could try finding that file (hidden) in your home folder /Users/username or possibly try changing your shell if bash is somehow broken beyond simple repair.
I can't see the .bashrc or .bash_profile thingy :/ I've even tried using the Spotlight :D

Do you have another user account on the machine you could login to?
no :(

Try this: From Terminal.app -> Shell -> New Command -> /bin/sh.
nothing happens, the same old blank page came up again :(

Type "Control-C". Does anything happen?

nope :( nothing happens :(

LPZ
Sep 1, 2010, 09:24 AM
May I suggest that the OP quit Terminal, delete com.apple.Terminal.plist from ~/Library/Preferences (~ means the user's home folder), and then try restarting Terminal.

If that doesn't help, open Activity Monitor (in Utilities) while Terminal is open, click on Terminal in the Process Name column of the Activity Monitor window, and then click on Sample Process. Copy and post the output.

bamboo123
Sep 1, 2010, 09:51 AM
May I suggest that the OP quit Terminal, delete com.apple.Terminal.plist from ~/Library/Preferences (~ means the user's home folder), and then try restarting Terminal.
I don't understand what you're talking about here xD lol ^^

If that doesn't help, open Activity Monitor (in Utilities) while Terminal is open, click on Terminal in the Process Name column of the Activity Monitor window, and then click on Sample Process. Copy and post the output.
nothing happens... my terminal just hang and nothing happens :(

notjustjay
Sep 1, 2010, 09:54 AM
Maybe this is too obvious, but did you try rebooting?

LPZ
Sep 1, 2010, 09:56 AM
I don't understand what you're talking about here xD lol ^^


nothing happens... my terminal just hang and nothing happens :(

Never mind. I don't have time now to explain further. balamw seems to be on the right track; listen to him.

By the way, maybe you should gain some more experience with Mac OS X before trying to follow old articles about Apache and PHP.

GorillaPaws
Sep 1, 2010, 10:00 AM
I don't understand what you're talking about here xD lol ^^

He posted the path to the file he wants you to delete.

Go to your home folder.
Open the Library folder.
Then open the Preferences folder.
Now search the files here for a file called com.apple.Terminal.plist and move it to the trash (You're not deleting anything important and your Mac will re-create the file on launching Terminal).

Are you running the Activity Monitor program (it's a separate program than the terminal)? You can find it in the Utilities Folder, which is in the Applications folder.

balamw
Sep 1, 2010, 10:00 AM
My bad /bin/sh is just an alias to /bin/bash. Try /bin/tcsh instead. Does that work?

Maybe this is too obvious, but did you try rebooting?

That was next on my list too, but it seems like such a Windows-y thing to do.

EDIT: AFAIK the Terminal plist isn't used by Xterm so I don't see why that would be hanging too. It makes sense to delete it, but the likelihood of it fixing the problem seems low given the other data.

B

bamboo123
Sep 1, 2010, 10:01 AM
Maybe this is too obvious, but did you try rebooting?

how do i reboot? :D

balamw
Sep 1, 2010, 10:04 AM
how do i reboot? :D

Open Terminal and type shutdown -r now

j/k ;)

Apple menu -> Restart.

B

bamboo123
Sep 1, 2010, 10:10 AM
He posted the path to the file he wants you to delete.

Go to your home folder.
Open the Library folder.
Then open the Preferences folder.
Now search the files here for a file called com.apple.Terminal.plist and move it to the trash (You're not deleting anything important and your Mac will re-create the file on launching Terminal).

Are you running the Activity Monitor program (it's a separate program than the terminal)? You can find it in the Utilities Folder, which is in the Applications folder.

hmm... it's not there... the com.apple.Terminal.plist :confused:

http://a.imageshack.us/img227/3923/afsdadfd.png

but when I search for the word terminal, 3 things came out :eek: I thought it may have something to do with my terminal problems :o

http://a.imageshack.us/img832/5064/screenshot20100901at110.png

bamboo123
Sep 1, 2010, 10:15 AM
Open Terminal and type shutdown -r now

j/k ;)

Apple menu -> Restart.

B

ok! :D thx! :D

balamw
Sep 1, 2010, 10:15 AM
Looks like you may be looking at the system /Library/Preferences not the user ~/Library/Preferences.

B

bamboo123
Sep 1, 2010, 10:24 AM
Looks like you may be looking at the system /Library/Preferences not the user ~/Library/Preferences.

B

huh? so am I in /Library/Preferences or in ~/Library/Preferences? :p lol :D I'm confused! xD





thank you, kainjow, for editing my post xD I'm sooo very sorry about the page stretches just now xD

balamw
Sep 1, 2010, 10:29 AM
huh? so am I in /Library/Preferences or in ~/Library/Preferences? :p lol :D I'm confused! xD


You wanted ~/Library/Preferences but what you posted looked like /Library/Preferences because of the Audio folder and lack of Terminal.plist.

Did you try the restart?

B

LPZ
Sep 1, 2010, 11:26 AM
You wanted ~/Library/Preferences but what you posted looked like /Library/Preferences because of the Audio folder and lack of Terminal.plist.

Did you try the restart?

B

balamw, you are a candidate for sainthood. What patience!

bamboo123
Sep 2, 2010, 09:17 AM
You wanted ~/Library/Preferences but what you posted looked like /Library/Preferences because of the Audio folder and lack of Terminal.plist.

Did you try the restart?

B

hey! it worked! :D thx a lot!! ^^ and what about when i have to quit it later? (( meaning how do i quit it :D )) i remember now that the welcome thingy disappeared after I pressed command+Q after using it :D


edit: And I totally agree with LPZ :D thx! Balamw :D

ulbador
Sep 3, 2010, 08:52 PM
hey! it worked! :D thx a lot!! ^^ and what about when i have to quit it later? (( meaning how do i quit it :D )) i remember now that the welcome thingy disappeared after I pressed command+Q after using it :D


edit: And I totally agree with LPZ :D thx! Balamw :D

Hold down control and hit D (case matters) a bunch until the terminal window either closes or says [Process Completed]

DaMonsterMonste
Jan 2, 2011, 11:51 PM
He posted the path to the file he wants you to delete.

Go to your home folder.
Open the Library folder.
Then open the Preferences folder.
Now search the files here for a file called com.apple.Terminal.plist and move it to the trash (You're not deleting anything important and your Mac will re-create the file on launching Terminal).

Are you running the Activity Monitor program (it's a separate program than the terminal)? You can find it in the Utilities Folder, which is in the Applications folder.

i have the same problem but there is no such file i looked in the library folder and nothing with terminal is in the name

DaMonsterMonste
Jan 2, 2011, 11:54 PM
Looks like you may be looking at the system /Library/Preferences not the user ~/Library/Preferences.

B

ok i found and deleted that file and my terminal still didnt work:(

DaMonsterMonste
Jan 2, 2011, 11:59 PM
nevermind reboot fixed it thanks!!!

ulbador
Jan 3, 2011, 12:00 AM
It looks like you hosed your bash profile or bashrc

Open up the Preferences menu option.

Click on the Startup Tab

Move the radio button to "Command (complete path)"

Put

"/bin/zsh"

Without the quotes in the box. Close the preferences and hit Apple-N to open a new Terminal window. If this works, type (These files may or may not exist):

rm ~/.bashrc
rm ~/.bash_profile


Then you can probably change the Preference back (assuming you didn't hose the system-wide one)