[arch-general] [PATCHES] About /var/run/ and /var/lock/ checks in daemons

Jan de Groot jan at jgc.homeip.net
Thu Feb 12 02:59:41 EST 2009


On Thu, 2009-02-12 at 05:51 -0200, Gerardo Exequiel Pozzi wrote:
> Hi people!
> 
> I interested to make Arch Linux suitable for use with a /var/run and
> /var/lock that are mounted as tmpfs. But this also helps, in the case
> that not mounted as tmpfs, to make more simple "purge function" for
> these directories at rc.sysinit step.
> 
> In my case this is "just for fun!", but other users can be benefited by
> this, for example "netbook users".
> 
> OK, i initially created rc-script patches for the packages in the extra
> repo that use /var/run/program-name-directory and fails if not exists.
> (these list was obtained with """ for x in $(find
> /usr/share/pkgtools/lists -type f); do egrep -l "var/run/.+" $x;done """
> 
> @@NOTE@@: I will send the patches to the FL individualy per package now,
> reference to this email in FL, and then copy the links to response in
> this email. ;)
> 
> Please review it, thanks in advance. :)
> 
> ** Actually work OK (/var/run)
>   core/openswan-2.4.11-1
>   core/dbus-core-1.2.4-1
>   core/netcfg-2.1.2-1
>   extra/consolekit-0.3.0-3
> 
> 
> ** Patched RC files (/var/run)
>   extra/apache-2.2.11-2
>   extra/bind-9.5.0.P2-1
>   extra/clamav-0.94-1
>   extra/courier-imap-4.4.1-1
>   extra/courier-mta-0.60.0-1
>   extra/cyrus-sasl-2.1.22-10
>   extra/fetchmail-6.3.8-4
>   extra/hal-0.5.11-7 (patched for policykit)
>   extra/laptop-mode-tools-1.47-1
>   extra/lighttpd-1.4.20-2
>   extra/mpd-0.14.1-3
>   extra/policykit-0.9-7 (no rc-script here, patched in hal)
>   extra/samba-3.2.7-1
>   extra/wicd-1.5.8-1
> 
> 
> ** Researched (/var/run)
>   extra/iptraf-3.0.0-2 (Trivial patch for iptraf.c or using a
>             profile.d/iptraf for creating a "iptraf()" or another solution)
> 
>   * Apparently these don't use /var/run/program-name-directory, but
>         maybe a simple "mkdir" to rc-script for precaution.
>     extra/bftpd-2.3-1 (The daemon uses directly /var/run/bftpd.pid)
>     extra/networkmanager-0.7.0-1 (The daemon uses directly
>         /var/run/NetworkManager.pid)
> 
>   extra/wesnoth-1.4.7-1 (this game don't have a rc-script for the
> daemon, if run the /usr/bin/wesnothd without /var/run/wesnothd it fails,
> solution: provide a rc-script)
> 
> 
> ** Pending for research (/var/run)
>   community/pulseaudio-0.9.14-1
>   community/ultimate-ircd-3.0.2-1
>   community/xen-3.3.1-1
>   community/wdm-1.28-2
>   community/dspam-3.8.0-2
>   community/inn-2.4.5-3
>   community/gpsd-2.37-2
>   community/apache13-1.3.41-3
>   community/freeradius-2.1.3-1
>   community/lastfmsubmitd-0.35-1
>   community/selinux-pam-1.0.1-1
>   community/fail2ban-0.8.3-1
>   community/ircservices-5.0.62-3
>   community/p3scan-2.3.2-2
>   community/bind-geodns-9.4.1-1
>   community/jabberd14-1.6.1.1-3
> 
> 
> ** Pending for research (/var/lock)
>   core/dmraid-1.0.0.rc14-2
>   extra/sane-1.0.19-2

If this requires patching so many packages, and given the fact
that /var/run on tmpfs is not default in archlinux, maybe you should try
building /var/run from an initial directory or something like that. This
is also what I use for my OpenBSD router which runs from compactflash
and has /var mounted on ramdisk.



More information about the arch-general mailing list