Re: [Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-17 Thread Carlo Marcelo Arenas Belon
On Wed, Aug 13, 2008 at 08:34:09PM +0100, Kostas Georgiou wrote: > > It doesn't need to bind privileged ports or anything else > that requires root privileges as far as I can tell with the default configuration it needs root privileges so it can setuid to whatever is configured to run as (nobody

Re: [Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-17 Thread Carlo Marcelo Arenas Belon
On Wed, Aug 13, 2008 at 05:26:21PM -0700, Bernard Li wrote: > On Wed, Aug 13, 2008 at 5:07 PM, Kostas Georgiou > <[EMAIL PROTECTED]> wrote: > > > This is easilly solved by using /var/run/gmetad/ to store the pid with the > > directory owned by whatever user gmetad runs as. Then you run with > > da

Re: [Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-13 Thread Bernard Li
Hi Kostas: On Wed, Aug 13, 2008 at 5:07 PM, Kostas Georgiou <[EMAIL PROTECTED]> wrote: > This is easilly solved by using /var/run/gmetad/ to store the pid with the > directory owned by whatever user gmetad runs as. Then you run with > daemon --user ganglia $GMETAD --pid-file=/var/run/ganglia/gmet

Re: [Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-13 Thread Kostas Georgiou
On Wed, Aug 13, 2008 at 03:47:32PM -0400, Jason A. Smith wrote: > One reason is to write its pid file, normally into /var/run/gmetad.pid, > which usually only root can do. As far as I know, this is how most > daemons operate. Initially start as root, do a few things like write > the pid file and

Re: [Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-13 Thread Jason A. Smith
One reason is to write its pid file, normally into /var/run/gmetad.pid, which usually only root can do. As far as I know, this is how most daemons operate. Initially start as root, do a few things like write the pid file and like you mentioned, bind to privileged ports if necessary, then drop pri

[Ganglia-developers] Any reason why the init script starts gmetad as root?

2008-08-13 Thread Kostas Georgiou
Hi, I just noticed that the default init scripts start gmetad as root and it then does a setuid to nobody. Is there a reason why gmetad needs extra priviliges? It doesn't need to bind privileged ports or anything else that requires root privileges as far as I can tell so a daemon --user nobody $G