mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
Upgrade Munin to 1.4.3. Thanks to Sean Rees <sean@rees.us> for providing
the initial patches and getting me started with this. Note that munin-main has been renamed to munin-master (see MOVED). Approved by: portmgr (erwin) Feature safe: yes
This commit is contained in:
parent
57a370406d
commit
6f830b33ee
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=250230
32 changed files with 503 additions and 632 deletions
1
MOVED
1
MOVED
|
@ -4324,3 +4324,4 @@ sysutils/smartmontools-devel|sysutils/smartmontools|2010-02-10|Removed, use sysu
|
|||
ports-mgmt/portbrowser||2010-02-16|No longer maintained
|
||||
editors/openoffice.org-2-RC||2010-02-19|Removed
|
||||
net-p2p/rblibtorrent-devel|net-p2p/libtorrent-rasterbar-14|2010-02-21|No longer devel, recognize project name
|
||||
sysutils/munin-main|sysutils/munin-master|2010-02-22|Reorganized upstream
|
||||
|
|
|
@ -501,7 +501,8 @@
|
|||
SUBDIR += mtpfs
|
||||
SUBDIR += mtxorbd
|
||||
SUBDIR += multitail
|
||||
SUBDIR += munin-main
|
||||
SUBDIR += munin-common
|
||||
SUBDIR += munin-master
|
||||
SUBDIR += munin-node
|
||||
SUBDIR += muse
|
||||
SUBDIR += mybashburn
|
||||
|
|
46
sysutils/munin-common/Makefile
Normal file
46
sysutils/munin-common/Makefile
Normal file
|
@ -0,0 +1,46 @@
|
|||
# New ports collection makefile for: munin-common
|
||||
# Date created: 10 February 2010
|
||||
# Whom: Sean Rees <sean@rees.us>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= munin
|
||||
PORTVERSION= 1.4.3
|
||||
CATEGORIES= sysutils perl5
|
||||
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20stable/${PORTVERSION}
|
||||
PKGNAMESUFFIX= -common
|
||||
|
||||
MAINTAINER= des@FreeBSD.org
|
||||
COMMENT= Common components between a munin node and server
|
||||
|
||||
BUILD_DEPENDS= ${SITE_PERL}/Module/Build.pm:${PORTSDIR}/devel/p5-Module-Build \
|
||||
${SITE_PERL}/${PERL_ARCH}/Net/SSLeay.pm:${PORTSDIR}/security/p5-Net-SSLeay
|
||||
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/Net/SSLeay.pm:${PORTSDIR}/security/p5-Net-SSLeay
|
||||
|
||||
USE_PERL5= yes
|
||||
USE_GMAKE= yes
|
||||
PATCH_STRIP= -p1
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.r/rc/}
|
||||
PKGMESSAGE= ${WRKDIR}/pkg-message
|
||||
|
||||
MAKE_ARGS= LIBDIR=${DATADIR} CONFDIR=${ETCDIR} \
|
||||
PERL=${PERL} SITE_PERL_REL=${SITE_PERL_REL}
|
||||
ALL_TARGET= build-common-prime
|
||||
INSTALL_TARGET= install-common
|
||||
|
||||
MAN3= Munin::Common::Config.3 \
|
||||
Munin::Common::Defaults.3 \
|
||||
Munin::Common::TLS.3 \
|
||||
Munin::Common::TLSClient.3 \
|
||||
Munin::Common::TLSServer.3 \
|
||||
Munin::Common::Timeout.3
|
||||
|
||||
SUB_FILES= pkg-message
|
||||
|
||||
post-install:
|
||||
@(cd ${WRKSRC}/common/blib/libdoc && for man in ${MAN3} ; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man3; \
|
||||
done)
|
||||
|
||||
.include <bsd.port.mk>
|
3
sysutils/munin-common/distinfo
Normal file
3
sysutils/munin-common/distinfo
Normal file
|
@ -0,0 +1,3 @@
|
|||
MD5 (munin-1.4.3.tar.gz) = 229646facc4e2bca6511b20b3e5eb73f
|
||||
SHA256 (munin-1.4.3.tar.gz) = c5f1c8e5e71e9ffd5c74037ec3eec4da362fd2aecea3c788abb7d92b461834d0
|
||||
SIZE (munin-1.4.3.tar.gz) = 1205698
|
11
sysutils/munin-common/files/patch-Makefile
Normal file
11
sysutils/munin-common/files/patch-Makefile
Normal file
|
@ -0,0 +1,11 @@
|
|||
--- Makefile.orig 2010-01-30 10:49:44.000000000 -0700
|
||||
+++ Makefile 2010-01-30 10:49:53.000000000 -0700
|
||||
@@ -69,7 +69,7 @@
|
||||
mkdir -p $(LOGDIR)
|
||||
mkdir -p $(STATEDIR)
|
||||
mkdir -p $(CONFDIR)
|
||||
- $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR)
|
||||
+ $(CHOWN) $(USER) $(STATEDIR)
|
||||
|
||||
install-master-prime: $(INFILES_MASTER) install-pre install-master
|
||||
mkdir -p $(CONFDIR)/templates
|
|
@ -1,6 +1,6 @@
|
|||
--- Makefile.config.orig 2008-01-20 20:32:46.000000000 +0100
|
||||
+++ Makefile.config 2008-08-09 15:44:18.000000000 +0200
|
||||
@@ -7,46 +7,50 @@
|
||||
--- Makefile.config.orig 2009-12-30 05:55:56.000000000 -0700
|
||||
+++ Makefile.config 2010-01-30 11:17:34.000000000 -0700
|
||||
@@ -17,29 +17,33 @@
|
||||
#
|
||||
# the base of the Munin installation.
|
||||
#
|
||||
|
@ -36,11 +36,16 @@
|
|||
+LIBDIR = $(DATADIR)
|
||||
|
||||
# Server only - Output directory
|
||||
-HTMLDIR = $(PREFIX)/var/www
|
||||
-CGIDIR = $(HTMLDIR)/cgi
|
||||
-HTMLDIR = $(PREFIX)/www/docs
|
||||
-CGIDIR = $(PREFIX)/www/cgi
|
||||
+HTMLDIR = $(WWWDIR)
|
||||
+CGIDIR = $(PREFIX)/www/cgi-bin
|
||||
|
||||
# Server only - spool directory for data gathered from nodes by
|
||||
# munin-gather - experimental. Place on ramdisk to make munin
|
||||
@@ -52,21 +56,20 @@
|
||||
# SSPOOLDIR := /tmp/muninspool
|
||||
|
||||
# Client only - Where to put RRD files and other intenal data
|
||||
-DBDIR = $(DESTDIR)/var/opt/munin
|
||||
+DBDIR = $(PREFIX)/var/munin
|
||||
|
@ -50,7 +55,7 @@
|
|||
PLUGSTATE = $(DBDIR)/plugin-state
|
||||
|
||||
# Where Munin should place its logs.
|
||||
-LOGDIR = $(DESTDIR)/var/log/munin
|
||||
-LOGDIR = $(PREFIX)/log/munin
|
||||
+LOGDIR = /var/log/munin-main
|
||||
|
||||
# Location of PID files and other statefiles. On the server, must be
|
||||
|
@ -59,33 +64,33 @@
|
|||
+STATEDIR = /var/run/munin
|
||||
|
||||
# The perl interpreter to use
|
||||
-PERL = $(shell which perl)
|
||||
+# Passed in from FreeBSD port Makefile.
|
||||
-PERL := $(shell which perl)
|
||||
|
||||
# The python interpreter to use (used by some plugins)
|
||||
PYTHON = /usr/bin/env python
|
||||
@@ -62,10 +66,10 @@
|
||||
GOODSH = $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
PYTHON := /usr/bin/env python
|
||||
@@ -95,11 +98,11 @@
|
||||
GOODSH := $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
|
||||
# Path of bash for bash specific plugins
|
||||
-BASH = /bin/bash
|
||||
+BASH = /usr/local/bin/bash
|
||||
-BASH := /bin/bash
|
||||
+BASH := /usr/local/bin/bash
|
||||
|
||||
# Server only - Where to install the perl libraries
|
||||
-PERLLIB = $(DESTDIR)$(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
PERLSITELIB := $(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
-PERLLIB = $(DESTDIR)$(PERLSITELIB)
|
||||
+PERLLIB = $(PREFIX)/$(SITE_PERL_REL)
|
||||
|
||||
# Client only - Install plugins for this architecture
|
||||
OSTYPE = $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -90,9 +94,8 @@
|
||||
PLUGINUSER = nobody
|
||||
|
||||
OSTYPE := $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -126,9 +129,8 @@
|
||||
# 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)
|
||||
-CHECKUSER = $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP = $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
# These will work on most modern OSes:
|
||||
#
|
||||
-GETENT := $(shell which getent || which true 2>/dev/null)
|
||||
-CHECKUSER := $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistent. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP := $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistent. Create the group and retry; exit 2"))
|
||||
+CHECKUSER:= $(shell /usr/sbin/pw user show $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
+CHECKGROUP:= $(shell /usr/sbin/pw group show $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
|
||||
# For OSX, comment out the previous two lines and comment in these
|
||||
#CHECKUSER = $(shell nicl . -read /users/$(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
#
|
|
@ -8,7 +8,7 @@ intervals, and asks them for data. It then stores the data in RRD-files,
|
|||
and (if needed) updates the graphs. One of the main goals have been ease
|
||||
of creating own "plugins" (graphs).
|
||||
|
||||
This is the collector. It is installed on the machine that shall collect
|
||||
and display performance data.
|
||||
This are the common components to drive both the server and the node components
|
||||
of munin.
|
||||
|
||||
WWW: http://www.linpro.no/projects/munin/
|
8
sysutils/munin-common/pkg-plist
Normal file
8
sysutils/munin-common/pkg-plist
Normal file
|
@ -0,0 +1,8 @@
|
|||
%%SITE_PERL%%/Munin/Common/Config.pm
|
||||
%%SITE_PERL%%/Munin/Common/Defaults.pm
|
||||
%%SITE_PERL%%/Munin/Common/TLS.pm
|
||||
%%SITE_PERL%%/Munin/Common/TLSClient.pm
|
||||
%%SITE_PERL%%/Munin/Common/TLSServer.pm
|
||||
%%SITE_PERL%%/Munin/Common/Timeout.pm
|
||||
@dirrm %%SITE_PERL%%/Munin/Common
|
||||
@dirrm %%SITE_PERL%%/Munin
|
|
@ -1,54 +0,0 @@
|
|||
# New ports collection makefile for: munin-main
|
||||
# Date created: 25 Januar 2004
|
||||
# Whom: Lupe Christoph <lupe@lupe-christoph.de>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= munin
|
||||
PORTVERSION= 1.2.6
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= sysutils perl5
|
||||
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20stable/${PORTVERSION}
|
||||
PKGNAMESUFFIX= -main
|
||||
DISTNAME= ${PORTNAME}_${PORTVERSION:S/.r/rc/}
|
||||
|
||||
MAINTAINER= des@FreeBSD.org
|
||||
COMMENT= Collector part of Munin
|
||||
|
||||
USE_PERL5= yes
|
||||
|
||||
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/RRDs.pm:${PORTSDIR}/databases/rrdtool \
|
||||
${SITE_PERL}/HTML/Template.pm:${PORTSDIR}/www/p5-HTML-Template \
|
||||
${SITE_PERL}/Date/Manip.pm:${PORTSDIR}/devel/p5-Date-Manip
|
||||
BUILD_DEPENDS= ${RUN_DEPENDS}
|
||||
|
||||
USE_GMAKE= yes
|
||||
PATCH_STRIP= -p1
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.r/rc/}
|
||||
PKGMESSAGE= ${WRKDIR}/pkg-message
|
||||
ALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} build build-man
|
||||
INSTALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} SITE_PERL_REL=$(SITE_PERL_REL) install-main
|
||||
|
||||
MAN5= munin.conf.5
|
||||
MAN8= munin-cron.8 munin-graph.8 munin-html.8 munin-limits.8 munin-update.8
|
||||
|
||||
SUB_FILES=pkg-message
|
||||
|
||||
pre-install:
|
||||
@PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/pkg-install ${PKGNAME} PRE-INSTALL
|
||||
|
||||
post-install:
|
||||
@${INSTALL_DATA} ${WRKSRC}/build/server/munin.conf ${PREFIX}/etc/munin/munin.conf.sample
|
||||
@for man in ${MAN5}; do \
|
||||
${INSTALL_MAN} -C ${WRKSRC}/build/doc/$$man ${PREFIX}/man/man5; \
|
||||
done
|
||||
@for man in ${MAN8}; do \
|
||||
${INSTALL_MAN} -C ${WRKSRC}/build/doc/$$man ${PREFIX}/man/man8; \
|
||||
done
|
||||
@DATADIR=${DATADIR} PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/pkg-install ${PKGNAME} POST-INSTALL
|
||||
@${CHOWN} munin /var/log/munin-main
|
||||
@${CHGRP} munin /var/run/munin /var/log/munin-main ${WWWDIR} ${PREFIX}/var/munin
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.mk>
|
|
@ -1,3 +0,0 @@
|
|||
MD5 (munin_1.2.6.tar.gz) = 45f84d58f80642ce914f147232f0d396
|
||||
SHA256 (munin_1.2.6.tar.gz) = 3b04d72810317a91225c78652277079ec3cc5791ef8991326da219a05d2477d8
|
||||
SIZE (munin_1.2.6.tar.gz) = 360694
|
|
@ -1,11 +0,0 @@
|
|||
--- Makefile.orig Tue May 11 22:23:06 2004
|
||||
+++ Makefile Fri Jun 4 00:25:54 2004
|
||||
@@ -26,7 +26,7 @@
|
||||
mkdir -p $(HTMLDIR)
|
||||
mkdir -p $(DBDIR)
|
||||
|
||||
- $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR) $(RUNDIR) $(HTMLDIR) $(DBDIR)
|
||||
+ $(CHOWN) $(USER) $(STATEDIR) $(RUNDIR) $(HTMLDIR) $(DBDIR)
|
||||
|
||||
for p in server/*.tmpl; do \
|
||||
$(INSTALL) -m 0644 "$$p" $(CONFDIR)/templates/ ; \
|
|
@ -1,118 +0,0 @@
|
|||
#! /bin/sh
|
||||
|
||||
ask() {
|
||||
local question default answer
|
||||
|
||||
question=$1
|
||||
default=$2
|
||||
if [ -z "${PACKAGE_BUILDING}" -a -z "${BATCH}" ]; then
|
||||
read -p "${question} [${default}]? " answer
|
||||
fi
|
||||
if [ x${answer} = x ]; then
|
||||
answer=${default}
|
||||
fi
|
||||
echo ${answer}
|
||||
}
|
||||
|
||||
yesno() {
|
||||
local dflt question answer
|
||||
|
||||
question=$1
|
||||
dflt=$2
|
||||
while :; do
|
||||
answer=$(ask "${question}" "${dflt}")
|
||||
case "${answer}" in
|
||||
[Yy]*) return 0;;
|
||||
[Nn]*) return 1;;
|
||||
esac
|
||||
echo "Please answer yes or no."
|
||||
done
|
||||
}
|
||||
|
||||
delete_account() {
|
||||
local u g home
|
||||
|
||||
u=$1
|
||||
g=$2
|
||||
if pw group show ${g} > /dev/null 2>&1; then
|
||||
if yesno "Do you want me to remove group \"${g}\"" y; then
|
||||
pw group del -n ${g}
|
||||
echo "Done."
|
||||
else
|
||||
GID=`pw group show ${g} | awk -F: '{ print $3 }'`
|
||||
fi
|
||||
fi
|
||||
if pw user show ${u} > /dev/null 2>&1; then
|
||||
if yesno "Do you want me to remove user \"${u}\"" y; then
|
||||
eval home=~${u}
|
||||
pw user del -n ${u} -r
|
||||
echo "Done."
|
||||
if [ -d "${home}" ]; then
|
||||
echo "Please remember to remove the home directory \"${home}\""
|
||||
fi
|
||||
|
||||
# pw user del may have removed the group, too.
|
||||
# Put it back if the admin asked us to retain it.
|
||||
if [ -n "$GID" ]; then
|
||||
pw group show ${g} > /dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
pw group add ${g}
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
delete_crontab_entries() {
|
||||
local b e
|
||||
b=$1
|
||||
e=$2
|
||||
|
||||
TMPFILE=`mktemp -t munin` || exit 1
|
||||
crontab -u munin -l | sed -e "/^$b\$/,/^$e\$/d" -e '/^[ ]*#/d' -e '/^$/d' > $TMPFILE
|
||||
if [ -s $TMPFILE ]; then
|
||||
crontab -u munin -l | sed -e "/^$b\$/,/^$e\$/d" | crontab -u munin -
|
||||
echo "The crontab for user munin had manually created entries."
|
||||
echo "Only the automatically created entries have been removed."
|
||||
echo "These are the remaining lines:"
|
||||
crontab -u munin -l
|
||||
else
|
||||
echo y | crontab -u munin -r
|
||||
echo "crontab for user munin removed"
|
||||
fi
|
||||
rm $TMPFILE
|
||||
}
|
||||
|
||||
delnewsyslog() {
|
||||
tmp="/etc/#munin-node$$"
|
||||
sed -e '/^\/var\/log\/munin-main\/\*\.log[ ]/d' /etc/newsyslog.conf >${tmp}
|
||||
cat ${tmp} > /etc/newsyslog.conf
|
||||
rm ${tmp}
|
||||
}
|
||||
|
||||
newsyslog() {
|
||||
ENTRY=`fgrep '/var/log/munin-main/*' /etc/newsyslog.conf`
|
||||
DEFAULT='/var/log/munin-main/*.log munin:munin 644 7 * @T00 GNWZ'
|
||||
if [ -z "$ENTRY" ]; then
|
||||
exit 0
|
||||
elif [ "$ENTRY" = "$DEFAULT" ]; then
|
||||
delnewsyslog
|
||||
elif yesno "You have changed the default munin-main entry in \"/etc/newsyslog.conf\".
|
||||
Do you want me to delete it?" y; then
|
||||
delnewsyslog
|
||||
echo "Done."
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
case $2 in
|
||||
DEINSTALL)
|
||||
if [ -z "${PACKAGE_BUILDING}" ]; then
|
||||
delete_crontab_entries '#BEGIN_MUNIN_MAIN' '#END_MUNIN_MAIN'
|
||||
newsyslog
|
||||
fi
|
||||
;;
|
||||
POST-DEINSTALL)
|
||||
delete_account munin munin
|
||||
;;
|
||||
esac
|
|
@ -1,127 +0,0 @@
|
|||
#! /bin/sh
|
||||
|
||||
ask() {
|
||||
local question default answer
|
||||
|
||||
question=$1
|
||||
default=$2
|
||||
if [ -z "${PACKAGE_BUILDING}" -a -z "${BATCH}" ]; then
|
||||
read -p "${question} [${default}]? " answer
|
||||
fi
|
||||
if [ x${answer} = x ]; then
|
||||
answer=${default}
|
||||
fi
|
||||
echo ${answer}
|
||||
}
|
||||
|
||||
yesno() {
|
||||
local dflt question answer
|
||||
|
||||
question=$1
|
||||
dflt=$2
|
||||
while :; do
|
||||
answer=$(ask "${question}" "${dflt}")
|
||||
case "${answer}" in
|
||||
[Yy]*) return 0;;
|
||||
[Nn]*) return 1;;
|
||||
esac
|
||||
echo "Please answer yes or no."
|
||||
done
|
||||
}
|
||||
|
||||
make_account() {
|
||||
local u g gcos
|
||||
|
||||
u=$1
|
||||
g=$2
|
||||
gcos=$3
|
||||
|
||||
if pw group show "${g}" >/dev/null 2>&1; then
|
||||
echo "You already have a group \"${g}\", so I will use it."
|
||||
else
|
||||
echo "You need a group \"${g}\"."
|
||||
if which -s pw && yesno "Would you like me to create it" y; then
|
||||
pw groupadd ${g} || exit
|
||||
echo "Done."
|
||||
else
|
||||
echo "Please create it, and try again."
|
||||
if ! /usr/sbin/pw user show ${u} >/dev/null 2>/dev/null; then
|
||||
echo "While you're at it, please create a user \"${u}\" too,"
|
||||
echo "with a default group of \"${g}\"."
|
||||
fi
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
if pw user show "${u}" >/dev/null 2>&1; then
|
||||
echo "You already have a user \"${u}\", so I will use it."
|
||||
else
|
||||
echo "You need a user \"${u}\"."
|
||||
if which -s pw && yesno "Would you like me to create it" y; then
|
||||
pw useradd ${u} -g ${g} -h - \
|
||||
-s /bin/sh -c "${gcos}" || exit
|
||||
echo "Done."
|
||||
else
|
||||
echo "Please create it, and try again."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
create_crontab_entries() {
|
||||
local b e
|
||||
b=$1
|
||||
e=$2
|
||||
|
||||
if crontab -u munin -l > /dev/null 2>&1; then
|
||||
TMPFILE=`mktemp -t munin` || exit 1
|
||||
cat > $TMPFILE
|
||||
crontab -u munin -l | sed -e "/^$b$/,/^$e$/d" | \
|
||||
cat - $TMPFILE | crontab -u munin -
|
||||
rm $TMPFILE
|
||||
else
|
||||
crontab -u munin -
|
||||
fi
|
||||
}
|
||||
|
||||
mklogdir() {
|
||||
}
|
||||
|
||||
newsyslog() {
|
||||
if fgrep -q '/var/log/munin-main/*' /etc/newsyslog.conf; then
|
||||
:
|
||||
else
|
||||
cat >> /etc/newsyslog.conf <<EOT
|
||||
/var/log/munin-main/*.log munin:munin 644 7 * @T00 GNWZ
|
||||
EOT
|
||||
fi
|
||||
}
|
||||
|
||||
move_www_dir() {
|
||||
if [ -d ${PKG_PREFIX}/www/data/munin -a ! -d ${PKG_PREFIX}/www/munin ]; then
|
||||
echo Migrating ${PKG_PREFIX}/www/data/munin to ${PKG_PREFIX}/www/munin
|
||||
mv ${PKG_PREFIX}/www/data/munin ${PKG_PREFIX}/www/munin
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
########################################################################
|
||||
|
||||
case $2 in
|
||||
PRE-INSTALL)
|
||||
make_account munin munin "Munin owner"
|
||||
move_www_dir # at some point in the installation, the www dir is created
|
||||
;;
|
||||
POST-INSTALL)
|
||||
if [ -z "${PACKAGE_BUILDING}" ]; then
|
||||
newsyslog
|
||||
create_crontab_entries '#BEGIN_MUNIN_MAIN' '#END_MUNIN_MAIN' <<EOT
|
||||
#BEGIN_MUNIN_MAIN
|
||||
MAILTO=root
|
||||
|
||||
*/5 * * * * ${PKG_PREFIX}/bin/munin-cron
|
||||
#END_MUNIN_MAIN
|
||||
EOT
|
||||
fi
|
||||
;;
|
||||
esac
|
|
@ -1,55 +0,0 @@
|
|||
@exec mkdir -p /var/run/munin && chown munin:munin /var/run/munin
|
||||
@exec mkdir -p /var/log/munin-main && chown munin:munin /var/log/munin-main
|
||||
@exec mkdir -p %D/%%WWWDIR%% && chown munin:munin %D/%%WWWDIR%%
|
||||
@exec mkdir -p %D/var/munin && chown munin:munin %D/var/munin
|
||||
bin/munin-cron
|
||||
@unexec if cmp -s %D/etc/munin/munin.conf.sample %D/etc/munin/munin.conf; then rm -f %D/etc/munin/munin.conf; fi
|
||||
etc/munin/munin.conf.sample
|
||||
etc/munin/templates/definitions.html
|
||||
@unexec if cmp -s %D/etc/munin/templates/logo.png %D/%%WWWDIR%%/logo.png; then rm -f %D/%%WWWDIR%%/logo.png; fi
|
||||
etc/munin/templates/logo.png
|
||||
etc/munin/templates/munin-comparison-day.tmpl
|
||||
etc/munin/templates/munin-comparison-month.tmpl
|
||||
etc/munin/templates/munin-comparison-week.tmpl
|
||||
etc/munin/templates/munin-comparison-year.tmpl
|
||||
etc/munin/templates/munin-domainview.tmpl
|
||||
etc/munin/templates/munin-nodeview.tmpl
|
||||
etc/munin/templates/munin-overview.tmpl
|
||||
etc/munin/templates/munin-serviceview.tmpl
|
||||
@unexec if cmp -s %D/etc/munin/templates/style.css %D/%%WWWDIR%%/style.css; then rm -f %D/%%WWWDIR%%/style.css; fi
|
||||
etc/munin/templates/style.css
|
||||
%%SITE_PERL%%/Munin.pm
|
||||
%%DATADIR%%/VeraMono.ttf
|
||||
%%DATADIR%%/munin-graph
|
||||
%%DATADIR%%/munin-html
|
||||
%%DATADIR%%/munin-limits
|
||||
%%DATADIR%%/munin-update
|
||||
www/cgi-bin/munin-cgi-graph
|
||||
@unexec rm -f /var/run/munin/munin-*.lock
|
||||
@dirrmtry /var/run/munin
|
||||
@dirrmtry /var/log/munin-main
|
||||
@dirrmtry %%WWWDIR%%
|
||||
@dirrmtry www/cgi-bin
|
||||
@dirrmtry var/munin
|
||||
@dirrmtry %%DATADIR%%
|
||||
@dirrmtry etc/munin/templates
|
||||
@dirrmtry etc/munin
|
||||
@unexec echo
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo "If you want to *completely* remove munin-main, you have to"
|
||||
@unexec echo
|
||||
@unexec echo " rm -rf \\"
|
||||
@unexec if [ -d %D/%%WWWDIR%% ]; then echo " %D/%%WWWDIR%% \\"; fi
|
||||
@unexec if [ -d %D/var/munin ]; then ls -d %D/var/munin/* | grep -v plugin-state | fmt -40 | sed -e 's/^/ /' -e 's/$/ \\/'; fi
|
||||
@unexec if [ -f %D/etc/munin/munin.conf ]; then echo " %D/etc/munin/munin.conf \\"; fi
|
||||
@unexec if [ -d %D/etc/munin/templates ]; then echo " %D/etc/munin/templates \\"; fi
|
||||
@unexec echo " /var/log/munin-main"
|
||||
@unexec echo
|
||||
@unexec echo "If you have already deinstalled munin-node, you can also"
|
||||
@unexec echo
|
||||
@unexec echo " rmdir %D/etc/munin %D/var/munin"
|
||||
@unexec echo
|
||||
@unexec echo "These files and directories have to be left on the system because"
|
||||
@unexec echo "you may be performing an update. This process can't tell."
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo
|
|
@ -1,4 +1,4 @@
|
|||
# New ports collection makefile for: munin-main
|
||||
# New ports collection makefile for: munin-master
|
||||
# Date created: 25 Januar 2004
|
||||
# Whom: Lupe Christoph <lupe@lupe-christoph.de>
|
||||
#
|
||||
|
@ -6,49 +6,86 @@
|
|||
#
|
||||
|
||||
PORTNAME= munin
|
||||
PORTVERSION= 1.2.6
|
||||
PORTREVISION= 1
|
||||
PORTVERSION= 1.4.3
|
||||
CATEGORIES= sysutils perl5
|
||||
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20stable/${PORTVERSION}
|
||||
PKGNAMESUFFIX= -main
|
||||
DISTNAME= ${PORTNAME}_${PORTVERSION:S/.r/rc/}
|
||||
PKGNAMESUFFIX= -master
|
||||
|
||||
MAINTAINER= des@FreeBSD.org
|
||||
COMMENT= Collector part of Munin
|
||||
|
||||
USE_PERL5= yes
|
||||
|
||||
RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/RRDs.pm:${PORTSDIR}/databases/rrdtool \
|
||||
BUILD_DEPENDS= ${SITE_PERL}/Module/Build.pm:${PORTSDIR}/devel/p5-Module-Build \
|
||||
${SITE_PERL}/Munin/Common/Defaults.pm:${PORTSDIR}/sysutils/munin-common \
|
||||
${SITE_PERL}/${PERL_ARCH}/Digest/MD5.pm:${PORTSDIR}/security/p5-Digest-MD5 \
|
||||
${SITE_PERL}/${PERL_ARCH}/Net/SSLeay.pm:${PORTSDIR}/security/p5-Net-SSLeay \
|
||||
${SITE_PERL}/${PERL_ARCH}/RRDs.pm:${PORTSDIR}/databases/rrdtool \
|
||||
${SITE_PERL}/${PERL_ARCH}/Storable.pm:${PORTSDIR}/converters/p5-Storable-AMF \
|
||||
${SITE_PERL}/DateTime/HiRes.pm:${PORTSDIR}/devel/p5-DateTime-HiRes \
|
||||
${SITE_PERL}/Getopt/Long.pm:${PORTSDIR}/devel/p5-Getopt-Long \
|
||||
${SITE_PERL}/HTML/Template.pm:${PORTSDIR}/www/p5-HTML-Template \
|
||||
${SITE_PERL}/Date/Manip.pm:${PORTSDIR}/devel/p5-Date-Manip
|
||||
BUILD_DEPENDS= ${RUN_DEPENDS}
|
||||
${SITE_PERL}/Log/Log4perl.pm:${PORTSDIR}/devel/p5-Log-Log4perl \
|
||||
${SITE_PERL}/Text/Balanced.pm:${PORTSDIR}/textproc/p5-Text-Balanced
|
||||
RUN_DEPENDS= ${SITE_PERL}/Munin/Common/Defaults.pm:${PORTSDIR}/sysutils/munin-common \
|
||||
${SITE_PERL}/${PERL_ARCH}/RRDs.pm:${PORTSDIR}/databases/rrdtool \
|
||||
${SITE_PERL}/${PERL_ARCH}/Digest/MD5.pm:${PORTSDIR}/security/p5-Digest-MD5 \
|
||||
${SITE_PERL}/${PERL_ARCH}/Net/SSLeay.pm:${PORTSDIR}/security/p5-Net-SSLeay \
|
||||
${SITE_PERL}/${PERL_ARCH}/Storable.pm:${PORTSDIR}/converters/p5-Storable-AMF \
|
||||
${SITE_PERL}/DateTime/HiRes.pm:${PORTSDIR}/devel/p5-DateTime-HiRes \
|
||||
${SITE_PERL}/Getopt/Long.pm:${PORTSDIR}/devel/p5-Getopt-Long \
|
||||
${SITE_PERL}/HTML/Template.pm:${PORTSDIR}/www/p5-HTML-Template \
|
||||
${SITE_PERL}/Log/Log4perl.pm:${PORTSDIR}/devel/p5-Log-Log4perl \
|
||||
${SITE_PERL}/Text/Balanced.pm:${PORTSDIR}/textproc/p5-Text-Balanced
|
||||
|
||||
USE_PERL5= yes
|
||||
USE_GMAKE= yes
|
||||
PATCH_STRIP= -p1
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.r/rc/}
|
||||
PKGMESSAGE= ${WRKDIR}/pkg-message
|
||||
ALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} build build-man
|
||||
INSTALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} SITE_PERL_REL=$(SITE_PERL_REL) install-main
|
||||
|
||||
MAKE_ARGS= LIBDIR=${DATADIR} CONFDIR=${ETCDIR} \
|
||||
WWWDIR=${WWWDIR} CGIDIR=${WWWDIR}/cgi-bin \
|
||||
PERL=${PERL} SITE_PERL_REL=${SITE_PERL_REL}
|
||||
ALL_TARGET= build-master build-man
|
||||
INSTALL_TARGET= install-master-prime
|
||||
|
||||
MAN3= Munin::Master::Config.3 \
|
||||
Munin::Master::Group.3 \
|
||||
Munin::Master::GroupRepository.3 \
|
||||
Munin::Master::HTMLOld.3 \
|
||||
Munin::Master::Host.3 \
|
||||
Munin::Master::Logger.3 \
|
||||
Munin::Master::Node.3 \
|
||||
Munin::Master::ProcessManager.3 \
|
||||
Munin::Master::Update.3 \
|
||||
Munin::Master::UpdateWorker.3 \
|
||||
Munin::Master::Utils.3 \
|
||||
Munin::Master::Worker.3
|
||||
MAN5= munin.conf.5
|
||||
MAN8= munin-cron.8 munin-graph.8 munin-html.8 munin-limits.8 munin-update.8
|
||||
MAN8= munin-cron.8 \
|
||||
munin-graph.8 \
|
||||
munin-html.8 \
|
||||
munin-limits.8 \
|
||||
munin-update.8
|
||||
|
||||
SUB_FILES=pkg-message
|
||||
SUB_FILES= pkg-message
|
||||
|
||||
pre-install:
|
||||
@PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/pkg-install ${PKGNAME} PRE-INSTALL
|
||||
|
||||
post-install:
|
||||
@${INSTALL_DATA} ${WRKSRC}/build/server/munin.conf ${PREFIX}/etc/munin/munin.conf.sample
|
||||
@for man in ${MAN5}; do \
|
||||
${INSTALL_MAN} -C ${WRKSRC}/build/doc/$$man ${PREFIX}/man/man5; \
|
||||
done
|
||||
@for man in ${MAN8}; do \
|
||||
${INSTALL_MAN} -C ${WRKSRC}/build/doc/$$man ${PREFIX}/man/man8; \
|
||||
done
|
||||
@${INSTALL_DATA} ${WRKSRC}/build/master/munin.conf ${PREFIX}/etc/munin/munin.conf.sample
|
||||
@(cd ${WRKSRC}/master/blib/libdoc && for man in ${MAN3}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man3; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/build/doc && for man in ${MAN5}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man5; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/build/doc && for man in ${MAN8}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man8; \
|
||||
done)
|
||||
@DATADIR=${DATADIR} PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/pkg-install ${PKGNAME} POST-INSTALL
|
||||
@${CHOWN} munin /var/log/munin-main
|
||||
@${CHGRP} munin /var/run/munin /var/log/munin-main ${WWWDIR} ${PREFIX}/var/munin
|
||||
@${CHOWN} munin /var/log/munin-master
|
||||
@${CHGRP} munin /var/run/munin /var/log/munin-master ${WWWDIR} ${PREFIX}/var/munin
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
MD5 (munin_1.2.6.tar.gz) = 45f84d58f80642ce914f147232f0d396
|
||||
SHA256 (munin_1.2.6.tar.gz) = 3b04d72810317a91225c78652277079ec3cc5791ef8991326da219a05d2477d8
|
||||
SIZE (munin_1.2.6.tar.gz) = 360694
|
||||
MD5 (munin-1.4.3.tar.gz) = 229646facc4e2bca6511b20b3e5eb73f
|
||||
SHA256 (munin-1.4.3.tar.gz) = c5f1c8e5e71e9ffd5c74037ec3eec4da362fd2aecea3c788abb7d92b461834d0
|
||||
SIZE (munin-1.4.3.tar.gz) = 1205698
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- Makefile.orig Tue May 11 22:23:06 2004
|
||||
+++ Makefile Fri Jun 4 00:25:54 2004
|
||||
@@ -26,7 +26,7 @@
|
||||
mkdir -p $(HTMLDIR)
|
||||
mkdir -p $(DBDIR)
|
||||
--- Makefile.orig 2010-01-30 10:49:44.000000000 -0700
|
||||
+++ Makefile 2010-01-30 10:49:53.000000000 -0700
|
||||
@@ -69,7 +69,7 @@
|
||||
mkdir -p $(LOGDIR)
|
||||
mkdir -p $(STATEDIR)
|
||||
mkdir -p $(CONFDIR)
|
||||
- $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR)
|
||||
+ $(CHOWN) $(USER) $(STATEDIR)
|
||||
|
||||
- $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR) $(RUNDIR) $(HTMLDIR) $(DBDIR)
|
||||
+ $(CHOWN) $(USER) $(STATEDIR) $(RUNDIR) $(HTMLDIR) $(DBDIR)
|
||||
|
||||
for p in server/*.tmpl; do \
|
||||
$(INSTALL) -m 0644 "$$p" $(CONFDIR)/templates/ ; \
|
||||
install-master-prime: $(INFILES_MASTER) install-pre install-master
|
||||
mkdir -p $(CONFDIR)/templates
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- Makefile.config.orig 2008-01-20 20:32:46.000000000 +0100
|
||||
+++ Makefile.config 2008-08-09 15:44:18.000000000 +0200
|
||||
@@ -7,46 +7,50 @@
|
||||
--- Makefile.config.orig 2009-12-30 05:55:56.000000000 -0700
|
||||
+++ Makefile.config 2010-01-30 11:17:34.000000000 -0700
|
||||
@@ -17,29 +17,33 @@
|
||||
#
|
||||
# the base of the Munin installation.
|
||||
#
|
||||
|
@ -36,11 +36,16 @@
|
|||
+LIBDIR = $(DATADIR)
|
||||
|
||||
# Server only - Output directory
|
||||
-HTMLDIR = $(PREFIX)/var/www
|
||||
-CGIDIR = $(HTMLDIR)/cgi
|
||||
-HTMLDIR = $(PREFIX)/www/docs
|
||||
-CGIDIR = $(PREFIX)/www/cgi
|
||||
+HTMLDIR = $(WWWDIR)
|
||||
+CGIDIR = $(PREFIX)/www/cgi-bin
|
||||
|
||||
# Server only - spool directory for data gathered from nodes by
|
||||
# munin-gather - experimental. Place on ramdisk to make munin
|
||||
@@ -52,21 +56,20 @@
|
||||
# SSPOOLDIR := /tmp/muninspool
|
||||
|
||||
# Client only - Where to put RRD files and other intenal data
|
||||
-DBDIR = $(DESTDIR)/var/opt/munin
|
||||
+DBDIR = $(PREFIX)/var/munin
|
||||
|
@ -50,8 +55,8 @@
|
|||
PLUGSTATE = $(DBDIR)/plugin-state
|
||||
|
||||
# Where Munin should place its logs.
|
||||
-LOGDIR = $(DESTDIR)/var/log/munin
|
||||
+LOGDIR = /var/log/munin-main
|
||||
-LOGDIR = $(PREFIX)/log/munin
|
||||
+LOGDIR = /var/log/munin-master
|
||||
|
||||
# Location of PID files and other statefiles. On the server, must be
|
||||
# writable by the user "munin".
|
||||
|
@ -59,33 +64,33 @@
|
|||
+STATEDIR = /var/run/munin
|
||||
|
||||
# The perl interpreter to use
|
||||
-PERL = $(shell which perl)
|
||||
+# Passed in from FreeBSD port Makefile.
|
||||
-PERL := $(shell which perl)
|
||||
|
||||
# The python interpreter to use (used by some plugins)
|
||||
PYTHON = /usr/bin/env python
|
||||
@@ -62,10 +66,10 @@
|
||||
GOODSH = $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
PYTHON := /usr/bin/env python
|
||||
@@ -95,11 +98,11 @@
|
||||
GOODSH := $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
|
||||
# Path of bash for bash specific plugins
|
||||
-BASH = /bin/bash
|
||||
+BASH = /usr/local/bin/bash
|
||||
-BASH := /bin/bash
|
||||
+BASH := /usr/local/bin/bash
|
||||
|
||||
# Server only - Where to install the perl libraries
|
||||
-PERLLIB = $(DESTDIR)$(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
PERLSITELIB := $(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
-PERLLIB = $(DESTDIR)$(PERLSITELIB)
|
||||
+PERLLIB = $(PREFIX)/$(SITE_PERL_REL)
|
||||
|
||||
# Client only - Install plugins for this architecture
|
||||
OSTYPE = $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -90,9 +94,8 @@
|
||||
PLUGINUSER = nobody
|
||||
|
||||
OSTYPE := $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -126,9 +129,8 @@
|
||||
# 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)
|
||||
-CHECKUSER = $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP = $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
# These will work on most modern OSes:
|
||||
#
|
||||
-GETENT := $(shell which getent || which true 2>/dev/null)
|
||||
-CHECKUSER := $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistent. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP := $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistent. Create the group and retry; exit 2"))
|
||||
+CHECKUSER:= $(shell /usr/sbin/pw user show $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
+CHECKGROUP:= $(shell /usr/sbin/pw group show $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
|
||||
# For OSX, comment out the previous two lines and comment in these
|
||||
#CHECKUSER = $(shell nicl . -read /users/$(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
#
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
********************************************************************
|
||||
Unless this file already existed, a sample configuration file
|
||||
has been placed in %%PREFIX%%/etc/munin/munin.conf.
|
||||
has been placed in %%ETCDIR%%/munin/munin.conf.
|
||||
|
||||
Please edit it according to your needs.
|
||||
|
||||
|
|
|
@ -85,19 +85,19 @@ delete_crontab_entries() {
|
|||
|
||||
delnewsyslog() {
|
||||
tmp="/etc/#munin-node$$"
|
||||
sed -e '/^\/var\/log\/munin-main\/\*\.log[ ]/d' /etc/newsyslog.conf >${tmp}
|
||||
sed -e '/^\/var\/log\/munin-master\/\*\.log[ ]/d' /etc/newsyslog.conf >${tmp}
|
||||
cat ${tmp} > /etc/newsyslog.conf
|
||||
rm ${tmp}
|
||||
}
|
||||
|
||||
newsyslog() {
|
||||
ENTRY=`fgrep '/var/log/munin-main/*' /etc/newsyslog.conf`
|
||||
DEFAULT='/var/log/munin-main/*.log munin:munin 644 7 * @T00 GNWZ'
|
||||
ENTRY=`fgrep '/var/log/munin-master/*' /etc/newsyslog.conf`
|
||||
DEFAULT='/var/log/munin-master/*.log munin:munin 644 7 * @T00 GNWZ'
|
||||
if [ -z "$ENTRY" ]; then
|
||||
exit 0
|
||||
elif [ "$ENTRY" = "$DEFAULT" ]; then
|
||||
delnewsyslog
|
||||
elif yesno "You have changed the default munin-main entry in \"/etc/newsyslog.conf\".
|
||||
elif yesno "You have changed the default munin-master entry in \"/etc/newsyslog.conf\".
|
||||
Do you want me to delete it?" y; then
|
||||
delnewsyslog
|
||||
echo "Done."
|
||||
|
|
|
@ -88,11 +88,11 @@ mklogdir() {
|
|||
}
|
||||
|
||||
newsyslog() {
|
||||
if fgrep -q '/var/log/munin-main/*' /etc/newsyslog.conf; then
|
||||
if fgrep -q '/var/log/munin-master/*' /etc/newsyslog.conf; then
|
||||
:
|
||||
else
|
||||
cat >> /etc/newsyslog.conf <<EOT
|
||||
/var/log/munin-main/*.log munin:munin 644 7 * @T00 GNWZ
|
||||
/var/log/munin-master/*.log munin:munin 644 7 * @T00 GNWZ
|
||||
EOT
|
||||
fi
|
||||
}
|
||||
|
|
|
@ -1,55 +1,55 @@
|
|||
@exec mkdir -p /var/run/munin && chown munin:munin /var/run/munin
|
||||
@exec mkdir -p /var/log/munin-main && chown munin:munin /var/log/munin-main
|
||||
@exec mkdir -p %D/%%WWWDIR%% && chown munin:munin %D/%%WWWDIR%%
|
||||
@exec mkdir -p %D/var/munin && chown munin:munin %D/var/munin
|
||||
bin/munin-check
|
||||
bin/munin-cron
|
||||
@unexec if cmp -s %D/etc/munin/munin.conf.sample %D/etc/munin/munin.conf; then rm -f %D/etc/munin/munin.conf; fi
|
||||
etc/munin/munin.conf.sample
|
||||
etc/munin/templates/definitions.html
|
||||
@unexec if cmp -s %D/etc/munin/templates/logo.png %D/%%WWWDIR%%/logo.png; then rm -f %D/%%WWWDIR%%/logo.png; fi
|
||||
etc/munin/templates/logo.png
|
||||
etc/munin/templates/munin-comparison-day.tmpl
|
||||
etc/munin/templates/munin-comparison-month.tmpl
|
||||
etc/munin/templates/munin-comparison-week.tmpl
|
||||
etc/munin/templates/munin-comparison-year.tmpl
|
||||
etc/munin/templates/munin-domainview.tmpl
|
||||
etc/munin/templates/munin-nodeview.tmpl
|
||||
etc/munin/templates/munin-overview.tmpl
|
||||
etc/munin/templates/munin-serviceview.tmpl
|
||||
@unexec if cmp -s %D/etc/munin/templates/style.css %D/%%WWWDIR%%/style.css; then rm -f %D/%%WWWDIR%%/style.css; fi
|
||||
etc/munin/templates/style.css
|
||||
%%SITE_PERL%%/Munin.pm
|
||||
%%DATADIR%%/VeraMono.ttf
|
||||
%%ETCDIR%%/munin.conf.sample
|
||||
%%ETCDIR%%/templates/definitions.html
|
||||
%%ETCDIR%%/templates/favicon.ico
|
||||
%%ETCDIR%%/templates/logo-h.png
|
||||
%%ETCDIR%%/templates/logo.png
|
||||
%%ETCDIR%%/templates/munin-comparison-day.tmpl
|
||||
%%ETCDIR%%/templates/munin-comparison-month.tmpl
|
||||
%%ETCDIR%%/templates/munin-comparison-week.tmpl
|
||||
%%ETCDIR%%/templates/munin-comparison-year.tmpl
|
||||
%%ETCDIR%%/templates/munin-domainview.tmpl
|
||||
%%ETCDIR%%/templates/munin-nodeview.tmpl
|
||||
%%ETCDIR%%/templates/munin-overview.tmpl
|
||||
%%ETCDIR%%/templates/munin-serviceview.tmpl
|
||||
%%ETCDIR%%/templates/partial/bottom_navigation.tmpl
|
||||
%%ETCDIR%%/templates/partial/generated_by.tmpl
|
||||
%%ETCDIR%%/templates/partial/head.tmpl
|
||||
%%ETCDIR%%/templates/partial/logo_navigation.tmpl
|
||||
%%ETCDIR%%/templates/partial/logo_navigation_comparison.tmpl
|
||||
%%ETCDIR%%/templates/partial/logo_path.tmpl
|
||||
%%ETCDIR%%/templates/partial/path.tmpl
|
||||
%%ETCDIR%%/templates/style-1.2.css
|
||||
%%ETCDIR%%/templates/style.css
|
||||
%%SITE_PERL%%/Munin/Master/Config.pm
|
||||
%%SITE_PERL%%/Munin/Master/GraphOld.pm
|
||||
%%SITE_PERL%%/Munin/Master/Group.pm
|
||||
%%SITE_PERL%%/Munin/Master/GroupRepository.pm
|
||||
%%SITE_PERL%%/Munin/Master/HTMLOld.pm
|
||||
%%SITE_PERL%%/Munin/Master/Host.pm
|
||||
%%SITE_PERL%%/Munin/Master/LimitsOld.pm
|
||||
%%SITE_PERL%%/Munin/Master/Logger.pm
|
||||
%%SITE_PERL%%/Munin/Master/Node.pm
|
||||
%%SITE_PERL%%/Munin/Master/ProcessManager.pm
|
||||
%%SITE_PERL%%/Munin/Master/Update.pm
|
||||
%%SITE_PERL%%/Munin/Master/UpdateWorker.pm
|
||||
%%SITE_PERL%%/Munin/Master/Utils.pm
|
||||
%%SITE_PERL%%/Munin/Master/Worker.pm
|
||||
%%DATADIR%%/DejaVuSans.ttf
|
||||
%%DATADIR%%/DejaVuSansMono.ttf
|
||||
%%DATADIR%%/munin-graph
|
||||
%%DATADIR%%/munin-html
|
||||
%%DATADIR%%/munin-limits
|
||||
%%DATADIR%%/munin-update
|
||||
www/cgi-bin/munin-cgi-graph
|
||||
@unexec rm -f /var/run/munin/munin-*.lock
|
||||
@dirrmtry /var/run/munin
|
||||
@dirrmtry /var/log/munin-main
|
||||
%%WWWDIR%%/cgi-bin/munin-cgi-graph
|
||||
%%WWWDIR%%/cgi-bin/munin-fastcgi-graph
|
||||
%%WWWDIR%%/.htaccess
|
||||
@dirrmtry %%WWWDIR%%/cgi-bin
|
||||
@dirrmtry %%WWWDIR%%
|
||||
@dirrmtry www/cgi-bin
|
||||
@dirrmtry var/munin
|
||||
@dirrmtry %%DATADIR%%
|
||||
@dirrmtry etc/munin/templates
|
||||
@dirrmtry etc/munin
|
||||
@unexec echo
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo "If you want to *completely* remove munin-main, you have to"
|
||||
@unexec echo
|
||||
@unexec echo " rm -rf \\"
|
||||
@unexec if [ -d %D/%%WWWDIR%% ]; then echo " %D/%%WWWDIR%% \\"; fi
|
||||
@unexec if [ -d %D/var/munin ]; then ls -d %D/var/munin/* | grep -v plugin-state | fmt -40 | sed -e 's/^/ /' -e 's/$/ \\/'; fi
|
||||
@unexec if [ -f %D/etc/munin/munin.conf ]; then echo " %D/etc/munin/munin.conf \\"; fi
|
||||
@unexec if [ -d %D/etc/munin/templates ]; then echo " %D/etc/munin/templates \\"; fi
|
||||
@unexec echo " /var/log/munin-main"
|
||||
@unexec echo
|
||||
@unexec echo "If you have already deinstalled munin-node, you can also"
|
||||
@unexec echo
|
||||
@unexec echo " rmdir %D/etc/munin %D/var/munin"
|
||||
@unexec echo
|
||||
@unexec echo "These files and directories have to be left on the system because"
|
||||
@unexec echo "you may be performing an update. This process can't tell."
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo
|
||||
@dirrmtry var/munin
|
||||
@dirrm %%SITE_PERL%%/Munin/Master
|
||||
@dirrmtry %%SITE_PERL%%/Munin
|
||||
@dirrmtry %%ETCDIR%%/templates
|
||||
@dirrmtry %%ETCDIR%%
|
||||
|
|
|
@ -6,51 +6,96 @@
|
|||
#
|
||||
|
||||
PORTNAME= munin
|
||||
PORTVERSION= 1.2.6
|
||||
PORTREVISION= 1
|
||||
PORTVERSION= 1.4.3
|
||||
CATEGORIES= sysutils perl5
|
||||
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20stable/${PORTVERSION}
|
||||
PKGNAMESUFFIX= -node
|
||||
DISTNAME= ${PORTNAME}_${PORTVERSION:S/.r/rc/}
|
||||
|
||||
MAINTAINER= des@FreeBSD.org
|
||||
COMMENT= Node-specific part of Munin
|
||||
|
||||
BUILD_DEPENDS= ${SITE_PERL}/Module/Build.pm:${PORTSDIR}/devel/p5-Module-Build \
|
||||
${SITE_PERL}/DateTime/HiRes.pm:${PORTSDIR}/devel/p5-DateTime-HiRes \
|
||||
${SITE_PERL}/Munin/Common/Defaults.pm:${PORTSDIR}/sysutils/munin-common \
|
||||
${SITE_PERL}/Net/Server.pm:${PORTSDIR}/net/p5-Net-Server \
|
||||
${SITE_PERL}/Net/SNMP.pm:${PORTSDIR}/net-mgmt/p5-Net-SNMP \
|
||||
bash:${PORTSDIR}/shells/bash
|
||||
RUN_DEPENDS= ${SITE_PERL}/DateTime/HiRes.pm:${PORTSDIR}/devel/p5-DateTime-HiRes \
|
||||
${SITE_PERL}/Munin/Common/Defaults.pm:${PORTSDIR}/sysutils/munin-common \
|
||||
${SITE_PERL}/Net/Server.pm:${PORTSDIR}/net/p5-Net-Server \
|
||||
${SITE_PERL}/Net/SNMP.pm:${PORTSDIR}/net-mgmt/p5-Net-SNMP \
|
||||
bash:${PORTSDIR}/shells/bash
|
||||
|
||||
USE_PERL5= yes
|
||||
|
||||
RUN_DEPENDS= ${SITE_PERL}/Net/Server/Fork.pm:${PORTSDIR}/net/p5-Net-Server
|
||||
BUILD_DEPENDS= ${RUN_DEPENDS}
|
||||
|
||||
USE_GMAKE= yes
|
||||
PATCH_STRIP= -p0
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION:S/.r/rc/}
|
||||
PKGMESSAGE= ${WRKDIR}/pkg-message
|
||||
ALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} build build-man
|
||||
INSTALL_TARGET= WWWDIR=${WWWDIR} DATADIR=${DATADIR} PERL=${PERL} SITE_PERL_REL=$(SITE_PERL_REL) install-node install-node-plugins
|
||||
MAKE_ENV= LANG=C
|
||||
|
||||
MAKE_ARGS= LIBDIR=${DATADIR} CONFDIR=${ETCDIR} \
|
||||
PERL=${PERL} SITE_PERL_REL=${SITE_PERL_REL}
|
||||
ALL_TARGET= build-node build-plugins
|
||||
INSTALL_TARGET= install-node-prime install-plugins-prime
|
||||
|
||||
MAN1= munin-node-configure.1 \
|
||||
munin-node.1 \
|
||||
munin-run.1 \
|
||||
munindoc.1
|
||||
MAN3_NODE= Munin::Node::Config.3 \
|
||||
Munin::Node::Configure::Debug.3 \
|
||||
Munin::Node::Configure::History.3 \
|
||||
Munin::Node::Configure::HostEnumeration.3 \
|
||||
Munin::Node::Configure::Plugin.3 \
|
||||
Munin::Node::Configure::PluginList.3 \
|
||||
Munin::Node::Logger.3 \
|
||||
Munin::Node::OS.3 \
|
||||
Munin::Node::SNMPConfig.3 \
|
||||
Munin::Node::Server.3 \
|
||||
Munin::Node::Service.3 \
|
||||
Munin::Node::Session.3 \
|
||||
Munin::Node::Utils.3
|
||||
MAN3_PLUGIN= Munin::Plugin.3 \
|
||||
Munin::Plugin::Pgsql.3 \
|
||||
Munin::Plugin::SNMP.3
|
||||
MAN3= ${MAN3_NODE} ${MAN3_PLUGIN}
|
||||
MAN5= munin-node.conf.5
|
||||
MAN8= munin-node-configure.8 munin-node.8 munin-run.8
|
||||
MAN8= munin.8
|
||||
|
||||
SUB_FILES= pkg-message munin-node.sh munin-node-revive.sh
|
||||
SUB_LIST= RC_SUBR=${RC_SUBR}
|
||||
USE_RC_SUBR= YES
|
||||
SUB_FILES= pkg-message munin-node-revive.sh
|
||||
USE_RC_SUBR= munin-node.sh
|
||||
RC_SUBR_SUFFIX= .sh
|
||||
|
||||
pre-su-install:
|
||||
@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
post-install:
|
||||
${INSTALL_SCRIPT} ${WRKDIR}/munin-node.sh ${PREFIX}/etc/rc.d/munin-node.sh
|
||||
${INSTALL_DATA} ${WRKSRC}/build/node/munin-node.conf ${PREFIX}/etc/munin/munin-node.conf.sample
|
||||
${INSTALL_DATA} ${FILESDIR}/plugins.conf ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample
|
||||
${INSTALL_SCRIPT} ${WRKDIR}/munin-node.sh \
|
||||
${PREFIX}/etc/rc.d/munin-node.sh
|
||||
${INSTALL_DATA} ${WRKSRC}/build/node/munin-node.conf \
|
||||
${PREFIX}/etc/munin/munin-node.conf.sample
|
||||
${INSTALL_DATA} ${FILESDIR}/plugins.conf \
|
||||
${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample
|
||||
@if [ ! -f ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf ]; then \
|
||||
${INSTALL_DATA} ${PREFIX}/etc/munin/plugin-conf.d/plugins.conf.sample ${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
|
||||
@(cd ${WRKSRC}/node/blib/bindoc && for man in ${MAN1}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man1; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/node/blib/libdoc && for man in ${MAN3_NODE}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man3; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/plugins/blib/libdoc && for man in ${MAN3_PLUGIN}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man3; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/build/doc && for man in ${MAN5}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man5; \
|
||||
done)
|
||||
@(cd ${WRKSRC}/build/doc && for man in ${MAN8}; do \
|
||||
${INSTALL_MAN} -C $$man ${PREFIX}/man/man8; \
|
||||
done)
|
||||
@${ECHO} ${PORTVERSION} > ${PREFIX}/etc/munin/VERSION.node
|
||||
PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
@${INSTALL_MAN} -C ${WRKSRC}/build/doc/munin-node.conf.5 ${PREFIX}/man/man5
|
||||
@${INSTALL_MAN} -C ${WRKSRC}/build/doc/munin-node-configure.8 ${PREFIX}/man/man8
|
||||
@${INSTALL_MAN} -C ${WRKSRC}/build/doc/munin-node.8 ${PREFIX}/man/man8
|
||||
@${INSTALL_MAN} -C ${WRKSRC}/build/doc/munin-run.8 ${PREFIX}/man/man8
|
||||
@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
@${ECHO} ${DISTNAME} | ${SED} -e 's/munin_//' > ${PREFIX}/etc/munin/VERSION.node
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
MD5 (munin_1.2.6.tar.gz) = 45f84d58f80642ce914f147232f0d396
|
||||
SHA256 (munin_1.2.6.tar.gz) = 3b04d72810317a91225c78652277079ec3cc5791ef8991326da219a05d2477d8
|
||||
SIZE (munin_1.2.6.tar.gz) = 360694
|
||||
MD5 (munin-1.4.3.tar.gz) = 229646facc4e2bca6511b20b3e5eb73f
|
||||
SHA256 (munin-1.4.3.tar.gz) = c5f1c8e5e71e9ffd5c74037ec3eec4da362fd2aecea3c788abb7d92b461834d0
|
||||
SIZE (munin-1.4.3.tar.gz) = 1205698
|
||||
|
|
14
sysutils/munin-node/files/patch-Makefile
Normal file
14
sysutils/munin-node/files/patch-Makefile
Normal file
|
@ -0,0 +1,14 @@
|
|||
--- Makefile.orig 2009-12-30 05:55:56.000000000 -0700
|
||||
+++ Makefile 2010-01-30 12:57:44.000000000 -0700
|
||||
@@ -65,11 +65,8 @@
|
||||
endif
|
||||
|
||||
install-pre: Makefile Makefile.config
|
||||
- @$(CHECKUSER)
|
||||
- mkdir -p $(LOGDIR)
|
||||
mkdir -p $(STATEDIR)
|
||||
mkdir -p $(CONFDIR)
|
||||
- $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR)
|
||||
|
||||
install-master-prime: $(INFILES_MASTER) install-pre install-master
|
||||
mkdir -p $(CONFDIR)/templates
|
|
@ -1,6 +1,6 @@
|
|||
--- Makefile.config.orig 2008-01-20 20:32:46.000000000 +0100
|
||||
+++ Makefile.config 2008-08-09 15:44:06.000000000 +0200
|
||||
@@ -7,46 +7,50 @@
|
||||
--- Makefile.config.orig 2009-12-30 05:55:56.000000000 -0700
|
||||
+++ Makefile.config 2010-01-30 11:17:34.000000000 -0700
|
||||
@@ -17,29 +17,33 @@
|
||||
#
|
||||
# the base of the Munin installation.
|
||||
#
|
||||
|
@ -36,11 +36,16 @@
|
|||
+LIBDIR = $(DATADIR)
|
||||
|
||||
# Server only - Output directory
|
||||
-HTMLDIR = $(PREFIX)/var/www
|
||||
-CGIDIR = $(HTMLDIR)/cgi
|
||||
-HTMLDIR = $(PREFIX)/www/docs
|
||||
-CGIDIR = $(PREFIX)/www/cgi
|
||||
+HTMLDIR = $(WWWDIR)
|
||||
+CGIDIR = $(PREFIX)/www/cgi-bin
|
||||
|
||||
# Server only - spool directory for data gathered from nodes by
|
||||
# munin-gather - experimental. Place on ramdisk to make munin
|
||||
@@ -52,21 +56,20 @@
|
||||
# SSPOOLDIR := /tmp/muninspool
|
||||
|
||||
# Client only - Where to put RRD files and other intenal data
|
||||
-DBDIR = $(DESTDIR)/var/opt/munin
|
||||
+DBDIR = $(PREFIX)/var/munin
|
||||
|
@ -50,8 +55,8 @@
|
|||
PLUGSTATE = $(DBDIR)/plugin-state
|
||||
|
||||
# Where Munin should place its logs.
|
||||
-LOGDIR = $(DESTDIR)/var/log/munin
|
||||
+LOGDIR = /var/log
|
||||
-LOGDIR = $(PREFIX)/log/munin
|
||||
+LOGDIR = /var/log/munin-main
|
||||
|
||||
# Location of PID files and other statefiles. On the server, must be
|
||||
# writable by the user "munin".
|
||||
|
@ -59,33 +64,33 @@
|
|||
+STATEDIR = /var/run/munin
|
||||
|
||||
# The perl interpreter to use
|
||||
-PERL = $(shell which perl)
|
||||
+# Passed in from FreeBSD port Makefile.
|
||||
-PERL := $(shell which perl)
|
||||
|
||||
# The python interpreter to use (used by some plugins)
|
||||
PYTHON = /usr/bin/env python
|
||||
@@ -62,10 +66,10 @@
|
||||
GOODSH = $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
PYTHON := /usr/bin/env python
|
||||
@@ -95,11 +98,11 @@
|
||||
GOODSH := $(shell PATH=`getconf PATH` sh -c 'type sh | sed "s/.* //"')
|
||||
|
||||
# Path of bash for bash specific plugins
|
||||
-BASH = /bin/bash
|
||||
+BASH = /usr/local/bin/bash
|
||||
-BASH := /bin/bash
|
||||
+BASH := /usr/local/bin/bash
|
||||
|
||||
# Server only - Where to install the perl libraries
|
||||
-PERLLIB = $(DESTDIR)$(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
PERLSITELIB := $(shell $(PERL) -V:sitelib | cut -d"'" -f2)
|
||||
-PERLLIB = $(DESTDIR)$(PERLSITELIB)
|
||||
+PERLLIB = $(PREFIX)/$(SITE_PERL_REL)
|
||||
|
||||
# Client only - Install plugins for this architecture
|
||||
OSTYPE = $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -90,9 +94,8 @@
|
||||
PLUGINUSER = nobody
|
||||
|
||||
OSTYPE := $(shell uname | tr '[A-Z]' '[a-z]')
|
||||
@@ -126,9 +129,8 @@
|
||||
# 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)
|
||||
-CHECKUSER = $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP = $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
# These will work on most modern OSes:
|
||||
#
|
||||
-GETENT := $(shell which getent || which true 2>/dev/null)
|
||||
-CHECKUSER := $(shell $(GETENT) passwd $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistent. Create the user and retry; exit 2"))
|
||||
-CHECKGROUP := $(shell $(GETENT) group $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistent. Create the group and retry; exit 2"))
|
||||
+CHECKUSER:= $(shell /usr/sbin/pw user show $(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
+CHECKGROUP:= $(shell /usr/sbin/pw group show $(GROUP) >/dev/null 2>/dev/null || (echo "echo Group $(GROUP) nonexistant. Create the group and retry; exit 2"))
|
||||
|
||||
# For OSX, comment out the previous two lines and comment in these
|
||||
#CHECKUSER = $(shell nicl . -read /users/$(USER) >/dev/null 2>/dev/null || (echo "echo User $(USER) nonexistant. Create the user and retry; exit 2"))
|
||||
#
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- node/munin-node.conf.in.orig Thu Jan 15 15:28:57 2004
|
||||
+++ node/munin-node.conf.in Sun Jan 25 14:26:15 2004
|
||||
@@ -12,7 +12,7 @@
|
||||
# Which port to bind to;
|
||||
host *
|
||||
--- node/munin-node.conf.in.orig 2010-01-30 12:07:52.000000000 -0700
|
||||
+++ node/munin-node.conf.in 2010-01-30 12:07:59.000000000 -0700
|
||||
@@ -10,7 +10,7 @@
|
||||
setsid 1
|
||||
|
||||
user root
|
||||
-group root
|
||||
+group wheel
|
||||
setsid yes
|
||||
|
||||
# Regexps for files to ignore
|
||||
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
--- node/node.d.freebsd/netstat.in.orig 2006-11-02 15:15:57.000000000 +0100
|
||||
+++ node/node.d.freebsd/netstat.in 2008-08-17 14:01:14.000000000 +0200
|
||||
@@ -45,7 +45,7 @@
|
||||
|
||||
|
||||
if [ "$1" = "autoconf" ]; then
|
||||
- if ( /bin/netstat -s 2>/dev/null >/dev/null ); then
|
||||
+ if ( /usr/bin/netstat -s 2>/dev/null >/dev/null ); then
|
||||
echo yes
|
||||
exit 0
|
||||
else
|
||||
@@ -96,5 +96,5 @@
|
||||
exit 0
|
||||
fi
|
||||
|
||||
-/bin/netstat -s | awk '/connection requests/ { print "active.value " $1 } /connection accepts/ { print "passive.value " $1 } /bad connection/ { print "failed.value " $1 } /reset/ { print "resets.value " $1 } /connections established/ { print "established.value " $1 }'
|
||||
+/usr/bin/netstat -s | awk '/connection requests/ { print "active.value " $1 } /connection accepts/ { print "passive.value " $1 } /bad connection/ { print "failed.value " $1 } /reset/ { print "resets.value " $1 } /connections established/ { print "established.value " $1 }'
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
--- node/node.d/ntp_offset.in.orig 2008-10-14 19:50:27.092576040 +0900
|
||||
+++ node/node.d/ntp_offset.in 2008-10-14 19:50:36.788908430 +0900
|
||||
--- plugins/node.d/ntp_offset.in.orig 2008-10-14 19:50:27.092576040 +0900
|
||||
+++ plugins/node.d/ntp_offset.in 2008-10-14 19:50:36.788908430 +0900
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!@@GOODSH@@ -w
|
||||
+#!@@GOODSH@@
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
|
||||
********************************************************************
|
||||
Unless this file already existed, a sample configuration file
|
||||
has been placed in %%PREFIX%%/etc/munin/munin-node.conf.
|
||||
has been placed in %%ETCDIR%%/munin/munin-node.conf.
|
||||
|
||||
Please edit it according to your needs.
|
||||
|
||||
|
@ -16,6 +15,5 @@ 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:
|
||||
|
||||
%%PREFIX%%/etc/rc.d/munin-node.sh start
|
||||
%%ETCDIR%%/rc.d/munin-node.sh start
|
||||
********************************************************************
|
||||
|
||||
|
|
|
@ -1,74 +1,125 @@
|
|||
@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
|
||||
@unexec if [ -n "$PACKAGE_BUILDING" ]; then rm -f %D/etc/munin/VERSION.node; fi
|
||||
@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
|
||||
bin/munindoc
|
||||
etc/rc.d/munin-node.sh
|
||||
etc/munin/VERSION.node
|
||||
etc/munin/munin-node.conf.sample
|
||||
etc/munin/plugin-conf.d/plugins.conf.sample
|
||||
%%SITE_PERL%%/Munin/Node/Config.pm
|
||||
%%SITE_PERL%%/Munin/Node/Configure/Debug.pm
|
||||
%%SITE_PERL%%/Munin/Node/Configure/History.pm
|
||||
%%SITE_PERL%%/Munin/Node/Configure/HostEnumeration.pm
|
||||
%%SITE_PERL%%/Munin/Node/Configure/Plugin.pm
|
||||
%%SITE_PERL%%/Munin/Node/Configure/PluginList.pm
|
||||
%%SITE_PERL%%/Munin/Node/Logger.pm
|
||||
%%SITE_PERL%%/Munin/Node/OS.pm
|
||||
%%SITE_PERL%%/Munin/Node/SNMPConfig.pm
|
||||
%%SITE_PERL%%/Munin/Node/Server.pm
|
||||
%%SITE_PERL%%/Munin/Node/Service.pm
|
||||
%%SITE_PERL%%/Munin/Node/Session.pm
|
||||
%%SITE_PERL%%/Munin/Node/Utils.pm
|
||||
%%SITE_PERL%%/Munin/Plugin.pm
|
||||
%%SITE_PERL%%/Munin/Plugin/Pgsql.pm
|
||||
%%SITE_PERL%%/Munin/Plugin/SNMP.pm
|
||||
sbin/munin-node
|
||||
sbin/munin-node-configure
|
||||
sbin/munin-node-configure-snmp
|
||||
sbin/munin-run
|
||||
%%DATADIR%%/plugins/acpi
|
||||
%%DATADIR%%/plugins/amavis
|
||||
%%DATADIR%%/plugins/apache_accesses
|
||||
%%DATADIR%%/plugins/apache_processes
|
||||
%%DATADIR%%/plugins/apache_volume
|
||||
%%DATADIR%%/plugins/apc_envunit_
|
||||
%%DATADIR%%/plugins/apc_nis
|
||||
%%DATADIR%%/plugins/asterisk_channels
|
||||
%%DATADIR%%/plugins/asterisk_channelstypes
|
||||
%%DATADIR%%/plugins/asterisk_codecs
|
||||
%%DATADIR%%/plugins/asterisk_meetme
|
||||
%%DATADIR%%/plugins/asterisk_meetmeusers
|
||||
%%DATADIR%%/plugins/asterisk_sipchannels
|
||||
%%DATADIR%%/plugins/asterisk_sippeers
|
||||
%%DATADIR%%/plugins/asterisk_voicemail
|
||||
%%DATADIR%%/plugins/bind9
|
||||
%%DATADIR%%/plugins/bind9_rndc
|
||||
%%DATADIR%%/plugins/cmc_tc_sensor_
|
||||
%%DATADIR%%/plugins/colour_tester
|
||||
%%DATADIR%%/plugins/coretemp
|
||||
%%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/dev_cpu_
|
||||
%%DATADIR%%/plugins/df
|
||||
%%DATADIR%%/plugins/df_inode
|
||||
%%DATADIR%%/plugins/dhcpd3
|
||||
%%DATADIR%%/plugins/digitemp_
|
||||
%%DATADIR%%/plugins/ejabberd_
|
||||
%%DATADIR%%/plugins/env
|
||||
%%DATADIR%%/plugins/exim_mailqueue
|
||||
%%DATADIR%%/plugins/exim_mailqueue_alt
|
||||
%%DATADIR%%/plugins/exim_mailstats
|
||||
%%DATADIR%%/plugins/extinfo_tester
|
||||
%%DATADIR%%/plugins/fail2ban
|
||||
%%DATADIR%%/plugins/foldingathome
|
||||
%%DATADIR%%/plugins/foldingathome_rank
|
||||
%%DATADIR%%/plugins/foldingathome_wu
|
||||
%%DATADIR%%/plugins/freeradius_acct
|
||||
%%DATADIR%%/plugins/freeradius_auth
|
||||
%%DATADIR%%/plugins/freeradius_proxy_acct
|
||||
%%DATADIR%%/plugins/freeradius_proxy_auth
|
||||
%%DATADIR%%/plugins/haproxy_
|
||||
%%DATADIR%%/plugins/hddtemp
|
||||
%%DATADIR%%/plugins/hddtemp2
|
||||
%%DATADIR%%/plugins/hddtemp_smartctl
|
||||
%%DATADIR%%/plugins/hddtempd
|
||||
%%DATADIR%%/plugins/http_loadtime
|
||||
%%DATADIR%%/plugins/id
|
||||
%%DATADIR%%/plugins/if_
|
||||
%%DATADIR%%/plugins/if_errcoll_
|
||||
%%DATADIR%%/plugins/ifx_concurrent_sessions_
|
||||
%%DATADIR%%/plugins/iostat
|
||||
%%DATADIR%%/plugins/ipac-ng
|
||||
%%DATADIR%%/plugins/ipmi_sensor_
|
||||
%%DATADIR%%/plugins/ircu
|
||||
%%DATADIR%%/plugins/jmx_
|
||||
%%DATADIR%%/plugins/load
|
||||
%%DATADIR%%/plugins/loggrep
|
||||
%%DATADIR%%/plugins/lpstat
|
||||
%%DATADIR%%/plugins/mailman
|
||||
%%DATADIR%%/plugins/mailscanner
|
||||
%%DATADIR%%/plugins/mbmon_
|
||||
%%DATADIR%%/plugins/memcached_
|
||||
%%DATADIR%%/plugins/memory
|
||||
%%DATADIR%%/plugins/mhttping
|
||||
%%DATADIR%%/plugins/multigraph_tester
|
||||
%%DATADIR%%/plugins/multiping
|
||||
%%DATADIR%%/plugins/multips
|
||||
%%DATADIR%%/plugins/munin_graph
|
||||
%%DATADIR%%/plugins/multips_memory
|
||||
%%DATADIR%%/plugins/munin_stats
|
||||
%%DATADIR%%/plugins/munin_update
|
||||
%%DATADIR%%/plugins/mysql_
|
||||
%%DATADIR%%/plugins/mysql_bytes
|
||||
%%DATADIR%%/plugins/mysql_innodb
|
||||
%%DATADIR%%/plugins/mysql_isam_space_
|
||||
%%DATADIR%%/plugins/mysql_queries
|
||||
%%DATADIR%%/plugins/mysql_slowqueries
|
||||
%%DATADIR%%/plugins/mysql_threads
|
||||
%%DATADIR%%/plugins/named
|
||||
%%DATADIR%%/plugins/netopia
|
||||
%%DATADIR%%/plugins/netstat
|
||||
%%DATADIR%%/plugins/nginx_request
|
||||
%%DATADIR%%/plugins/nginx_status
|
||||
%%DATADIR%%/plugins/nomadix_users_
|
||||
%%DATADIR%%/plugins/ntp_
|
||||
%%DATADIR%%/plugins/ntp_kernel_err
|
||||
%%DATADIR%%/plugins/ntp_kernel_pll_freq
|
||||
%%DATADIR%%/plugins/ntp_kernel_pll_off
|
||||
%%DATADIR%%/plugins/ntp_offset
|
||||
%%DATADIR%%/plugins/ntp_states
|
||||
%%DATADIR%%/plugins/nut_misc
|
||||
%%DATADIR%%/plugins/nut_volts
|
||||
%%DATADIR%%/plugins/nutups_
|
||||
%%DATADIR%%/plugins/nvidia_
|
||||
%%DATADIR%%/plugins/open_files
|
||||
%%DATADIR%%/plugins/openvpn
|
||||
%%DATADIR%%/plugins/perdition
|
||||
%%DATADIR%%/plugins/ping_
|
||||
%%DATADIR%%/plugins/plugin.sh
|
||||
|
@ -78,21 +129,49 @@ sbin/munin-run
|
|||
%%DATADIR%%/plugins/postfix_mailqueue
|
||||
%%DATADIR%%/plugins/postfix_mailstats
|
||||
%%DATADIR%%/plugins/postfix_mailvolume
|
||||
%%DATADIR%%/plugins/postgres_bgwriter
|
||||
%%DATADIR%%/plugins/postgres_cache_
|
||||
%%DATADIR%%/plugins/postgres_checkpoints
|
||||
%%DATADIR%%/plugins/postgres_connections_
|
||||
%%DATADIR%%/plugins/postgres_connections_db
|
||||
%%DATADIR%%/plugins/postgres_locks_
|
||||
%%DATADIR%%/plugins/postgres_querylength_
|
||||
%%DATADIR%%/plugins/postgres_scans_
|
||||
%%DATADIR%%/plugins/postgres_size_
|
||||
%%DATADIR%%/plugins/postgres_transactions_
|
||||
%%DATADIR%%/plugins/postgres_tuples_
|
||||
%%DATADIR%%/plugins/postgres_users
|
||||
%%DATADIR%%/plugins/postgres_xlog
|
||||
%%DATADIR%%/plugins/processes
|
||||
%%DATADIR%%/plugins/ps_
|
||||
%%DATADIR%%/plugins/psu_
|
||||
%%DATADIR%%/plugins/qmailqstat
|
||||
%%DATADIR%%/plugins/qmailscan
|
||||
%%DATADIR%%/plugins/qmailscan-simple
|
||||
%%DATADIR%%/plugins/samba
|
||||
%%DATADIR%%/plugins/sendmail_mailqueue
|
||||
%%DATADIR%%/plugins/sendmail_mailstats
|
||||
%%DATADIR%%/plugins/sendmail_mailtraffic
|
||||
%%DATADIR%%/plugins/slapd_
|
||||
%%DATADIR%%/plugins/slapd_bdb_cache_
|
||||
%%DATADIR%%/plugins/slony_lag_
|
||||
%%DATADIR%%/plugins/smart_
|
||||
%%DATADIR%%/plugins/snmp__cpuload
|
||||
%%DATADIR%%/plugins/snmp__df
|
||||
%%DATADIR%%/plugins/snmp__fc_if_
|
||||
%%DATADIR%%/plugins/snmp__fc_if_err_
|
||||
%%DATADIR%%/plugins/snmp__if_
|
||||
%%DATADIR%%/plugins/snmp__if_err_
|
||||
%%DATADIR%%/plugins/snmp__if_multi
|
||||
%%DATADIR%%/plugins/snmp__load
|
||||
%%DATADIR%%/plugins/snmp__memory
|
||||
%%DATADIR%%/plugins/snmp__netapp_diskusage_
|
||||
%%DATADIR%%/plugins/snmp__netapp_inodeusage_
|
||||
%%DATADIR%%/plugins/snmp__netstat
|
||||
%%DATADIR%%/plugins/snmp__print_pages
|
||||
%%DATADIR%%/plugins/snmp__print_supplies
|
||||
%%DATADIR%%/plugins/snmp__processes
|
||||
%%DATADIR%%/plugins/snmp__rdp_users
|
||||
%%DATADIR%%/plugins/snmp__sensors_fsc_bx_fan
|
||||
%%DATADIR%%/plugins/snmp__sensors_fsc_bx_temp
|
||||
%%DATADIR%%/plugins/snmp__sensors_fsc_fan
|
||||
|
@ -100,48 +179,47 @@ sbin/munin-run
|
|||
%%DATADIR%%/plugins/snmp__sensors_mbm_fan
|
||||
%%DATADIR%%/plugins/snmp__sensors_mbm_temp
|
||||
%%DATADIR%%/plugins/snmp__sensors_mbm_volt
|
||||
%%DATADIR%%/plugins/snmp__swap
|
||||
%%DATADIR%%/plugins/snmp__uptime
|
||||
%%DATADIR%%/plugins/snmp__users
|
||||
%%DATADIR%%/plugins/snmp__winload
|
||||
%%DATADIR%%/plugins/snmp__winmem
|
||||
%%DATADIR%%/plugins/snort_alerts
|
||||
%%DATADIR%%/plugins/snort_bytes_pkt
|
||||
%%DATADIR%%/plugins/snort_drop_rate
|
||||
%%DATADIR%%/plugins/snort_pattern_match
|
||||
%%DATADIR%%/plugins/snort_pkts
|
||||
%%DATADIR%%/plugins/snort_traffic
|
||||
%%DATADIR%%/plugins/spamstats
|
||||
%%DATADIR%%/plugins/squeezebox_
|
||||
%%DATADIR%%/plugins/squid_cache
|
||||
%%DATADIR%%/plugins/squid_icp
|
||||
%%DATADIR%%/plugins/squid_objectsize
|
||||
%%DATADIR%%/plugins/squid_requests
|
||||
%%DATADIR%%/plugins/squid_traffic
|
||||
%%DATADIR%%/plugins/surfboard
|
||||
%%DATADIR%%/plugins/swap
|
||||
%%DATADIR%%/plugins/sybase_space
|
||||
%%DATADIR%%/plugins/systat
|
||||
%%DATADIR%%/plugins/tomcat_
|
||||
%%DATADIR%%/plugins/tomcat_access
|
||||
%%DATADIR%%/plugins/tomcat_jvm
|
||||
%%DATADIR%%/plugins/tomcat_threads
|
||||
%%DATADIR%%/plugins/tomcat_volume
|
||||
%%DATADIR%%/plugins/uptime
|
||||
%%DATADIR%%/plugins/users
|
||||
%%DATADIR%%/plugins/varnish_
|
||||
%%DATADIR%%/plugins/vmstat
|
||||
@unexec rm -f /var/run/munin/munin-node.pid
|
||||
@unexec rmdir /var/run/munin 2>/dev/null || true
|
||||
%%DATADIR%%/plugins/warning_tester
|
||||
%%DATADIR%%/plugins/zimbra_
|
||||
@dirrmtry var/munin/plugin-state
|
||||
@dirrmtry var/munin
|
||||
@dirrmtry %%DATADIR%%/plugins
|
||||
@dirrm %%DATADIR%%/plugins
|
||||
@dirrmtry %%DATADIR%%
|
||||
@dirrmtry %%SITE_PERL%%/Munin/Plugin
|
||||
@dirrm %%SITE_PERL%%/Munin/Plugin
|
||||
@dirrm %%SITE_PERL%%/Munin/Node/Configure
|
||||
@dirrm %%SITE_PERL%%/Munin/Node
|
||||
@dirrmtry %%SITE_PERL%%/Munin
|
||||
@dirrmtry etc/munin/plugin-conf.d
|
||||
@dirrmtry etc/munin/plugins
|
||||
@dirrmtry etc/munin/plugin-conf.d
|
||||
@dirrmtry etc/munin
|
||||
@unexec echo remove %%SITE_PERL%%/Munin/Plugin
|
||||
@unexec echo remove %%SITE_PERL%%/Munin
|
||||
@dirrmtry %%SITE_PERL%%/Munin/Plugin
|
||||
@dirrmtry %%SITE_PERL%%/Munin
|
||||
@unexec echo
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo "If you want to *completely* remove munin-node, you have to"
|
||||
@unexec echo
|
||||
@unexec echo " rm -rf %D/etc/munin/VERSION.node %D/etc/munin/plugins \\"
|
||||
@unexec if [ -d %D/var/munin/plugin-state ]; then echo " %D/var/munin/plugin-state \\"; fi
|
||||
@unexec if [ -f %D/etc/munin/munin-node.conf ]; then echo " %D/etc/munin/munin-node.conf \\"; fi
|
||||
@unexec if [ -d %D/var/munin/plugin-state ]; then echo " %D/var/munin/plugin-state \\"; fi
|
||||
@unexec if [ -d %%LOCALBASE%%/%%SITE_PERL%%/Munin/Plugin ]; then echo " %%LOCALBASE%%/%%SITE_PERL%%/Munin/Plugin \\"; fi
|
||||
@unexec if [ -d %%LOCALBASE%%/%%SITE_PERL%%/Munin ]; then echo " %%LOCALBASE%%/%%SITE_PERL%%/Munin/Plugin \\"; fi
|
||||
@unexec echo " /var/log/munin-node.log*"
|
||||
@unexec echo
|
||||
@unexec echo "If you have already deinstalled munin-main, you can also"
|
||||
@unexec echo
|
||||
@unexec echo " rmdir %D/etc/munin %D/var/munin"
|
||||
@unexec echo
|
||||
@unexec echo "These files and directories have to be left on the system because"
|
||||
@unexec echo "you may be performing an update. This process can't tell."
|
||||
@unexec echo '********************************************************************'
|
||||
@unexec echo
|
||||
|
|
Loading…
Add table
Reference in a new issue