/etc/init.d/grub-common uses file from initscripts without a dependency

Bug #1584134 reported by Martin Pitt
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
grub2 (Debian)
Fix Released
Unknown
grub2 (Ubuntu)
Fix Released
Low
Martin Pitt

Bug Description

In yakkety we are only a few away from dropping initscripts from the default install. When purging initscripts, the only failed service at boot is /etc/init.d/grub-common:

● grub-common.service - LSB: Record successful boot for GRUB
   Loaded: loaded (/etc/init.d/grub-common; bad; vendor preset: enabled)
   Active: failed (Result: exit-code) since Fr 2016-05-20 18:17:46 CEST; 23s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 761 ExecStart=/etc/init.d/grub-common start (code=exited, status=2)

Mai 20 18:17:46 donald systemd[1]: Starting LSB: Record successful boot for GRUB...
Mai 20 18:17:46 donald grub-common[761]: /etc/init.d/grub-common: 17: .: Can't open /lib/init/vars.sh
Mai 20 18:17:46 donald systemd[1]: grub-common.service: Control process exited, code=exited status=2
Mai 20 18:17:46 donald systemd[1]: Failed to start LSB: Record successful boot for GRUB.
Mai 20 18:17:46 donald systemd[1]: grub-common.service: Unit entered failed state.
Mai 20 18:17:46 donald systemd[1]: grub-common.service: Failed with result 'exit-code'.

Indeed /etc/init.d/grub-common unconditionally sources /lib/init/vars.sh without depending on initscripts. Of course we don't actually want to add this dependency, but robustify the init.d script to get along without vars.sh. In addition it wouldn't hurt to create a systemd unit for this.

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: grub-common 2.02~beta2-36ubuntu3
ProcVersionSignature: Ubuntu 4.4.0-23.41-generic 4.4.10
Uname: Linux 4.4.0-23-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.1
Architecture: amd64
CurrentDesktop: i3
Date: Fri May 20 18:19:26 2016
EcryptfsInUse: Yes
SourcePackage: grub2
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Martin Pitt (pitti) wrote :
Changed in grub2 (Ubuntu):
status: New → Triaged
importance: Undecided → Low
assignee: nobody → Martin Pitt (pitti)
milestone: none → ubuntu-16.05
Martin Pitt (pitti)
Changed in grub2 (Ubuntu):
status: Triaged → In Progress
Martin Pitt (pitti)
Changed in grub2 (Ubuntu):
status: In Progress → Fix Committed
Changed in grub2 (Debian):
status: Unknown → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 2.02~beta2-36ubuntu8

---------------
grub2 (2.02~beta2-36ubuntu8) yakkety; urgency=medium

  * debian/grub-common.init: Don't source /lib/init/vars.sh, we don't depend
    on initscripts (and don't want to). There is no reason why we would not
    use the LSB log_action_msg in non-verbose (default) mode, most other
    packages use it unconditionally. (LP: #1584134)

 -- Martin Pitt <email address hidden> Fri, 20 May 2016 18:33:35 +0200

Changed in grub2 (Ubuntu):
status: Fix Committed → Fix Released
Changed in grub2 (Debian):
status: New → Fix Committed
Changed in grub2 (Debian):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.