Sophie

Sophie

distrib > CentOS > 5 > x86_64 > by-pkgid > 7ca84d00a753576dfaee15bac39038f0 > files > 315

mrtg-2.14.5-4.el5.x86_64.rpm

#!/bin/sh
##
## OUTPUT_FILE has to have the same path with WorkDir value setted in the make-mrtg.cfg.awk file
## MRTG_NETHOSTS_CFG has to be the same file declared in the make-mrtg.cfg.awk file
## MRTG_EXECUTABLE is the MRTG executable file with full path
## NETHOSTST_INTERNET_PATH is the path for internet IPs file (without / in the end) and has to be the same path declared in the make-mrtg.cfg.awk file
## NETHOSTST_AWK_FILE is the make-mrtg.cfg.awk file with full path
##
MRTG_EXECUTABLE="/usr/local/mrtg/mrtg"
NETHOSTST_INTERNET_PATH="/usr/local/mrtg/contrib/net-hosts"
NETHOSTST_AWK_FILE="/usr/local/mrtg/contrib/net-hosts/make-mrtg.cfg.awk"
##
##
/bin/cat $NETHOSTST_INTERNET_PATH/internet | /bin/awk -F: '{print $1}' | /usr/sbin/fping | /bin/awk -f $NETHOSTST_AWK_FILE
##
##
#####################################################################################################
## Index Maker in MRTG Style
############################
#
# OUTPUT_FILE="/usr/local/mrtg/contrib/net-hosts/1/index.html"
# MRTG_NETHOSTS_CFG="/usr/local/mrtg/contrib/net-hosts/mrtg-awk.cfg"
#
# /usr/local/mrtg/indexmaker -b "#ffffff" -1 -t 'Internet Nodes' -o $OUTPUT_FILE $MRTG_NETHOSTS_CFG
#
######################################################################################################