diff options
author | sem <sem@FreeBSD.org> | 2005-03-05 01:47:19 +0800 |
---|---|---|
committer | sem <sem@FreeBSD.org> | 2005-03-05 01:47:19 +0800 |
commit | ba1cc50ea10162a705c4e64928772785ae2c33c1 (patch) | |
tree | cf8b0c9be2863ad75d6d0c19e14b6176689adefb /sysutils | |
parent | c2da15a63cde92de81dffaf594b0c80c6bd2e815 (diff) | |
download | freebsd-ports-gnome-ba1cc50ea10162a705c4e64928772785ae2c33c1.tar.gz freebsd-ports-gnome-ba1cc50ea10162a705c4e64928772785ae2c33c1.tar.zst freebsd-ports-gnome-ba1cc50ea10162a705c4e64928772785ae2c33c1.zip |
- Update tp 1.2.0
- Upgrade FreeBSD4 support to rcNG
- Use INSTALL_SCRIPT to install the start-stop script
- Correct rcNG version of pkg-message, adding PREFIX
- Use SUB_FILES and SUB_LIST
- Add log rotation support
PR: ports/77721
Submitted by: maintainer
Diffstat (limited to 'sysutils')
-rw-r--r-- | sysutils/munin-node/Makefile | 33 | ||||
-rw-r--r-- | sysutils/munin-node/distinfo | 4 | ||||
-rw-r--r-- | sysutils/munin-node/files/munin-node-revive.sh.in | 27 | ||||
-rw-r--r-- | sysutils/munin-node/files/munin-node.in (renamed from sysutils/munin-node/files/munin_node.sh) | 8 | ||||
-rw-r--r-- | sysutils/munin-node/files/munin-node.sh | 32 | ||||
-rw-r--r-- | sysutils/munin-node/files/munin-node.sh.in | 28 | ||||
-rw-r--r-- | sysutils/munin-node/files/patch-Makefile.config | 27 | ||||
-rw-r--r-- | sysutils/munin-node/files/patch-cpu.in | 15 | ||||
-rw-r--r-- | sysutils/munin-node/files/patch-vmstat.in | 29 | ||||
-rw-r--r-- | sysutils/munin-node/files/pkg-message.4 | 12 | ||||
-rw-r--r-- | sysutils/munin-node/files/pkg-message.in (renamed from sysutils/munin-node/files/pkg-message) | 7 | ||||
-rw-r--r-- | sysutils/munin-node/files/plugins.conf | 35 | ||||
-rw-r--r-- | sysutils/munin-node/pkg-deinstall | 53 | ||||
-rw-r--r-- | sysutils/munin-node/pkg-install | 47 | ||||
-rw-r--r-- | sysutils/munin-node/pkg-plist | 43 |
15 files changed, 250 insertions, 150 deletions
diff --git a/sysutils/munin-node/Makefile b/sysutils/munin-node/Makefile index 016835799bb0..3e404d1eb57e 100644 --- a/sysutils/munin-node/Makefile +++ b/sysutils/munin-node/Makefile @@ -6,12 +6,12 @@ # PORTNAME= munin -PORTVERSION= 1.0.4 +PORTVERSION= 1.2.0 CATEGORIES= sysutils perl5 MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= munin PKGNAMESUFFIX= -node -DISTNAME= ${PORTNAME}_${PORTVERSION:S/.p/pre/} +DISTNAME= ${PORTNAME}_${PORTVERSION:S/.r/rc/} MAINTAINER= lupe@lupe-christoph.de COMMENT= Node-specific part of Munin @@ -27,36 +27,31 @@ RUN_DEPENDS+= ${SITE_PERL}/Net/Domain.pm:${PORTSDIR}/net/p5-Net USE_GMAKE= yes PATCH_STRIP= -p1 -WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.p/pre/} +WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.r/rc/} PKGMESSAGE= ${WRKDIR}/pkg-message -ALL_TARGET= DATADIR=${DATADIR} build build-man -INSTALL_TARGET= DATADIR=${DATADIR} install-node install-node-plugins +ALL_TARGET= DATADIR=${DATADIR} PERL=${PERL} build build-man +INSTALL_TARGET= DATADIR=${DATADIR} PERL=${PERL} install-node install-node-plugins MAKE_ENV= LANG=C -NOPRECIOUSMAKEVARS=yes MAN5= munin-node.conf.5 MAN8= munin-node-configure.8 munin-node.8 munin-run.8 -.if ${OSVERSION} < 500000 -PKGMSG=${FILESDIR}/pkg-message.4 -STARTSTOP_SRC=${FILESDIR}/munin-node.sh -.else -PKGMSG=${FILESDIR}/pkg-message -STARTSTOP_SRC=${FILESDIR}/munin_node.sh -.endif -STARTSTOP_DST=${PREFIX}/etc/rc.d/munin-node.sh +SUB_FILES= pkg-message munin-node.sh munin-node-revive.sh +SUB_LIST= RC_SUBR=${RC_SUBR} +USE_RC_SUBR= YES pre-install: - @${SED} 's@%%PREFIX%%@${PREFIX}@g' ${PKGMSG} > ${PKGMESSAGE} @PKG_PREFIX=${PREFIX} ${SH} pkg-install ${PKGNAME} PRE-INSTALL post-install: - @${SED} 's@%PREFIX%@${PREFIX}@g' ${STARTSTOP_SRC} > ${STARTSTOP_DST} - @${CHMOD} +x ${STARTSTOP_DST} + ${INSTALL_SCRIPT} ${WRKDIR}/munin-node.sh ${PREFIX}/etc/rc.d/munin-node.sh +.if ${PERL_LEVEL} < 500800 + ${INSTALL_SCRIPT} ${WRKDIR}/munin-node-revive.sh ${PREFIX}/bin/munin-node-revive +.endif ${INSTALL_DATA} ${WRKSRC}/build/node/munin-node.conf ${PREFIX}/etc/munin/munin-node.conf.sample - ${INSTALL_DATA} ${WRKSRC}/plugins.conf ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample + ${INSTALL_DATA} files/plugins.conf ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample @if [ ! -f ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf ]; then \ - ${INSTALL_DATA} ${WRKSRC}/plugins.conf ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf; \ + ${INSTALL_DATA} ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf; \ fi @${CAT} ${PKGMESSAGE} @${INSTALL_MAN} -C ${WRKSRC}/build/doc/munin-node.conf.5 ${PREFIX}/man/man5 diff --git a/sysutils/munin-node/distinfo b/sysutils/munin-node/distinfo index 1db411157e37..e486eb6b0c23 100644 --- a/sysutils/munin-node/distinfo +++ b/sysutils/munin-node/distinfo @@ -1,2 +1,2 @@ -MD5 (munin_1.0.4.tar.gz) = 00721181e1ff81be85ad89307457d998 -SIZE (munin_1.0.4.tar.gz) = 214902 +MD5 (munin_1.2.0.tar.gz) = bbab7bf91ac837e4c72889aaef7cf2e8 +SIZE (munin_1.2.0.tar.gz) = 318364 diff --git a/sysutils/munin-node/files/munin-node-revive.sh.in b/sysutils/munin-node/files/munin-node-revive.sh.in new file mode 100644 index 000000000000..66bfa746a71d --- /dev/null +++ b/sysutils/munin-node/files/munin-node-revive.sh.in @@ -0,0 +1,27 @@ +#!/bin/sh + +# +# Add the following lines to /etc/rc.conf to enable munin-node: +# munin_node_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable munin-node +# munin_node_config (path): Set to "%%PREFIX%%/etc/munin/munin-node.conf" by default. +# + +. %%RC_SUBR%% + +name="munin_node" +rcvar=`set_rcvar` + +[ -z "$munin_node_enable" ] && munin_node_enable="NO" +[ -z "$munin_node_config" ] && munin_node_config="%%PREFIX%%/etc/munin/munin-node.conf" + +command="%%PREFIX%%/sbin/munin-node" +pidfile=`awk '$1 == "pid_file" { print $2 }' $munin_node_config` + +load_rc_config $name + +#set -x +pid=`check_pidfile $pidfile %%PREFIX%%/sbin/munin-node` +if [ -z "$pid" ]; then + run_rc_command start > /dev/null +fi diff --git a/sysutils/munin-node/files/munin_node.sh b/sysutils/munin-node/files/munin-node.in index 1a174ec64c14..b770f4a984ee 100644 --- a/sysutils/munin-node/files/munin_node.sh +++ b/sysutils/munin-node/files/munin-node.in @@ -10,18 +10,18 @@ # Add the following lines to /etc/rc.conf to enable munin-node: # munin_node_enable (bool): Set to "NO" by default. # Set it to "YES" to enable munin-node -# munin_node_config (path): Set to "%PREFIX%/etc/munin/munin-node.conf" by default. +# munin_node_config (path): Set to "%%PREFIX%%/etc/munin/munin-node.conf" by default. # -. /etc/rc.subr +. %%RC_SUBR%% name="munin_node" rcvar=`set_rcvar` [ -z "$munin_node_enable" ] && munin_node_enable="NO" -[ -z "$munin_node_config" ] && munin_node_config="/usr/local/etc/munin/munin-node.conf" +[ -z "$munin_node_config" ] && munin_node_config="%%PREFIX%%/etc/munin/munin-node.conf" -command="/usr/local/sbin/munin-node" +command="%%PREFIX%%/sbin/munin-node" pidfile=`awk '$1 == "pid_file" { print $2 }' $munin_node_config` load_rc_config $name diff --git a/sysutils/munin-node/files/munin-node.sh b/sysutils/munin-node/files/munin-node.sh deleted file mode 100644 index fb88e12f06aa..000000000000 --- a/sysutils/munin-node/files/munin-node.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -PROGRAM=%PREFIX%/sbin/munin-node -CONFIG=%PREFIX%/etc/munin/munin-node.conf - -case "$1" in - start) - if [ -x $PROGRAM -a -f $CONFIG -a -d $PLUGINS ]; then - $PROGRAM --config $CONFIG && echo -n ' munin-node' - fi - ;; - - stop) - if [ -f $CONFIG ]; then - PIDFILE=`awk '$1 == "pid_file" { print $2 }' $CONFIG` - if [ -f $PIDFILE ]; then - PID=`cat $PIDFILE` - CMD=`ps -xa -o command -p $PID | sed 1d` - case "$CMD" in - *munin-node*) - /bin/kill $PID && echo -n ' munin-node' - ;; - esac - fi - fi - ;; - - *) - echo "Usage: `basename $0` { start | stop }" - exit 64 - ;; -esac diff --git a/sysutils/munin-node/files/munin-node.sh.in b/sysutils/munin-node/files/munin-node.sh.in new file mode 100644 index 000000000000..b770f4a984ee --- /dev/null +++ b/sysutils/munin-node/files/munin-node.sh.in @@ -0,0 +1,28 @@ +#!/bin/sh +# + +# PROVIDE: munin-node +# REQUIRE: DAEMON +# BEFORE: cron +# KEYWORD: FreeBSD + +# +# Add the following lines to /etc/rc.conf to enable munin-node: +# munin_node_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable munin-node +# munin_node_config (path): Set to "%%PREFIX%%/etc/munin/munin-node.conf" by default. +# + +. %%RC_SUBR%% + +name="munin_node" +rcvar=`set_rcvar` + +[ -z "$munin_node_enable" ] && munin_node_enable="NO" +[ -z "$munin_node_config" ] && munin_node_config="%%PREFIX%%/etc/munin/munin-node.conf" + +command="%%PREFIX%%/sbin/munin-node" +pidfile=`awk '$1 == "pid_file" { print $2 }' $munin_node_config` + +load_rc_config $name +run_rc_command "$1" diff --git a/sysutils/munin-node/files/patch-Makefile.config b/sysutils/munin-node/files/patch-Makefile.config index 7e1b893d6f0f..98cba56f4e2a 100644 --- a/sysutils/munin-node/files/patch-Makefile.config +++ b/sysutils/munin-node/files/patch-Makefile.config @@ -1,6 +1,6 @@ ---- munin-1.0.0pre3.orig/Makefile.config Sun Feb 1 22:05:52 2004 -+++ munin-1.0.0pre3/Makefile.config Sat Feb 7 12:48:23 2004 -@@ -7,42 +7,46 @@ +--- munin-1.2.0rc2.orig/Makefile.config 2005-01-10 11:38:32.000000000 +0100 ++++ munin-1.2.0rc2/Makefile.config 2005-02-03 11:55:51.000000000 +0100 +@@ -7,52 +7,56 @@ # # the base of the Munin installation. # @@ -33,11 +33,13 @@ # Where to put internal binaries and plugin repository -LIBDIR = $(PREFIX)/lib -+LIBDIR = ${DATADIR} ++LIBDIR = $(DATADIR) # Server only - Output directory -HTMLDIR = $(PREFIX)/var/www +-CGIDIR = $(HTMLDIR)/cgi +HTMLDIR = $(PREFIX)/www/data/munin ++CGIDIR = $(PREFIX)/www/cgi-bin # Client only - Where to put RRD files and other intenal data -DBDIR = $(DESTDIR)/var/opt/munin @@ -57,9 +59,20 @@ +STATEDIR = /var/run/munin # The perl interpreter to use - PERL = $(shell which perl) -@@ -65,9 +69,8 @@ - GROUP = munin +-PERL = $(shell which perl) ++# Passed in from FreeBSD port Makefile. + + # The python interpreter to use (used by some plugins) + PYTHON = /usr/bin/env python + + # Server only - Where to install the perl libraries +-PERLLIB = $(DESTDIR)$(shell $(PERL) -V:sitelib | cut -d= -f2 | sed "s/[\';]//g") ++PERLLIB = $(shell $(PERL) -V:sitelib | cut -d= -f2 | sed "s/[\';]//g") + + # Client only - Install plugins for this architecture + OSTYPE = $(shell uname | tr '[A-Z]' '[a-z]') +@@ -72,9 +76,8 @@ + PLUGINUSER = nobody # Which command to use to check if the USER and GROUP to run Munin as, exists. -GETENT = $(shell which getent || which true 2>/dev/null) diff --git a/sysutils/munin-node/files/patch-cpu.in b/sysutils/munin-node/files/patch-cpu.in deleted file mode 100644 index 4dbe91a6bf79..000000000000 --- a/sysutils/munin-node/files/patch-cpu.in +++ /dev/null @@ -1,15 +0,0 @@ ---- munin-1.0.4.orig/node/node.d.freebsd/cpu.in Sun May 9 21:18:35 2004 -+++ munin-1.0.4/node/node.d.freebsd/cpu.in Sat Nov 20 15:32:50 2004 -@@ -59,10 +59,10 @@ - OSV=`/sbin/sysctl -n kern.osrelease | cut -f1 -d.` - if [ "$OSV" = "4" ]; then - STATUNITS=`/sbin/sysctl -n kern.clockrate | cut -f16 -d' '` -- elif [ "$OSV" = "5" ]; then -+ elif [ "$OSV" -ge "5" ]; then - STATUNITS=`/sbin/sysctl -n kern.clockrate | cut -f13 -d' '` - fi --# PERCENT=`/sbin/sysctl -n hw.ncpu | awk '{print ($1)*100}'` -+ PERCENT=`/sbin/sysctl -n hw.ncpu | awk '{print ($1)*100}'` - SCALE=`echo 'scale=5;' $PERCENT/$STATUNITS | bc -q ` - NCPU=`/sbin/sysctl -n hw.ncpu` - if [ "$scaleto100" = yes ]; then diff --git a/sysutils/munin-node/files/patch-vmstat.in b/sysutils/munin-node/files/patch-vmstat.in deleted file mode 100644 index 8aa3288e8b10..000000000000 --- a/sysutils/munin-node/files/patch-vmstat.in +++ /dev/null @@ -1,29 +0,0 @@ ---- munin-1.0.4.orig/node/node.d.freebsd/vmstat.in Sun Feb 1 19:59:54 2004 -+++ munin-1.0.4/node/node.d.freebsd/vmstat.in Sat Nov 20 14:14:54 2004 -@@ -32,7 +32,7 @@ - OSV=`/sbin/sysctl -n kern.osrelease | cut -f1 -d.` - - if [ "$1" = "autoconf" ]; then -- if [ "$OSV" = "5" ]; then -+ if [ "$OSV" -ge "5" ]; then - /sbin/sysctl -n vm.vmtotal 2>/dev/null >/dev/null - RESULT=$? - NAME=/sbin/sysctl -@@ -59,7 +59,7 @@ - echo 'graph_title VMstat' - echo 'graph_args --base 1000 -l 0' - echo 'graph_vlabel process states' -- if [ "$OSV" = "5" ]; then -+ if [ "$OSV" -ge "5" ]; then - echo 'running.label running' - echo 'running.type GAUGE' - echo 'diskwait.label diskwait' -@@ -77,7 +77,7 @@ - exit 0 - fi - --if [ "$OSV" = "5" ]; then -+if [ "$OSV" -ge "5" ]; then - sysctl -n vm.vmtotal | awk ' - /^Processes:/ { - print "running.value", $3; diff --git a/sysutils/munin-node/files/pkg-message.4 b/sysutils/munin-node/files/pkg-message.4 deleted file mode 100644 index 206a44057599..000000000000 --- a/sysutils/munin-node/files/pkg-message.4 +++ /dev/null @@ -1,12 +0,0 @@ - -******************************************************************** -Unless this file already existed, a sample configuration file -has been placed in %%PREFIX%%/etc/munin/munin-node.conf. - -Please edit it according to your needs. - -The Munin client will be started at system boot automatically. -You can start it manually with: - %%PREFIX%%/etc/rc.d/munin-node.sh start -******************************************************************** - diff --git a/sysutils/munin-node/files/pkg-message b/sysutils/munin-node/files/pkg-message.in index 96d07954fde4..965c716ba8b5 100644 --- a/sysutils/munin-node/files/pkg-message +++ b/sysutils/munin-node/files/pkg-message.in @@ -12,9 +12,10 @@ to start, put this line in /etc/rc.conf: munin_node_enable="YES" -Then, it will be started on the next boot. To start it now, use -this command: +Then, it will be started on the next boot. If this line is already +present, the client will be started now. Otherwise, edit +/etc/rc.conf and execute this command: - /etc/rc.d/munin_node start + %%PREFIX%%/etc/rc.d/munin-node.sh start ******************************************************************** diff --git a/sysutils/munin-node/files/plugins.conf b/sysutils/munin-node/files/plugins.conf new file mode 100644 index 000000000000..dd4025afbd9d --- /dev/null +++ b/sysutils/munin-node/files/plugins.conf @@ -0,0 +1,35 @@ +# +# This file contains configuration options for the plugins. Three +# options are understood by munin-node itself: +# +# user <user> # Set the user to run the plugin as +# group <group> # Set the group to run the plugin as +# command <command> # Run <command> instead of the plugin. %c +# expands to what would normally be run. +# env.<variable> # Sets <variable> in the plugin's environment, see the +# individual plugins to find out which variables they +# care about. +# +# + +[mysql*] +#env.mysqlopts -u someuser + +[exim*] +group mail + +[cps*] +user root + +[apt] +user root + +[vlan*] +user root + +[postfix*] +user root +env.logfile maillog + +[sendmail*] +env.mspqueue /var/spool/clientmqueue diff --git a/sysutils/munin-node/pkg-deinstall b/sysutils/munin-node/pkg-deinstall index 54e8e509cd30..3bf91c5a0e5b 100644 --- a/sysutils/munin-node/pkg-deinstall +++ b/sysutils/munin-node/pkg-deinstall @@ -1,13 +1,4 @@ #! /bin/sh -# -# $Log: pkg-deinstall,v $ -# Revision 1.2.2.1 2004/11/21 10:52:27 lupe -# make stop_process use old or new start-stop script. -# -# Revision 1.2 2004/02/06 18:49:58 lupe -# Fixes for pkg_add compatibility. -# -# ask() { local question default answer @@ -39,6 +30,8 @@ yesno() { } stop_process() { + STARTSTOP=${PKG_PREFIX}/etc/rc.d/munin-node.sh + if [ -x $STARTSTOP ]; then $STARTSTOP stop fi @@ -54,17 +47,45 @@ delete_group() { fi } -OSVERSION=`/sbin/sysctl -n kern.osreldate` -if [ $OSVERSION -lt 500000 ]; then - STARTSTOP=${PKG_PREFIX}/etc/rc.d/munin-node.sh -else - STARTSTOP=/etc/rc.d/munin_node -fi +delete_crontab_entries() { + local prog + prog=$1 + + if grep -q "^[^#]*$prog" /etc/crontab; then + TMPFILE=`mktemp -t munin` || exit 1 + grep -v $prog /etc/crontab > $TMPFILE + cat $TMPFILE > /etc/crontab + rm $/etc/crontab + fi +} + +delnewsyslog() { + tmp="/etc/#munin-node$$" + sed -e '/^\/var\/log\/munin-node.log[ ]/d' /etc/newsyslog.conf >${tmp} + cat ${tmp} > /etc/newsyslog.conf + rm ${tmp} +} + +newsyslog() { + ENTRY=`grep /var/log/munin-node.log /etc/newsyslog.conf` + DEFAULT='/var/log/munin-node.log 644 7 * @T00 Z /var/run/munin/munin-node.pid' + if [ -z "$ENTRY" ]; then + exit 0 + elif [ "$ENTRY" = "$DEFAULT" ]; then + delnewsyslog + elif yesno "You have changed the default munin-node entry in \"/etc/newsyslog.conf\". +Do you want me to delete it?" y; then + delnewsyslog + echo "Done." + fi +} + case $2 in DEINSTALL) + delete_crontab_entries ${PKG_PREFIX}/bin/munin-node-revive stop_process - exit 0 # ignore error + newsyslog ;; POST-DEINSTALL) delete_group munin diff --git a/sysutils/munin-node/pkg-install b/sysutils/munin-node/pkg-install index 09c169bf6b14..95d53640dba0 100644 --- a/sysutils/munin-node/pkg-install +++ b/sysutils/munin-node/pkg-install @@ -1,10 +1,4 @@ #! /bin/sh -# -# $Log: pkg-install,v $ -# Revision 1.2 2004/02/06 18:49:58 lupe -# Fixes for pkg_add compatibility. -# -# ask() { local question default answer @@ -63,8 +57,6 @@ init_plugins() { prevver=$(cat ${PKG_PREFIX}/etc/munin/VERSION.node) fi - mkdir -p ${PKG_PREFIX}/etc/munin/plugins ${PKG_PREFIX}/var/munin/plugin-state - if [ -n "$prevver" ]; then echo -n "Initializing new plugins.." ${PKG_PREFIX}/sbin/munin-node-configure --shell --newer "${prevver%-*}" | sh -x @@ -75,6 +67,43 @@ init_plugins() { echo "done." } +create_crontab_entries() { + local sched prog + sched=$1 + prog=$2 + + if grep -q "^[^#]*$prog" /etc/crontab; then + echo "It looks like your crontab is already set up, so I'll use that." + else + echo "It looks like your perl suffers from unsafe signals." + if yesno "Would you like me to set up your root crontab to restart munin-node" y; then + cat <<EOT >>/etc/crontab +$sched root $prog +EOT + else + echo "You may suffer from munin-node crashing after log rotation." + echo "If you still want to restart munin-node, use $prog." + fi + fi +} + +newsyslog() { + if yesno "Would you like me to set up log rotation" y; then + if grep -q /var/log/munin-node.log /etc/newsyslog.conf; then + : + else + cat >> /etc/newsyslog.conf <<EOT +/var/log/munin-node.log 644 7 * @T00 Z /var/run/munin/munin-node.pid +EOT + fi + if [ -f ${PKG_PREFIX}/bin/munin-node-revive ]; then + create_crontab_entries '4 * * * *' ${PKG_PREFIX}/bin/munin-node-revive + fi + else + echo "/var/log/munin-node.log will grow without bounds." + fi +} + ######################################################################## @@ -84,5 +113,7 @@ case $2 in ;; POST-INSTALL) init_plugins + ${PKG_PREFIX}/etc/rc.d/munin-node.sh start + newsyslog ;; esac diff --git a/sysutils/munin-node/pkg-plist b/sysutils/munin-node/pkg-plist index 295efbf665e2..7a12a8c6b838 100644 --- a/sysutils/munin-node/pkg-plist +++ b/sysutils/munin-node/pkg-plist @@ -1,12 +1,16 @@ +@exec mkdir -p %D/etc/munin/plugins +@exec mkdir -p %D/etc/munin/plugin-conf.d && chmod 755 %D/etc/munin/plugin-conf.d +@exec mkdir -p %D/var/munin/plugin-state && chgrp munin %D/var/munin/plugin-state && chmod 775 %D/var/munin/plugin-state +@unexec rm %D/bin/munin-node-revive 2>/dev/null || true @comment etc/munin/VERSION.node must remain for upgrade version check @unexec if cmp -s %D/etc/munin/munin-node.conf %D/etc/munin/munin-node.conf.sample; then rm -f %D/etc/munin/munin-node.conf; fi etc/munin/munin-node.conf.sample @unexec if cmp -s %D/etc/munin/plugin-conf.d/plugins.conf %D/etc/munin/plugin-conf.d/plugins.conf.sample; then rm -f %D/etc/munin/plugin-conf.d/plugins.conf; fi etc/munin/plugin-conf.d/plugins.conf.sample @unexec rm %D/etc/rc.d/munin-node.sh 2>/dev/null || true -@unexec rm /etc/rc.d/munin_node 2>/dev/null || true sbin/munin-node sbin/munin-node-configure +sbin/munin-node-configure-snmp sbin/munin-run %%DATADIR%%/plugins/acpi %%DATADIR%%/plugins/amavis @@ -14,22 +18,38 @@ sbin/munin-run %%DATADIR%%/plugins/apache_processes %%DATADIR%%/plugins/apache_volume %%DATADIR%%/plugins/apc_envunit_ +%%DATADIR%%/plugins/apc_nis %%DATADIR%%/plugins/bind9 +%%DATADIR%%/plugins/bind9_rndc +%%DATADIR%%/plugins/courier_ +%%DATADIR%%/plugins/courier_mta_mailqueue +%%DATADIR%%/plugins/courier_mta_mailstats +%%DATADIR%%/plugins/courier_mta_mailvolume %%DATADIR%%/plugins/cpu +%%DATADIR%%/plugins/cupsys_pages %%DATADIR%%/plugins/df %%DATADIR%%/plugins/df_inode +%%DATADIR%%/plugins/dhcpd3 %%DATADIR%%/plugins/exim_mailqueue +%%DATADIR%%/plugins/exim_mailqueue_alt %%DATADIR%%/plugins/exim_mailstats -%%DATADIR%%/plugins/folding@home +%%DATADIR%%/plugins/foldingathome +%%DATADIR%%/plugins/foldingathome_rank +%%DATADIR%%/plugins/foldingathome_wu %%DATADIR%%/plugins/hddtemp %%DATADIR%%/plugins/hddtemp2 +%%DATADIR%%/plugins/hddtemp_smartctl +%%DATADIR%%/plugins/hddtempd %%DATADIR%%/plugins/if_ %%DATADIR%%/plugins/if_errcoll_ %%DATADIR%%/plugins/ipac-ng %%DATADIR%%/plugins/ircu %%DATADIR%%/plugins/load +%%DATADIR%%/plugins/loggrep %%DATADIR%%/plugins/mailman +%%DATADIR%%/plugins/mailscanner %%DATADIR%%/plugins/memory +%%DATADIR%%/plugins/mhttping %%DATADIR%%/plugins/multips %%DATADIR%%/plugins/munin_graph %%DATADIR%%/plugins/munin_update @@ -40,9 +60,15 @@ sbin/munin-run %%DATADIR%%/plugins/mysql_threads %%DATADIR%%/plugins/named %%DATADIR%%/plugins/netstat +%%DATADIR%%/plugins/ntp_ +%%DATADIR%%/plugins/ntp_states +%%DATADIR%%/plugins/nut_misc +%%DATADIR%%/plugins/nut_volts %%DATADIR%%/plugins/open_files +%%DATADIR%%/plugins/perdition +%%DATADIR%%/plugins/ping_ %%DATADIR%%/plugins/plugins.history -%%DATADIR%%/plugins/pm3users +%%DATADIR%%/plugins/pm3users_ %%DATADIR%%/plugins/pop_stats %%DATADIR%%/plugins/postfix_mailqueue %%DATADIR%%/plugins/postfix_mailstats @@ -54,6 +80,7 @@ sbin/munin-run %%DATADIR%%/plugins/sendmail_mailqueue %%DATADIR%%/plugins/sendmail_mailstats %%DATADIR%%/plugins/sendmail_mailtraffic +%%DATADIR%%/plugins/smart_ %%DATADIR%%/plugins/snmp__df %%DATADIR%%/plugins/snmp__fc_if_ %%DATADIR%%/plugins/snmp__fc_if_err_ @@ -61,6 +88,13 @@ sbin/munin-run %%DATADIR%%/plugins/snmp__if_err_ %%DATADIR%%/plugins/snmp__load %%DATADIR%%/plugins/snmp__processes +%%DATADIR%%/plugins/snmp__sensors_fsc_bx_fan +%%DATADIR%%/plugins/snmp__sensors_fsc_bx_temp +%%DATADIR%%/plugins/snmp__sensors_fsc_fan +%%DATADIR%%/plugins/snmp__sensors_fsc_temp +%%DATADIR%%/plugins/snmp__sensors_mbm_fan +%%DATADIR%%/plugins/snmp__sensors_mbm_temp +%%DATADIR%%/plugins/snmp__sensors_mbm_volt %%DATADIR%%/plugins/snmp__users %%DATADIR%%/plugins/spamstats %%DATADIR%%/plugins/squid_cache @@ -71,8 +105,11 @@ sbin/munin-run %%DATADIR%%/plugins/swap %%DATADIR%%/plugins/sybase_space %%DATADIR%%/plugins/vmstat +@unexec rm -f /var/run/munin/munin-node.pid +@unexec rmdir /var/run/munin 2>/dev/null || true @unexec rmdir %D/var/munin/plugin-state 2>/dev/null || true @unexec rmdir %D/var/munin 2>/dev/null || true +@unexec rmdir %D/%%DATADIR%%/plugins 2>/dev/null || true @unexec rmdir %D/%%DATADIR%% 2>/dev/null || true @unexec rmdir %D/etc/munin/plugin-conf.d 2>/dev/null || true @unexec rmdir %D/etc/munin 2>/dev/null || true |