Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I initiated 'do-release-upgrade' over ssh, and then my (client) network connection died.

How can I reconnect to the session which is performing this command?

share|improve this question

3 Answers 3

up vote 4 down vote accepted

You cannot. Your command will be sent a SIGHUP. Take a look at: screen, tmux, nohup, or disown, ...

How to reconnect to a disconnected ssh session

share|improve this answer

If screen is installed, the do-release-upgrade command automaticly starts a screen session. This session can be resumed in another ssh session.

share|improve this answer

Your session was killed when you disconnected.

To be more specific: presuming you su-ed to root, then your su process was a child of your login process, and your 'do-release-upgrade' process was a child of that.

When you disconnected you have killed your login process, killing the related child processes unless one or other them has done the sort of backgrounding that an daemon init does. (OT, but for more information on the latter, you can read about daemon forking at Wikipedia.)

You probably should have used screen, or worked on the system console :-(

share|improve this answer
    
The process was still stuck somehow, as apt-get was locked? –  Jon Skarpeteig Jul 31 '11 at 11:01
    
If do-release-upgrade is something like Debian's apt-get dist-upgrade; then dpkg will detect that the process of upgrading has been interrupted due to the existence of the dpkg lock file (normally /var/lib/dpkg/lock). –  rorycl Jul 31 '11 at 17:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.