Tips on how to handle tmpfile changes
Paul Howarth
paul at city-fan.org
Wed Dec 7 17:37:57 UTC 2011
On Wed, 07 Dec 2011 10:13:24 -0600
Michael Cronenworth <mike at cchtml.com> wrote:
> Paul Howarth wrote:
> > Simplest way is just to include the directory in the RPM in the
> > same way as you would if it was anywhere else in the filesystem.
> > That caters for operation immediately after installation, and the
> > tmpfiles script can re-create it on reboot.
>
> The /run/vnstat directory must also be owned by the vnstat user since
> vnstat no longer runs as root. I'll pass this along to the maintainer
> as a solution.
>
> > Is it actually necessary to do this? The default pidfile location
> > appears to be /var/run/vnstat.pid and since on F15 /var/run is a
> > symlink to ../run, the pid file should end up in the right place by
> > default, should it not?
>
> When the vnstat service attempts to start as the vnstat user it will
> be unable to create /var/run/vnstat.pid (a.k.a. /run/vnstat.pid) and
> will exit.
Ah, right, so you need a /run/vnstat directory owned by the vnstat user
and to put the pidfile in that directory.
How about using the vnstatd --pidfile option in the initscript rather
than adding it into the config file?
Paul.
More information about the devel
mailing list