I clicked [X]

For some really stupid reason I closed an SSH terminal by clicking [X]. My linode is refusing access now, even after a reboot. I presume this is because of the non-logout logout. Will this allow me back in after an amount of time, or is there anything I can do to get back in soon?.

Any help would be greatly appreciated. Cheers.

7 Replies

Ah! Excellent, that got me in. Many thanks. With regard to normal ssh, will I be able to access again after an amount of time, or is there something I have to do? Again, Cheers!

Did you block SSH access to everyone but a specific IP address?

Did you change the SSH port from 22?

To the first question: No.

To the second: yes, but I'm connecting on the correct/custom-specified port.

Cheers for the help, but I'm in via LISH for the moment, I'll try normal again after a good night's sleep.

Thank you both.

I must confess, I hardly ever log out properly, I just close the PuTTY window; then there's the times when NAT on my end causes my sessions to hang while I'm idle, so I just have to reconnect. I could have three dead sessions still logged in to SSH at any time and still I'll get in fine, so I highly doubt there's any kind of restriction there.

Go into Lish and check netstat to see that ssh is listening and running, and then try logging into ssh via localhost from Lish, just to see if that works.

netstat -tap | grep ssh

Also, you never really specified what "refusing access" means…can you at least connect? Is it rejecting your password? If you can connect and just can't login, it might be worth taking a look at /var/log/auth.log and see if there's anything in there from when you try and login.

You could do something like:

tail /var/log/auth.log

If you can't even connect, ssh might have hung for some reason, or you might have a firewall issue.

If ssh has hung you can probably get away with just restarting it via:

/etc/init.d/ssh restart

Though I've personally never had to do anything like that before, so I don't know what would be causing it to happen.

Geekman, cheers. Restarting SSH seems to have done the trick.

> Also, you never really specified what "refusing access" means…
No, I was getting 'Connection Refused' no matter how I tried to log in.

While I'm usually fairly careful not to [X] out, I seem to remember doing it in Putty before once or twice, and I've never had anything like this happen. This is the first time I've ever done it with a direct terminal ssh - wouldn't have thought that would make a difference, maybe it didn't: it may have just been bad luck…

Probably just one of those days. Again, thank you. It works! :D

If you get "Connection Refused" that means packet REJECT? Do you run a firewall? Firewalls usually DROP the filtered packets by default.

You can always check the service running with "netstat -ltnp | grep ssh" as root under Linux. This should give a hint on which port ssh runs actually.

Also as mentioned above, a thorough inspection of /var/log/auth.log is always advised.

I know it's already resolved, but I always try to investigate what caused this so I can avoid happening it next time.

Edit: I just read geekman has already written things I wrote, sorry for the redundance.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct