[rrd-developers] [patch] rrdcached init script and spec file

Daniel.Pocock at barclayscapital.com Daniel.Pocock at barclayscapital.com
Wed Oct 8 10:06:07 CEST 2008


 


> > The init script does not work on my system (CentOS 4.x) as 
> is, because 
> > the `daemon` function which I have does not support --pidfile -- is 
> > that argument necessary?

My target for this is RHEL5 - in other words, although I have to run the
gmond agent on quite a diverse range of servers from different
generations of RHEL and other systems, I run gmetad and rrdcached on
machines that are up to date.

--pidfile checks if the process is already running - however, I believe
such a check is made within the program as well, so it is probably not
needed and can be dropped for backwards compatibility with RHEL4/Centos4

When I added that argument, I was hoping that the daemon() function
would also clean up stale PID files, but looking at the
/etc/rc.d/init.d/functions code I can't see any evidence that it does
so.  Therefore, cleaning up stale PID files needs to be done within
rrdcached.

> >
> > Also, as discussed previously, I think it would be a good idea to 
> > create a 'rrdcached' user and group and start the daemon as 
> that user 
> > instead of nobody.  For application-specific (eg. Ganglia) 
> > implementations, we can just put the necessary users (such 
> as nobody, 
> > apache, ganglia) in the rrdcached group.

That sounds fine. Who should own the RRD files, rrdcached or ganglia?

> 
> I think coupled with a split of the package into a cached and 
> a normal one this would be a sensible thing. As I said before 
> the daemon should NOT run as nobody since it writes files and 
> there must never be any files oned by nobody ... (hence the name).

I have no objection to splitting the package, it seems like a sensible
idea for something that most people hopefully will never need.  You will
notice that the init script checks /etc/default/rrdcached for the
variable RUN_RRDCACHED.  That variable is 0 by default, so the current
package won't start the daemon on an unconfigured system.

Regards,

Daniel
_______________________________________________

This e-mail may contain information that is confidential, privileged or otherwise protected from disclosure. If you are not an intended recipient of this e-mail, do not duplicate or redistribute it by any means. Please delete it and any attachments and notify the sender that you have received it in error. Unless specifically indicated, this e-mail is not an offer to buy or sell or a solicitation to buy or sell any securities, investment products or other financial product or service, an official confirmation of any transaction, or an official statement of Barclays. Any views or opinions presented are solely those of the author and do not necessarily represent those of Barclays. This e-mail is subject to terms available at the following link: www.barcap.com/emaildisclaimer. By messaging with Barclays you consent to the foregoing.  Barclays Capital is the investment banking division of Barclays Bank PLC, a company registered in England (number 1026167) with its registered office at 1 Churchill Place, London, E14 5HP.  This email may relate to or be sent from other members of the Barclays Group.
_______________________________________________



More information about the rrd-developers mailing list