diff options
Diffstat (limited to 'network')
-rw-r--r-- | network/ntop/README | 14 | ||||
-rw-r--r-- | network/ntop/README.SLACKWARE | 16 | ||||
-rw-r--r-- | network/ntop/ntop-5.0.1-librrd.patch | 31 | ||||
-rw-r--r-- | network/ntop/ntop.SlackBuild | 12 | ||||
-rw-r--r-- | network/ntop/rc.ntop | 8 |
5 files changed, 59 insertions, 22 deletions
diff --git a/network/ntop/README b/network/ntop/README index 2e962ac451..2108bcb9bc 100644 --- a/network/ntop/README +++ b/network/ntop/README @@ -1,10 +1,10 @@ -ntop is a network probe that shows network usage in a way similar to -what top does for processes. In interactive mode, it displays the -network status on the user's terminal. In Web mode, it acts as a Web -server, creating an HTML dump of the network status. +ntop is a network probe that shows network usage in a way similar to +what top does for processes. In interactive mode, it displays the +network status on the user's terminal. In Web mode, it acts as a Web +server, creating an HTML dump of the network status. -It sports a NetFlow/sFlow emitter/collector, an HTTP-based client -interface for creating ntop-centric monitoring applications, and +It sports a NetFlow/sFlow emitter/collector, an HTTP-based client +interface for creating ntop-centric monitoring applications, and RRD for persistently storing traffic statistics. ntop needs to run under its own user/group. This has been assigned to @@ -20,5 +20,5 @@ log rotation will restart the ntop server which will reset the ntop statistics. If you want to keep the statistics you have to edit or delete the /etc/logrotate.d/ntop file. -For some important post-build and basic configuration instructions, +For some important post-build and basic configuration instructions, see the included 'README.SLACKWARE' file. diff --git a/network/ntop/README.SLACKWARE b/network/ntop/README.SLACKWARE index 66ce381786..e9c0595b29 100644 --- a/network/ntop/README.SLACKWARE +++ b/network/ntop/README.SLACKWARE @@ -36,7 +36,7 @@ If you want to start ntop on system bootup, include these lines in your /etc/rc.d/rc.ntop start fi -To guarantee a clean shutdown of ntop, include this in +To guarantee a clean shutdown of ntop, include this in /etc/rc.d/rc.local_shutdown: # Stop ntop @@ -47,7 +47,7 @@ To guarantee a clean shutdown of ntop, include this in 1.2) Make /etc/rc.d/rc.ntop executable -Additionally, you'll have to set the rc script to be executable just like +Additionally, you'll have to set the rc script to be executable just like any other Slackware rc script: # chmod +x /etc/rc.d/rc.ntop @@ -55,15 +55,15 @@ any other Slackware rc script: 2) Set the administrator password --------------------------------- -When ntop is installed at the first time, you MUST set the administration -password for ntop (user 'admin'). You do that by running ntop with the +When ntop is installed at the first time, you MUST set the administration +password for ntop (user 'admin'). You do that by running ntop with the option -A (or --set-admin-password) as root: # /usr/bin/ntop -P <ntop_homedirectory> -u <ntopuser> -A For example: # /usr/bin/ntop -P /var/lib/ntop -u ntop -A -It will prompt you for the password and then exit. +It will prompt you for the password and then exit. 3) Starting ntop ---------------- @@ -72,7 +72,7 @@ Now you are ready to start ntop by calling the startup script: # /etc/rc.d/rc.ntop start -Once ntop has started and configured correctly, you should be able to look +Once ntop has started and configured correctly, you should be able to look at all the data it's collected by pointing your browser at: http://(ip-of-your-ntop-server):3000/ @@ -110,7 +110,7 @@ My suggestions are: Don't forget to make the script executable. -The following scripts are examples for the GeoIP and OUI tables, feel free +The following scripts are examples for the GeoIP and OUI tables, feel free to adapt them to your reality. The "OS Fingerprint" table has not changed since 2005, so I did not @@ -176,7 +176,7 @@ for update in $UPDATES; do gzip -c ${update_file} > ${update_file}.gz fi done - + rm $UPDATE_OUT ============================================================================= diff --git a/network/ntop/ntop-5.0.1-librrd.patch b/network/ntop/ntop-5.0.1-librrd.patch new file mode 100644 index 0000000000..db2530c8a5 --- /dev/null +++ b/network/ntop/ntop-5.0.1-librrd.patch @@ -0,0 +1,31 @@ +--- a/configure.in ++++ b/configure.in +@@ -887,28 +887,6 @@ + fi + fi + +-RRD_LIB="-L${RRD_HOME}/lib -lrrd_th" +- +-if test -f "$RRD_HOME/lib/librrd_th.so"; then +- AC_MSG_RESULT(checking for rrdtool... yes) +-else +- if test -f "$RRD_HOME/lib/librrd_th.dylib"; then # OSX +- AC_MSG_RESULT(checking for rrdtool... yes) +- else +- if test -f "$RRD_HOME/lib/librrd_th.a"; then +- AC_MSG_RESULT(checking for rrdtool... yes) +- else +- AC_CHECK_LIB([rrd_th], [main]) +- if test ".${ac_cv_lib_rrd_th_main}" != ".yes"; then +- AC_MSG_ERROR(Unable to find RRD at $RRD_HOME: please use --with-rrd-home=DIR); +- AC_MSG_ERROR(RRD source can be downloaded from http://www.rrdtool.org/); +- else +- RRD_LIB= +- fi +- fi +- fi +-fi +- + RRD_INC= + if test -d "${RRD_HOME}/include"; then + RRD_INC="-I${RRD_HOME}/include" diff --git a/network/ntop/ntop.SlackBuild b/network/ntop/ntop.SlackBuild index 59f9055364..2e3de40b16 100644 --- a/network/ntop/ntop.SlackBuild +++ b/network/ntop/ntop.SlackBuild @@ -35,7 +35,7 @@ NTOPGROUP=${NTOPGROUP:-ntop} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -59,8 +59,8 @@ elif ! grep ^$NTOPUSER: /etc/passwd 2>&1 > /dev/null; then exit 1 fi -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" @@ -91,10 +91,15 @@ find -L . \ # Patch Makefile so we won't do automatic downloads patch -p1 < $CWD/no_downloads.patch +# Patch for rrdtool-1.6.0 (thanks to Gentoo) +patch -p1 < $CWD/ntop-5.0.1-librrd.patch + # Since ntop calls their ./configure from autogen.sh anything passed onto # autogen.sh (ie $@) is passed off as command line arguments to configure. CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ +RRD_LIB="-lrrd" \ +LOCALEDIR=/usr/lib${LIBDIRSUFFIX}/locale \ ./autogen.sh \ --prefix=/usr \ --sysconfdir=/etc \ @@ -102,6 +107,7 @@ CXXFLAGS="$SLKCFLAGS" \ --mandir=/usr/man \ --docdir=/usr/doc/$PRGNAM-$VERSION \ --libdir=/usr/lib${LIBDIRSUFFIX} \ + --with-rrd-home=/usr/lib${LIBDIRSUFFIX} \ --enable-snmp \ --build=$ARCH-slackware-linux make diff --git a/network/ntop/rc.ntop b/network/ntop/rc.ntop index 441d7dbe4f..2d29aac6c6 100644 --- a/network/ntop/rc.ntop +++ b/network/ntop/rc.ntop @@ -3,8 +3,8 @@ # /etc/rc.d/rc.ntop : start/stop/restart ntop # usage: ./rc.ntop { start | stop | restart } -# Thanks to andarius <andarius@errantnutron.com> for donating -# time and the various cleanups in the script and the start|stop|restart +# Thanks to andarius <andarius@errantnutron.com> for donating +# time and the various cleanups in the script and the start|stop|restart # functions. NTOPUID=@NTOPUSER@ @@ -43,7 +43,7 @@ ntop_start() { ntop_stop() { echo -n $"Stopping ntop ... " RETVAL=$? - if [ $RETVAL -eq 0 ]; then + if [ $RETVAL -eq 0 ]; then if [ -r /var/run/ntop.pid ]; then killall ntop # Give it some time to die gracefully @@ -60,7 +60,7 @@ ntop_stop() { echo "\nWARNING: ntop did not exit!" sleep 10 else - # Yes there are two spaces as this is the way ntop writes + # Yes there are two spaces as this is the way ntop writes # their logfiles. echo "$DATE EXIT: ntop stopped by user: $USER (UID: $EUID)" >> $NTOPLOG echo "Done" |