So interestingly, this isn't happening when I just type these commands into an SSH session. But if you create a script like this in say /tmp/test.sh:
#!/bin/bash apt-get -y purge openssh-server ssh-import-id apt-get -y autoremove shutdown -h now And then execute this through an ssh call like this: $ ssh root@whatever /tmp/test.sh I get the disconnection problem. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1429938 Title: stopping ssh.service closes existing ssh connections To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1429938/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs