[Pkg-sysvinit-devel] Bug#783990: initscripts: mount efivars directory during boot when using sysvinit

Pearson, Greg greg.pearson at hp.com
Fri May 1 20:52:51 UTC 2015


Package: initscripts
Version: 2.88dsf-59
Severity: normal

# uname -a
Linux sa1 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt9-3~deb8u1 (2015-04-24)
x86_64 GNU/Linux

I installed Debian on a HP ProLiant DL580Gen9 system in UEFI mode using
"debian-8.0.0-amd64-DVD-1.iso". After the installation finished I
installed the sysvinit-core package (2.88dsf-59) and rebooted the
system. This replaces systemd with sysvinit. I then checked if the
directory /sys/firmware/efi/efivars was mounted and it was not. It seems
like a good idea to have this directory automounted on boot so EFI tools
use the new interface to access EFI variables.

One possible solution would be to add the following to
/etc/init.d/mountkernfs.sh which is delivered by the initscripts package:

    if [ -d /sys/firmware/efi/efivars ]
    then
        domount "$MNTMODE" efivarfs "" /sys/firmware/efi/efivars efivarfs ""
    fi

This would also require a change to the kernel configuration file so
efivarfs is available when mountkernfs.sh runs:

    CONFIG_EFIVAR_FS=y

If this change was made, it might also be good to disable the old
interface (/sys/firmware/efi/vars) with the following change to the
kernel configuration file:

    CONFIG_EFI_VARS=n
    CONFIG_EFI_VARS_PSTORE=n

The newer Secure Boot related tools such as efitools and sbsigntool only
work with the newer interface. I don't think these are include in Debian
yet, but if they plan to be it would be good to have the new interface
ready.

Existing EFI utilities such as efibootmgr and efivar check
/sys/firmware/efi/efivars first and if available they use it, if not
available they use the legacy interface.

--
Greg



More information about the Pkg-sysvinit-devel mailing list