PuTTY closes after login

2

1

I'm logging in through my schools host and everything works fine, I exited earlier and now anytime I try to log back in, PuTTY automatically closes. I also used the Google Shell to see if it was an issue with PuTTY but I still get logged out. Here is the output I get:

Last login: Tue Feb 14 21:51:02 2017 from rsrch-bd09s72.ucads.uc.edu
/home/ep69674/.profile[3]: Class: not found [No such file or directory]
/home/ep69674/.profile[7]: 1.: not found [No such file or directory]
/home/ep69674/.profile[14]: 2.: not found [No such file or directory]
/home/ep69674/.profile[15]: what: not found [No such file or directory]
/home/ep69674/.profile[22]: 3.: not found [No such file or directory]
/home/ep69674/.profile[29]: 4.: not found [No such file or directory]
/home/ep69674/.profile[32]: ________________: not found [No such file or directory]
/home/ep69674/.profile[36]: 5.: not found [No such file or directory]
/home/ep69674/.profile: line 36: syntax error: `(' unexpected
Connection to rwclinux.rwc.uc.edu closed.
NaCl plugin exited with status code 3.

Side note: I'm also using SSH

lollercoaster

Posted 2017-02-15T03:12:08.440

Reputation: 21

Answers

3

It seems as though your .profile file has become corrupted, and is preventing your account from logging in.

This will likely require you to contact your system administrator to fix the file.

I've looked through a few "How to bypass .profile on login" articles, and though I don't have access to PuTTy to see if these flags can be set somehow, specifying bash --noprofile as the remote command might allow you to login.

Someone also reported that they were able to regain control by sending Control-C during the login process.

Should you be able to get access to your account this way, you may wish to run

mv .profile .profile-copy

so you can get back into your account without trickery in the future.

Nevin Williams

Posted 2017-02-15T03:12:08.440

Reputation: 3 725

1To specify the remote command, go to Connection > SSH > Remote Command. – Martin Prikryl – 2017-02-15T06:49:45.897

2

Try to copy the .profile from the remote using pscp.exe, for backup:

pscp user@host:.profile .profile.bak

And then replace it with an empty file:

echo > empty
pscp empty user@host:.profile

As a sanity check, try to login again using PuTTY. With the new empty .profile, it should work. Then edit the copy of .profile locally, try to fix the errors, and copy it back to the server. Repeat until all problems in .profile are resolved (you successfully log in).

janos

Posted 2017-02-15T03:12:08.440

Reputation: 2 449