← Back to team overview

touch-packages team mailing list archive

[Bug 1479826] Re: 'systemctl enable apache2' wrongly reports a failure because of update-rc.d backwards compat actions

 

Looks to me like this is more likely a problem in systemd-sysv-generator
than apache2 itself.

** Package changed: apache2 (Ubuntu) => systemd (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1479826

Title:
  'systemctl enable apache2' wrongly reports a failure because of
  update-rc.d backwards compat actions

Status in systemd package in Ubuntu:
  New

Bug description:
  # lsb_release -rd
  Description: Ubuntu 15.04
  Release: 15.04

  # apt-cache policy apache2
      Installed: 2.4.10-9ubuntu1
      Candidate: 2.4.10-9ubuntu1
      Version table:
    *** 2.4.10-9ubuntu1 0
               500 http://archive.ubuntu.com/ubuntu/ vivid/main amd64 Packages
               100 /var/lib/dpkg/status

  # Problem description:
  When using `systemctl enable apache2` to start apache2 by default on bootup, the command returns the returncode 1.
  The systemd service for apache2 itself is generated by 'systemd-sysv-generator' based on /etc/init.d/apache2.

  The output of `systemctl enable apache2` is:

  ```
  Synchronizing state for apache2.service with sysvinit using update-rc.d...
  Executing /usr/sbin/update-rc.d apache2 defaults
  Executing /usr/sbin/update-rc.d apache2 enable
  Failed to execute operation: No such file or directory
  ```

  The content of the generated transient service unit is:

  ```INI
  # /run/systemd/generator.late/apache2.service
  # Automatically generated by systemd-sysv-generator

  [Unit]
  Documentation=man:systemd-sysv-generator(8)
  SourcePath=/etc/init.d/apache2
  Description=LSB: Apache2 web server
  Before=runlevel2.target runlevel3.target runlevel4.target runlevel5.target shutdown.target
  After=local-fs.target remote-fs.target network-online.target systemd-journald-dev-log.socket nss-lookup.target
  Wants=network-online.target
  Conflicts=shutdown.target

  [Service]
  Type=forking
  Restart=no
  TimeoutSec=5min
  IgnoreSIGPIPE=no
  KillMode=process
  GuessMainPID=no
  RemainAfterExit=yes
  ExecStart=/etc/init.d/apache2 start
  ExecStop=/etc/init.d/apache2 stop
  ExecReload=/etc/init.d/apache2 reload
  ```

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