Skip to content

Commit

Permalink
sudo: Use /run as sudo time stamp parent directory
Browse files Browse the repository at this point in the history
Make Sudo compatible with FHS 3.0.

Newer systemd requires `/var/run` to be a symbolic link to `/run`, and
will not bind mount `/var/run` as a tmpfs anymore, if the directory
contains files. So configure Sudo to use `/run`.

From the file `INSTALL`:

>   --with-rundir=DIR
>         Set the directory to be used for sudo-specific files that
>         do not survive a system reboot.  This is typically where
>         the time stamp directory is located.  By default, configure
>         will use the first existing directory in the following list:
>             /var/run, /var/db, /var/lib, /var/adm, /usr/adm
>         This directory should be cleared when the system reboots.
>         On systems that lack /var/run, the default rundir and vardir
>         may be the same.  In this case, only the ts directory inside
>         the rundir needs to be cleared at boot time.

[`/var/run` should be a symbolic link to `/run`.][1] From the
[*Filesystem Hierarchy Standard 3.0* for `/var/run`][2].

> 5.13. /var/run : Run-time variable data
> ---------------------------------------
>
> ### 5.13.1. Purpose ###
>
> This directory was once intended for system information data
> describing the system since it was booted. These functions have been
> moved to /run; this directory exists to ensure compatibility with
> systems and software using an older version of this specification.

For [`/run`][3]:

> 3.15. /run : Run-time variable data
> -----------------------------------
>
> ### 3.15.1. Purpose ###
>
> The purposes of this directory were once served by /var/run. In
> general, programs may continue to use /var/run to fulfill the
> requirements set out for /run for the purposes of backwards
> compatibility. Programs which have migrated to use /run should cease
> their usage of /var/run, except as noted in the section on /var/run.

[1]: https://lists.fedoraproject.org/pipermail/devel/2011-March/150031.html
[2]: https://refspecs.linuxfoundation.org/FHS_3.0/fhs-3.0.html#varrunRuntimeVariableData
[3]: https://refspecs.linuxfoundation.org/FHS_3.0/fhs-3.0.html#runRuntimeVariableData
  • Loading branch information
pmenzel committed Feb 19, 2018
1 parent acaae5e commit 5e74329
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions sudo.be0
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ PATCHURL[0]=""
# bee_patch ${@}
#}

#mee_configure() {
# bee_configure
#}
mee_configure() {
bee_configure \
--with-rundir=/run/sudo
}

#mee_build() {
# bee_build
Expand Down

0 comments on commit 5e74329

Please sign in to comment.