Can I retrieve my disconnected SSH session?

Atheus

Diamond Member
Jun 7, 2005
7,313
2
0
Hi all

my SSH (PuTTY) session disconnected halfway through an apt full-upgrade on a debian Etch box. I still have to hit enter and 'y' a few times before the process can complete and I really don't want to just kill the process and start all over again...

Any ideas how I can get that session back?

I do also have physical access to the machine if nescesary.
 
Last edited:

spidey07

No Lifer
Aug 4, 2000
65,469
5
76
Not that I know of. Once tcp is broken you'd have to do a key exchange/session start.
I wouldn't kill the session unless you were absolutely sure.
 

n0cmonkey

Elite Member
Jun 10, 2001
42,936
1
0
I never do anything like that outside of tmux (or screen if I'm desperate). Had to restart too many long running processes due to bad connections to ever be without one of those programs.
 

Atheus

Diamond Member
Jun 7, 2005
7,313
2
0
Oh damn you're right - aptitude died with the session :(

Thanks for the recommendations anyway I'll look into screen.
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Oh damn you're right - aptitude died with the session :(

Thanks for the recommendations anyway I'll look into screen.

Yea, when a shell dies all of it's children get a HUP signal which, unless the app does something special to handle the signal, causes it to exit.