[Bug 1656237] Re: Shutdown/reboot hangs forever if an autossh process is started by rc.local

Dan Streetman 1656237 at bugs.launchpad.net
Wed Jun 30 20:04:59 UTC 2021


** Changed in: systemd (Ubuntu)
       Status: Confirmed => Won't Fix

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1656237

Title:
  Shutdown/reboot hangs forever if an autossh process is started by
  rc.local

Status in systemd package in Ubuntu:
  Won't Fix

Bug description:
  If an autossh process is started by /etc/rc.local, a xenial system is
  no longer able to shut down.  It seems to hang forever, not just for a
  few minutes.

  Repro steps:

  As root:

  # Set up an autossh tunnel (in this example, from localhost to localhost):
  apt-get install autossh openssh-server
  ssh-keygen
  cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
  chmod 0600 ~/.ssh/authorized_keys
  ssh root at localhost true
    "yes", accept the fingerprint

  # Test that autossh works:
  autossh -f -L 127.0.0.2:22:127.0.0.1:22 root at localhost -N
  ps auxw | grep autossh
    autossh should be listed

  # Add to /etc/rc.local before exit line:
  autossh -f -L 127.0.0.2:22:127.0.0.1:22 root at localhost -N &

  # Enable rc-local service if necessary:
  systemctl enable rc-local.service

  Reboot.

  After booted into system, `shutdown -r now`.  Observe that systemd
  always hangs forever during shutdown.

  
  # lsb_release -rd                                                                     
  Description:	Ubuntu 16.04.1 LTS
  Release:	16.04

  # dpkg -l | grep systemd
  ii  libpam-systemd:amd64  229-4ubuntu13     amd64        system and service manager - PAM module
  ii  libsystemd0:amd64     229-4ubuntu13     amd64        systemd utility library
  ii  libsystemd0:i386      229-4ubuntu13     i386         systemd utility library
  ii  systemd               229-4ubuntu13     amd64        system and service manager
  ii  systemd-sysv          229-4ubuntu13     amd64        system and service manager - SysV links

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1656237/+subscriptions



More information about the foundations-bugs mailing list