From a22cddf5c82d3ac69f06f950cc05bba51c5ef7bb Mon Sep 17 00:00:00 2001 From: octo Date: Fri, 16 Dec 2005 12:46:43 +0000 Subject: [PATCH] Merged revisions 317 and 318 from trunk to the branches --- Makefile.am | 2 ++ configure.in | 2 +- debian/changelog | 5 ++++- src/collectd.c | 11 +++++++---- src/collectd.pod | 38 +++++++++++++++++++++----------------- 5 files changed, 35 insertions(+), 23 deletions(-) diff --git a/Makefile.am b/Makefile.am index c60110c4..30beb639 100644 --- a/Makefile.am +++ b/Makefile.am @@ -7,4 +7,6 @@ dist-hook: find $(distdir) -type d -name '.svn' | xargs rm -rf install-exec-hook: + $(mkinstalldirs) $(DESTDIR)$(sysconfdir) $(mkinstalldirs) $(DESTDIR)$(localstatedir)/run + $(mkinstalldirs) $(DESTDIR)$(localstatedir)/lib/$(PACKAGE_NAME) diff --git a/configure.in b/configure.in index d0496025..293fc6ad 100644 --- a/configure.in +++ b/configure.in @@ -1,5 +1,5 @@ dnl Process this file with autoconf to produce a configure script. -AC_INIT(collectd, 3.5.alpha2) +AC_INIT(collectd, 3.5.0) AC_CONFIG_SRCDIR(src/collectd.c) AC_CONFIG_HEADERS(src/config.h) AM_INIT_AUTOMAKE(dist-bzip2) diff --git a/debian/changelog b/debian/changelog index 7199fb7b..215c322d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,11 @@ collectd (3.5.0-1) unstable; urgency=low * New upstream version + * Added dependency to `cpufreqd | powernowd | cpudyn' to `collectd-cpufreq' + * Added `collectd-users' + * Added `--localstatedir=/var' to `./configure' - -- Florian Forster Wed, 07 Dec 2005 11:50:17 +0200 + -- Florian Forster Fri, 16 Dec 2005 13:06:43 +0200 collectd (3.4.0-1) unstable; urgency=low diff --git a/src/collectd.c b/src/collectd.c index 8e92bfbc..af6a93e0 100644 --- a/src/collectd.c +++ b/src/collectd.c @@ -215,13 +215,16 @@ int start_server (void) } #endif /* HAVE_LIBRRD */ -int pidfile_create (void) +int pidfile_create (char *file) { FILE *fh; - if ((fh = fopen (PIDFILE, "w")) == NULL) + if (file == NULL) + file = PIDFILE; + + if ((fh = fopen (file, "w")) == NULL) { - syslog (LOG_ERR, "fopen (pidfile): %s", strerror (errno)); + syslog (LOG_ERR, "fopen (%s): %s", file, strerror (errno)); return (1); } @@ -373,7 +376,7 @@ int main (int argc, char **argv) setsid (); /* Write pidfile */ - if (pidfile_create ()) + if (pidfile_create (pidfile)) exit (2); /* close standard descriptors */ diff --git a/src/collectd.pod b/src/collectd.pod index 55a99edc..935f2fe0 100644 --- a/src/collectd.pod +++ b/src/collectd.pod @@ -76,48 +76,52 @@ Number of users logged into the system (I) =over 4 +=item B<-l> + +Start in local mode. This is the default. No data will be sent or read to/from +the network. Information will be read and written by the same process. See +L<"MODES">. + =item B<-c> Start in client (transmitter) mode. Data will be sent to the multicast group. See L<"MODES">. -=item B<-d> IdirectoryE> +=item B<-s> + +Start in server (receiver) mode. Data sent to the multicast group will be read +and stored in RRD files. See L<"MODES">. + +=item B<-f> + +Don't fork to the background. I will also B close standard file +descriptors, detach from the session nor write a pid file. This is mainly +thought for 'supervisioning' init replacements such as I. + +=item B<-D> IdirectoryE> Sets the directory collectd should work in. All F<.rrd>-files are created in this directory. Per default this is F. -=item B<-P> IdirectoryE> +=item B<-M> IdirectoryE> Sets the directory collectd should look for plugins in. Per default this is F. -=item B<-f> +=item B<-P> IfileE> -Don't fork to the background. I will also B close standard file -descriptors, detach from the session nor write a pid file. This is mainly -thought for 'supervisioning' init replacements such as I. +Sets the PID-file. =item B<-h> Output usage information and exit. -=item B<-l> - -Start in local mode. This is the default. No data will be sent or read to/from -the network. Information will be read and written by the same process. See -L<"MODES">. - =item B<-p> IhostE> Sets the host to ping periodically. This option may be given more than once to ping multiple hosts. If this option is not given at least once no host will be pinged. -=item B<-s> - -Start in server (receiver) mode. Data sent to the multicast group will be read -and stored in RRD files. See L<"MODES">. - =back =head1 RRD FILES -- 2.11.0