[Bug 1595759] [NEW] service command does not start legacy SysV scripts if systemd is enabled

Sarah Newman srn at prgmr.com
Fri Jun 24 00:21:19 UTC 2016


Public bug reported:

Version: 1.29ubuntu1 on Xenial 16.04

We have a legacy sysv init script. The command 'service' doesn't operate
on it without the following patch applied:

$ diff -uNr /usr/sbin/service  /usr/local/sbin/service 
--- /usr/sbin/service	2016-02-29 12:24:38.000000000 +0000
+++ /usr/local/sbin/service	2016-06-24 00:08:56.651503942 +0000
@@ -179,6 +179,11 @@
    fi
 }
 
+if [ -f "$SERVICEDIR/$SERVICE" ] && systemctl list-unit-files ${SERVICE} | grep -q '0 unit files listed.' ; then
+    update_openrc_started_symlinks
+    run_via_sysvinit
+fi
+
 # When this machine is running systemd, standard service calls are turned into
 # systemctl calls.
 if [ -n "$is_systemd" ]

** Affects: init-system-helpers (Ubuntu)
     Importance: Undecided
         Status: New

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

Title:
  service command does not start legacy SysV scripts if systemd is
  enabled

Status in init-system-helpers package in Ubuntu:
  New

Bug description:
  Version: 1.29ubuntu1 on Xenial 16.04

  We have a legacy sysv init script. The command 'service' doesn't
  operate on it without the following patch applied:

  $ diff -uNr /usr/sbin/service  /usr/local/sbin/service 
  --- /usr/sbin/service	2016-02-29 12:24:38.000000000 +0000
  +++ /usr/local/sbin/service	2016-06-24 00:08:56.651503942 +0000
  @@ -179,6 +179,11 @@
      fi
   }
   
  +if [ -f "$SERVICEDIR/$SERVICE" ] && systemctl list-unit-files ${SERVICE} | grep -q '0 unit files listed.' ; then
  +    update_openrc_started_symlinks
  +    run_via_sysvinit
  +fi
  +
   # When this machine is running systemd, standard service calls are turned into
   # systemctl calls.
   if [ -n "$is_systemd" ]

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/init-system-helpers/+bug/1595759/+subscriptions



More information about the foundations-bugs mailing list