debian/0000755000000000000000000000000011770604064007173 5ustar debian/control0000644000000000000000000000153511770575354010613 0ustar Source: pmacct Section: net Priority: optional Maintainer: Jamie Wilkinson Build-Depends: debhelper (>= 7), zlib1g-dev, libpcap-dev, libpq-dev, libmysqlclient-dev, libsqlite3-dev, kfreebsd-kernel-headers[kfreebsd-any] Standards-Version: 3.8.3 Package: pmacct Architecture: any Depends: ${shlibs:Depends}, net-tools [linux-any] | freebsd-net-tools [kfreebsd-any], psmisc Description: promiscuous mode traffic accountant pmacct is a tool designed to gather traffic information (bytes and number of packets) by listening on a promiscuous interface or for Netflow data, which may facilitate billing, bandwidth management, traffic analysis, or creating usage graphs. . Data can be stored in memory and queried, displayed directly, or written to a database; storage methods are quite flexible and may aggregate totals or keep them separate. debian/pmacct.default0000644000000000000000000000064311715077244012016 0ustar # Defaults for pmacct initscript # sourced by /etc/init.d/pmacct # installed at /etc/default/pmacct by the maintainer scripts # # This is a POSIX shell fragment # # Location of the configuration file PMACCTD_CONF=/etc/pmacct/pmacctd.conf # List of interfaces to start accounting on. # See /usr/share/doc/pmacct/README.Debian for details. INTERFACES="" # Additional options that are passed to pmacctd DAEMON_OPTS="" debian/pmacct.nfacctd.init0000644000000000000000000000367611757357255012760 0ustar #!/bin/sh ### BEGIN INIT INFO # Provides: nfacct # Required-start: $network $syslog # Required-stop: $network $syslog # Default-start: 2 3 4 5 # Default-stop: 0 1 6 # Short-Description: netflow accounting daemon ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/nfacctd NAME=nfacctd DESC="netflow accounting daemon" CONFDIR=/etc/pmacct test -x $DAEMON || exit 0 # Include nfacct defaults if available if [ -f /etc/default/nfacctd ] ; then . /etc/default/nfacctd fi stop () { #start-stop-daemon --stop --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON killall -INT nfacctd } start () { #start-stop-daemon --start --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON -- -f $PMACCTD_CONF $DAEMON_OPTS if [ -n "$INTERFACES" ]; then for i in $INTERFACES; do ip link set $i up $DAEMON -f $CONFDIR/nfacctd.$i.conf $DAEMON_OPTS done else $DAEMON -f $CONFDIR/nfacctd.conf $DAEMON_OPTS fi } case "$1" in start) echo -n "Starting $DESC: " start echo "$NAME." ;; stop) echo -n "Stopping $DESC: " stop echo "$NAME." ;; #reload) # # If the daemon can reload its config files on the fly # for example by sending it SIGHUP, do it here. # # If the daemon responds to changes in its config file # directly anyway, make this a do-nothing entry. # # echo "Reloading $DESC configuration files." # start-stop-daemon --stop --signal 1 --quiet --pidfile \ # /var/run/$NAME.pid --exec $DAEMON #;; restart|force-reload) # # If the "reload" option is implemented, move the "force-reload" # option to the "reload" entry above. If not, "force-reload" is # just the same as "restart". # echo -n "Restarting $DESC: " stop sleep 1 start echo "$NAME." ;; *) N=/etc/init.d/$NAME # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 echo "Usage: $N {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0 debian/pmacct.nfacctd.default0000644000000000000000000000064311716400762013413 0ustar # Defaults for nfacct initscript # sourced by /etc/init.d/nfacct # installed at /etc/default/sfacct by the maintainer scripts # # This is a POSIX shell fragment # # Location of the configuration file NFACCTD_CONF=/etc/pmacct/nfacctd.conf # List of interfaces to start accounting on. # See /usr/share/doc/pmacct/README.Debian for details. INTERFACES="" # Additional options that are passed to nfacctd DAEMON_OPTS="" debian/pmacct.manpages0000644000000000000000000000002011715101771012143 0ustar debian/pmacct.1 debian/pmacct.sfacctd.init0000644000000000000000000000367211757357255012761 0ustar #!/bin/sh ### BEGIN INIT INFO # Provides: sfacct # Required-start: $network $syslog # Required-stop: $network $syslog # Default-start: 2 3 4 5 # Default-stop: 0 1 6 # Short-Description: sflow accounting daemon ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/sfacctd NAME=sfacctd DESC="sflow accounting daemon" CONFDIR=/etc/pmacct test -x $DAEMON || exit 0 # Include sfacct defaults if available if [ -f /etc/default/sfacctd ] ; then . /etc/default/sfacctd fi stop () { #start-stop-daemon --stop --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON killall -INT sfacctd } start () { #start-stop-daemon --start --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON -- -f $PMACCTD_CONF $DAEMON_OPTS if [ -n "$INTERFACES" ]; then for i in $INTERFACES; do ip link set $i up $DAEMON -f $CONFDIR/sfacctd.$i.conf $DAEMON_OPTS done else $DAEMON -f $CONFDIR/sfacctd.conf $DAEMON_OPTS fi } case "$1" in start) echo -n "Starting $DESC: " start echo "$NAME." ;; stop) echo -n "Stopping $DESC: " stop echo "$NAME." ;; #reload) # # If the daemon can reload its config files on the fly # for example by sending it SIGHUP, do it here. # # If the daemon responds to changes in its config file # directly anyway, make this a do-nothing entry. # # echo "Reloading $DESC configuration files." # start-stop-daemon --stop --signal 1 --quiet --pidfile \ # /var/run/$NAME.pid --exec $DAEMON #;; restart|force-reload) # # If the "reload" option is implemented, move the "force-reload" # option to the "reload" entry above. If not, "force-reload" is # just the same as "restart". # echo -n "Restarting $DESC: " stop sleep 1 start echo "$NAME." ;; *) N=/etc/init.d/$NAME # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 echo "Usage: $N {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0 debian/pmacct.init0000644000000000000000000000371311757357255011347 0ustar #!/bin/sh ### BEGIN INIT INFO # Provides: pmacct # Required-start: $network $syslog # Required-stop: $network $syslog # Default-start: 2 3 4 5 # Default-stop: 0 1 6 # Short-Description: promiscuous mode accounting daemon ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/pmacctd NAME=pmacctd DESC="promiscuous mode accounting daemon" CONFDIR=/etc/pmacct test -x $DAEMON || exit 0 # Include pmacct defaults if available if [ -f /etc/default/pmacct ] ; then . /etc/default/pmacct fi stop () { #start-stop-daemon --stop --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON killall -INT pmacctd } start () { #start-stop-daemon --start --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON -- -f $PMACCTD_CONF $DAEMON_OPTS if [ -n "$INTERFACES" ]; then for i in $INTERFACES; do ifconfig $i up $DAEMON -f $CONFDIR/pmacctd.$i.conf $DAEMON_OPTS done else $DAEMON -f $CONFDIR/pmacctd.conf $DAEMON_OPTS fi } case "$1" in start) echo -n "Starting $DESC: " start echo "$NAME." ;; stop) echo -n "Stopping $DESC: " stop echo "$NAME." ;; #reload) # # If the daemon can reload its config files on the fly # for example by sending it SIGHUP, do it here. # # If the daemon responds to changes in its config file # directly anyway, make this a do-nothing entry. # # echo "Reloading $DESC configuration files." # start-stop-daemon --stop --signal 1 --quiet --pidfile \ # /var/run/$NAME.pid --exec $DAEMON #;; restart|force-reload) # # If the "reload" option is implemented, move the "force-reload" # option to the "reload" entry above. If not, "force-reload" is # just the same as "restart". # echo -n "Restarting $DESC: " stop sleep 1 start echo "$NAME." ;; *) N=/etc/init.d/$NAME # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 echo "Usage: $N {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0 debian/changelog0000644000000000000000000002556511770604001011051 0ustar pmacct (0.14.0-1.1) unstable; urgency=low * Non-maintainer upload. * Added patch to handle AF_LINK on hurd and kfreebsd platforms (Closes: #675836) -- Nicholas Bamber Thu, 21 Jun 2012 12:39:40 +0100 pmacct (0.14.0-1) unstable; urgency=low * New upstream release * Revert stop function to use SIGINT, properly. (Closes: #659975) -- Jamie Wilkinson Thu, 24 May 2012 07:10:17 +0000 pmacct (0.12.5-4) unstable; urgency=low * Revert initscripts stop command to use SIGINT instead of SIGTERM. as part of #659710. -- Jamie Wilkinson Tue, 14 Feb 2012 07:16:03 +0000 pmacct (0.12.5-3) unstable; urgency=low * Add initscripts for nfacctd, sfacctd and uacctd. (Closes: #503285, #659710) * Rename the pmacct initscript and default to "pmacctd". * Fix permissions on config files to not be world readable. (Closes: #579535) -- Jamie Wilkinson Tue, 14 Feb 2012 07:01:36 +0000 pmacct (0.12.5-2) unstable; urgency=low * Build a 64bit binary and enable threads. (Closes: #659711) -- Jamie Wilkinson Tue, 14 Feb 2012 02:10:03 +0000 pmacct (0.12.5-1) unstable; urgency=low * New upstream release. * Set extend-diff-ignore in debian/source/options to ignore changeable files. (Closes: #643250) * Fix FTBFS on kFreeBSD. Thanks Robert Millan! (Closes: #647661, #617570) * Build-depend on the lastest libmysqlclient-dev. Thanks Clint Byrum! (Closes: #652136) * Depend on psmisc so that stopping the daemon works. (Closes: #571548) * Include manpage for pmacct. Thanks Mats Erik Andersson! (Closes: #617558) -- Jamie Wilkinson Fri, 10 Feb 2012 02:34:49 +0000 pmacct (0.12.1-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Thu, 08 Apr 2010 20:29:51 +1000 pmacct (0.12.0-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Wed, 24 Feb 2010 22:22:43 +1100 pmacct (0.11.6-2) unstable; urgency=low * Updated standards version to 3.8.3. * Fixed path to GPLv2 in debian/copyright. * Bumped debian/compat to 7. - Replace dh_clean -k with dh_prep. - Add versioned depends on debhelper 7. -- Jamie Wilkinson Mon, 19 Oct 2009 17:34:36 +1100 pmacct (0.11.6-1) unstable; urgency=low * New upstream version. * Stop linking against libz and libm explicitly. * Compile with IPv6 support. (Closes: #474175) -- Jamie Wilkinson Sun, 18 Oct 2009 15:16:07 +1100 pmacct (0.11.5-1) unstable; urgency=low * New upstream version. (Closes: #543440) -- Jamie Wilkinson Sat, 12 Sep 2009 15:00:08 +1000 pmacct (0.11.4-1) unstable; urgency=low * New upstream version. (Closes: #407320) * Bug fix: "pmacct: Please remove postgresql-dev from your build-depends as it doesn't exist in the archive", thanks to Lior Kaplan (Closes: #429975). * Bug fix: "pmacct is missing dependency for iproute package", thanks to f.arthofer@lagis.at (Closes: #423032). * Added lsb section to initscript. * Don't ignore errors from make clean. * Updated standards version to 3.7.2 -- Jamie Wilkinson Sat, 17 Nov 2007 12:46:13 +1100 pmacct (0.11.3-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:30:27 +1100 pmacct (0.11.2-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:29:58 +1100 pmacct (0.11.1-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:29:12 +1100 pmacct (0.11.0-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:28:41 +1100 pmacct (0.10.3-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:28:09 +1100 pmacct (0.10.2-1) unstable; urgency=low * New upstream version. -- Jamie Wilkinson Sat, 17 Nov 2007 12:27:35 +1100 pmacct (0.10.1-2) unstable; urgency=low * Fix regex in watch file to only match pmacct tarball. -- Jamie Wilkinson Sat, 17 Nov 2007 12:23:44 +1100 pmacct (0.10.1-1) unstable; urgency=low * New upstream release. * Update copyright to point to new upstream homepage. * Update watch file to point to new download location. -- Jamie Wilkinson Wed, 19 Apr 2006 13:53:16 +1000 pmacct (0.10.0-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 4 Apr 2006 12:13:24 +1000 pmacct (0.9.6-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 4 Apr 2006 12:04:05 +1000 pmacct (0.9.5-1) unstable; urgency=low * New upstream release. * Added build dependency on libsqlite3-dev for the new SQLite backend. -- Jamie Wilkinson Tue, 4 Apr 2006 12:01:52 +1000 pmacct (0.9.4-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 4 Apr 2006 11:58:37 +1000 pmacct (0.9.3-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 4 Apr 2006 11:55:41 +1000 pmacct (0.9.2-1) unstable; urgency=low * New upstream release. * Acknowledge NMU. Thanks Matej. (Closes: #343796) * Dump the config.log if configure blows up. * Bumped standards version to 3.6.2 (no other changes made). * Updated FSF address in copyright to appease my cruel mistress lintian. -- Jamie Wilkinson Tue, 4 Apr 2006 11:51:08 +1000 pmacct (0.9.1-1.1) unstable; urgency=medium * Non-maintainer upload. * Build against libmysqlclient15-dev. Closes: #343796. -- Matej Vela Tue, 21 Feb 2006 07:33:15 +0100 pmacct (0.9.1-1) unstable; urgency=low * New upstream release. * Change mysql client library dependency to libmysqlclient12-dev. * Change postgresql library dependency for postgresql transition. * Alter configure script to use pg_config to find postgresql include files. -- Jamie Wilkinson Wed, 17 Aug 2005 18:01:52 +1000 pmacct (0.9.0-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Wed, 17 Aug 2005 17:34:42 +1000 pmacct (0.8.8-1) unstable; urgency=low * New upstream release. * Fix path to postgresql headers. -- Jamie Wilkinson Tue, 28 Jun 2005 13:38:16 +1000 pmacct (0.8.7-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 28 Jun 2005 13:34:12 +1000 pmacct (0.8.6-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 28 Jun 2005 13:30:23 +1000 pmacct (0.8.5-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 28 Jun 2005 13:26:14 +1000 pmacct (0.8.4-1) unstable; urgency=low * New upstream release. * Added UPGRADE to docs. -- Jamie Wilkinson Sun, 24 Apr 2005 12:43:26 +1000 pmacct (0.8.3-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 16:38:51 +1000 pmacct (0.8.2-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 16:35:36 +1000 pmacct (0.8.1-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 16:26:25 +1000 pmacct (0.8.0-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 15:16:15 +1000 pmacct (0.7.9-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 15:13:35 +1000 pmacct (0.7.8-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 15:07:51 +1000 pmacct (0.7.7-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 14:58:38 +1000 pmacct (0.7.6-1) unstable; urgency=low * New upstream release. (Closes: #280107) -- Jamie Wilkinson Sat, 16 Apr 2005 14:42:02 +1000 pmacct (0.7.5-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sat, 16 Apr 2005 14:27:42 +1000 pmacct (0.7.4-2) unstable; urgency=low * Support multiple interfaces by allowing multiple pmacctd daemons to run, as specified by /etc/default/pmacct. -- Jamie Wilkinson Tue, 5 Oct 2004 15:42:41 +1000 pmacct (0.7.4-1) unstable; urgency=low * New upstream release. (Closes: #274378) -- Jamie Wilkinson Tue, 5 Oct 2004 14:17:28 +1000 pmacct (0.7.3-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Tue, 5 Oct 2004 13:15:26 +1000 pmacct (0.7.2p1-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Thu, 12 Aug 2004 16:38:23 +1000 pmacct (0.7.2-1) unstable; urgency=low * New upstream release. - VLAN accounting. - Distributed accounting support. * Ensure configure and Makefile.in aren't rebuilt by retouching them just before configure stage (as date stamps from checkouts are not guaranteed). * Updated description to mention Netflow support. * Added watch file from DEHS. -- Jamie Wilkinson Thu, 12 Aug 2004 15:47:25 +1000 pmacct (0.7.1-1) unstable; urgency=low * New upstream release. - Shared memory support built by default. -- Jamie Wilkinson Thu, 12 Aug 2004 14:53:34 +1000 pmacct (0.7.0-1) unstable; urgency=low * New upstream release. - Enhanced IP fragmentation handling. - Adds Netflow capture support (nfacctd daemon). - PostgreSQL deadlock fix. -- Jamie Wilkinson Thu, 12 Aug 2004 12:22:43 +1000 pmacct (0.6.4-1) unstable; urgency=low * New upstream release. - Improved performance when talking to databases. (Closes: #258270) - Removed transaction patch (implemented upstream). -- Jamie Wilkinson Thu, 12 Aug 2004 11:41:50 +1000 pmacct (0.6.3-1) unstable; urgency=low * New upstream release. - Fixes segfault in pmpgplay binary. * Added mysql support to the package. * Added sql example scripts. (Closes: #244235) -- Jamie Wilkinson Wed, 5 May 2004 14:35:04 +1000 pmacct (0.6.2-2) unstable; urgency=low * Added FAQS and CONFIG-KEYS to the documentation. * Adjusted init script to send SIGINT to all pmacctd processes as per SIGNALS documentation. * Sped up the pgsql plugin by moving the transaction begin/end block outside of the inner loop. -- Jamie Wilkinson Fri, 30 Apr 2004 15:35:36 +1000 pmacct (0.6.2-1) unstable; urgency=low * New upstream release. -- Jamie Wilkinson Sun, 18 Apr 2004 12:32:23 +1000 pmacct (0.6.0-1) unstable; urgency=low * Initial Release. (Closes: #241444) -- Jamie Wilkinson Wed, 24 Mar 2004 13:52:03 +1100 debian/dirs0000644000000000000000000000005311715077244010060 0ustar usr/bin usr/sbin etc/pmacct var/lib/pmacct debian/pmpgplay.80000644000000000000000000000351511715077244011124 0ustar .\" Hey, EMACS: -*- nroff -*- .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) .TH PMACCT SECTION "March 24, 2004" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: .\" .nh disable hyphenation .\" .hy enable hyphenation .\" .ad l left justify .\" .ad b justify to both left and right margins .\" .nf disable filling .\" .fi enable filling .\" .br insert line break .\" .sp insert n+1 empty lines .\" for manpage-specific macros, see man(7) .SH NAME pmacct \- program to do something .SH SYNOPSIS .B pmacct .RI [ options ] " files" ... .br .B bar .RI [ options ] " files" ... .SH DESCRIPTION This manual page documents briefly the .B pmacct and .B bar commands. This manual page was written for the Debian distribution because the original program does not have a manual page. Instead, it has documentation in the GNU Info format; see below. .PP .\" TeX users may be more comfortable with the \fB\fP and .\" \fI\fP escape sequences to invode bold face and italics, .\" respectively. \fBpmacct\fP is a program that... .SH OPTIONS These programs follow the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. For a complete description, see the Info files. .TP .B \-h, \-\-help Show summary of options. .TP .B \-v, \-\-version Show version of program. .SH SEE ALSO .BR bar (1), .BR baz (1). .br The programs are documented fully by .IR "The Rise and Fall of a Fooish Bar" , available via the Info system. .SH AUTHOR This manual page was written by jaq , for the Debian project (but may be used by others). debian/compat0000644000000000000000000000000211715077244010374 0ustar 7 debian/pmacct.10000644000000000000000000000743511715101243010523 0ustar .\" Initial compilation manufacture around midnight .\" at the end of March 10th, 2011. .TH "pmacct" "1" "March 2011" "0.12.1" "pmacct" .SH NAME pmacct \- frontend to pmacctd. .SH SYNOPSIS .B pmacct \fIquery\fR .SH DESCRIPTION .B pmacct is a frontend to .BR pmacctd (8) when used in volatile memory mode. .PP The type of query is specified using options. At least one of the options \fB\-C\fR, \fB\-c\fR, \fB\-e\fR, \fB\-s\fR, or \fB\-t\fR is mandatory, but with \fB\-c\fR either of \fB\-M\fR or \fB\-N\fR must be used for further specification. .SH OPTIONS For displaying data either of these options are used: .TP \fB\-s\fR Show full statistics. .TP \fB\-c \fI aggregate\fR Specify primitives in a match aggregation, in order to present partial statistics. Either \fB\-M\fR or \fB\-N\fR must be used to specify matching data for this option. Here \fI aggregate\fR is a comma separated string constructed from the following identifiers, in arbitrary order: src_mac, dst_mac, vlan, src_host, dst_host, src_net, dst_net, src_mask, dst_mask, src_port, dst_port, tos, proto, src_as, dst_as, sum_mac, sum_host, sum_net, sum_as, sum_port, in_iface, out_iface, tag, tag2, flows, class, std_comm, ext_comm, as_path, peer_src_ip, peer_dst_ip, peer_src_as, peer_dst_as, src_as_path, src_std_comm, src_med, src_ext_comm, src_local_pref, is_symmetric. Only entries which match the aggregate are printed. .PP Management of the server daemon is offered by three options: .TP \fB\-e\fR Clear all statistics. For a partial clear, see \fB\-r\fR. .TP \fB\-t\fR Show memory table status. .TP \fB\-C\fR Show a table of all active classifiers. .SH MODIFIERS The primary options above can be influenced by some secondary options: .TP \fB\-p \fR \fI file\fR Unix socket location for client\-server communication. Default is \fI/tmp/collect.pipe\fR. .TP \fB\-a\fR Display all table fields, even currently unused fields. .TP \fB\-S\fR Calculate a summed total of all counters, instead of returning a counter for each individual match; applies to \fB\-N\fR. .TP \fB\-n\fR {bytes|packets|flows|all} Select which counters to print. This applies only to \fB\-N\fR. .TP \fB\-T\fR {bytes|packets|flows} Output statistics ordered by decreasing value of the indicated field. This option applies to \fB\-M\fR and to \fB\-s\fR. .TP \fB\-r\fR Reset counters in the present selection after printing their values. The option applies only to \fB\-M\fR and to \fB\-N\fR. .TP \fB\-l\fR Perform a locking on the table. .TP \fB\-M\fR {\fImatch_data\fR | file:\fIfilename\fR} Print a formatted table for all entries matching the given data. An aggregation must be specified using \fB\-c\fR, and the field order given there must be observed when stating the data here. The output can be influenced using \fB\-T\fR. .IP Here \fImatch_data\fR is a number of substrings separated by semicolon, each substring being a comma separated list of acceptable values in a match aggregation. A wildcard \'*\' can be used to match any value in a specific field. .IP As an alternative, a location \fIfilename\fR of a file can be specified. This file provides the substrings mentioned above as separate lines. The prefix \'file:\' is a verbatim marker. .TP \fB\-N \fI {\fImatch_data\fR | file:\fIfilename\fT} Print counters only, no text fields, header, or footer. This presupposes \fB\-c\fR, and can be influenced by \fB\-n\fR and \fB\-S\fR. The arguments are identical to those for \fB\-M\fR. .SH EXAMPLES The file .I /usr/share/doc/pmacct/EXAMPLES.gz contains suggestions prepared by the upstream author. .PP For suggestions, critisism, and bugs, get in contact with Paolo Lucente . .SH "SEE ALSO" .BR pmacctd (8) .SH AUTHOR This text was originally compiled by Mats Erik Andersson for the Debian project, but may be distributed for other uses under the same licensing as the software itself. debian/README.Debian0000644000000000000000000000103611715077244011237 0ustar README for Debian's pmacct ========================== Accounting on Multiple Interfaces --------------------------------- Debian's pmacct initscript supports multiple interfaces. Specify each interface you want to listen on, in the shell variable INTERFACES in /etc/default/pmacct . Create a configuration file for each interface in /etc/pmacct like so: /etc/pmacct/pmacct.eth1.conf for listening on eth1 /etc/pmacct/pmacct.eth2.conf for listening on eth2 and so on. Make sure each configuration file specifies the correct interface. debian/patches/0000755000000000000000000000000011770576544010635 5ustar debian/patches/af_link.patch0000644000000000000000000000172411770576544013265 0ustar Author: Nicholas Bamber Subject: Problems with the sockaddr_dl structure The first issue is that on kfreebsd platforms, where AF_LINK is legitimately defined, the definition of sockaddr_dl is in net/if_dl.h which the upstream source does not #include. The second issue is that Hurd also defines AF_LINK but does not actually implement that functionality - #678358. Bug #678375 was raised to clear this up when it is sorted out in Hurd. Bug-Debian: http://bugs.debian.org/675836 Last-Update: 2012-06-21 --- a/src/isis/sockunion.c +++ b/src/isis/sockunion.c @@ -27,6 +27,18 @@ #include "prefix.h" #include "sockunion.h" +/* As per #678358, Hurd defines AF_LINK but does not + * provide the functionality. When that bug is fixed + * These three lines could be removed and #678375 closed. + */ +#ifdef __GNU__ +#undef AF_LINK +#endif + +#ifdef AF_LINK +#include +#endif + const char * inet_sutop (union sockunion *su, char *str) { debian/patches/series0000644000000000000000000000001611770573746012050 0ustar af_link.patch debian/pmacct.sfacctd.default0000644000000000000000000000064311716400762013420 0ustar # Defaults for sfacct initscript # sourced by /etc/init.d/sfacct # installed at /etc/default/sfacct by the maintainer scripts # # This is a POSIX shell fragment # # Location of the configuration file SFACCTD_CONF=/etc/pmacct/sfacctd.conf # List of interfaces to start accounting on. # See /usr/share/doc/pmacct/README.Debian for details. INTERFACES="" # Additional options that are passed to sfacctd DAEMON_OPTS="" debian/pmacct.uacctd.default0000644000000000000000000000063411716403254013253 0ustar # Defaults for uacct initscript # sourced by /etc/init.d/uacct # installed at /etc/default/uacct by the maintainer scripts # # This is a POSIX shell fragment # # Location of the configuration file PMACCTD_CONF=/etc/uacct/uacctd.conf # List of interfaces to start accounting on. # See /usr/share/doc/uacct/README.Debian for details. INTERFACES="" # Additional options that are passed to uacctd DAEMON_OPTS="" debian/pmacct.80000644000000000000000000000351511715077244010542 0ustar .\" Hey, EMACS: -*- nroff -*- .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) .TH PMACCT SECTION "March 24, 2004" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: .\" .nh disable hyphenation .\" .hy enable hyphenation .\" .ad l left justify .\" .ad b justify to both left and right margins .\" .nf disable filling .\" .fi enable filling .\" .br insert line break .\" .sp insert n+1 empty lines .\" for manpage-specific macros, see man(7) .SH NAME pmacct \- program to do something .SH SYNOPSIS .B pmacct .RI [ options ] " files" ... .br .B bar .RI [ options ] " files" ... .SH DESCRIPTION This manual page documents briefly the .B pmacct and .B bar commands. This manual page was written for the Debian distribution because the original program does not have a manual page. Instead, it has documentation in the GNU Info format; see below. .PP .\" TeX users may be more comfortable with the \fB\fP and .\" \fI\fP escape sequences to invode bold face and italics, .\" respectively. \fBpmacct\fP is a program that... .SH OPTIONS These programs follow the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. For a complete description, see the Info files. .TP .B \-h, \-\-help Show summary of options. .TP .B \-v, \-\-version Show version of program. .SH SEE ALSO .BR bar (1), .BR baz (1). .br The programs are documented fully by .IR "The Rise and Fall of a Fooish Bar" , available via the Info system. .SH AUTHOR This manual page was written by jaq , for the Debian project (but may be used by others). debian/rules0000755000000000000000000000527411716404213010255 0ustar #!/usr/bin/make -f # -*- makefile -*- # Sample debian/rules that uses debhelper. # GNU copyright 1997 to 1999 by Joey Hess. # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # These are used for cross-compiling and for saving the configure script # from having to guess our platform (since we know it already) DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) CFLAGS = -Wall -g ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else CFLAGS += -O2 endif ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) INSTALL_PROGRAM += -s endif config.status: configure dh_testdir touch Makefile.in configure aclocal.m4 CFLAGS="$(CFLAGS)" ./configure \ --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info \ --enable-mmap \ --enable-pgsql \ --with-pgsql-includes=`pg_config --includedir` \ --enable-mysql \ --enable-sqlite3 \ --enable-ipv6 \ --enable-64bit \ --enable-threads \ || cat config.log build: build-stamp build-stamp: config.status dh_testdir $(MAKE) touch build-stamp clean: dh_testdir dh_testroot rm -f build-stamp [ ! -f Makefile ] || $(MAKE) distclean ifneq "$(wildcard /usr/share/misc/config.sub)" "" cp -f /usr/share/misc/config.sub config.sub endif ifneq "$(wildcard /usr/share/misc/config.guess)" "" cp -f /usr/share/misc/config.guess config.guess endif dh_clean install: build dh_testdir dh_testroot dh_prep dh_installdirs $(MAKE) install DESTDIR=$(CURDIR)/debian/pmacct install -m 0600 debian/pmacctd.conf $(CURDIR)/debian/pmacct/etc/pmacct/pmacctd.conf install -m 0600 debian/sfacctd.conf $(CURDIR)/debian/pmacct/etc/pmacct/sfacctd.conf install -m 0600 debian/nfacctd.conf $(CURDIR)/debian/pmacct/etc/pmacct/nfacctd.conf # Build architecture-independent files here. binary-indep: build install # We have nothing to do by default. # Build architecture-dependent files here. binary-arch: build install dh_testdir dh_testroot dh_installchangelogs ChangeLog dh_installdocs -X.arch dh_installexamples # dh_install # dh_installmenu # dh_installdebconf # dh_installlogrotate # dh_installemacsen # dh_installpam # dh_installmime dh_installinit dh_installinit --name nfacctd --no-start dh_installinit --name sfacctd --no-start dh_installinit --name uacctd --no-start # dh_installcron # dh_installinfo dh_installman dh_link dh_strip dh_compress dh_fixperms # dh_perl # dh_python # dh_makeshlibs dh_installdeb dh_shlibdeps dh_gencontrol dh_md5sums dh_builddeb binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install debian/copyright0000644000000000000000000000213111715077244011126 0ustar This package was debianized by Jamie Wilkinson on Wed, 24 Mar 2004 13:52:03 +1100. It was downloaded from http://www.pmacct.net/ Upstream Author: Paolo Lucente Copyright (C) 2004 Paolo Lucente. License: pmacct is licensed under the terms of the GNU General Public License. This package is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 dated June, 1991. This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. On Debian systems, the complete text of the GNU General Public License can be found in `/usr/share/common-licenses/GPL-2'. debian/source/0000755000000000000000000000000011715077450010475 5ustar debian/source/format0000644000000000000000000000001411715077450011703 0ustar 3.0 (quilt) debian/source/options0000644000000000000000000000020011715077326012105 0ustar # Don't store changes on autogenerated files. extend-diff-ignore = "(^|/)(config\.sub|config\.guess|Makefile|configure(\.in)?)" debian/pmacctd.conf0000644000000000000000000000126011716401005011442 0ustar ! pmacctd configuration ! ! ! daemonize: true pidfile: /var/run/pmacctd.pid syslog: daemon ! ! interested in in and outbound traffic aggregate: src_host,dst_host ! on this network pcap_filter: net 127.0.0.0/8 ! on this interface interface: lo ! ! storage methods !plugins: pgsql !sql_host: localhost !sql_passwd: ! refresh the db every minute !sql_refresh_time: 60 ! reduce the size of the insert/update clause !sql_optimize_clauses: true ! accumulate values in each row for up to an hour !sql_history: 1h ! create new rows on the minute, hour, day boundaries !sql_history_roundoff: mhd ! in case of emergency, log to this file !sql_recovery_logfile: /var/lib/pmacct/pmacctd_recovery_log debian/sfacctd.conf0000644000000000000000000000126011716401005011436 0ustar ! sfacctd configuration ! ! ! daemonize: true pidfile: /var/run/sfacctd.pid syslog: daemon ! ! interested in in and outbound traffic aggregate: src_host,dst_host ! on this network pcap_filter: net 127.0.0.0/8 ! on this interface interface: lo ! ! storage methods !plugins: pgsql !sql_host: localhost !sql_passwd: ! refresh the db every minute !sql_refresh_time: 60 ! reduce the size of the insert/update clause !sql_optimize_clauses: true ! accumulate values in each row for up to an hour !sql_history: 1h ! create new rows on the minute, hour, day boundaries !sql_history_roundoff: mhd ! in case of emergency, log to this file !sql_recovery_logfile: /var/lib/pmacct/sfacctd_recovery_log debian/watch0000644000000000000000000000007111715077244010225 0ustar version=3 http://www.pmacct.net/pmacct-([\d.]+)\.tar\.gz debian/pmacct.uacctd.init0000644000000000000000000000370311757357255012610 0ustar #!/bin/sh ### BEGIN INIT INFO # Provides: uacct # Required-start: $network $syslog # Required-stop: $network $syslog # Default-start: 2 3 4 5 # Default-stop: 0 1 6 # Short-Description: promiscuous mode accounting daemon ### END INIT INFO PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/uacctd NAME=uacctd DESC="promiscuous mode accounting daemon" CONFDIR=/etc/uacct test -x $DAEMON || exit 0 # Include uacct defaults if available if [ -f /etc/default/uacctd ] ; then . /etc/default/uacctd fi stop () { #start-stop-daemon --stop --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON killall -INT uacctd } start () { #start-stop-daemon --start --oknodo --quiet \ # --pidfile /var/run/$NAME.pid \ # --exec $DAEMON -- -f $PMACCTD_CONF $DAEMON_OPTS if [ -n "$INTERFACES" ]; then for i in $INTERFACES; do ifconfig $i up $DAEMON -f $CONFDIR/uacctd.$i.conf $DAEMON_OPTS done else $DAEMON -f $CONFDIR/uacctd.conf $DAEMON_OPTS fi } case "$1" in start) echo -n "Starting $DESC: " start echo "$NAME." ;; stop) echo -n "Stopping $DESC: " stop echo "$NAME." ;; #reload) # # If the daemon can reload its config files on the fly # for example by sending it SIGHUP, do it here. # # If the daemon responds to changes in its config file # directly anyway, make this a do-nothing entry. # # echo "Reloading $DESC configuration files." # start-stop-daemon --stop --signal 1 --quiet --pidfile \ # /var/run/$NAME.pid --exec $DAEMON #;; restart|force-reload) # # If the "reload" option is implemented, move the "force-reload" # option to the "reload" entry above. If not, "force-reload" is # just the same as "restart". # echo -n "Restarting $DESC: " stop sleep 1 start echo "$NAME." ;; *) N=/etc/init.d/$NAME # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 echo "Usage: $N {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0 debian/nfacctd.conf0000644000000000000000000000126011716401005011431 0ustar ! nfacctd configuration ! ! ! daemonize: true pidfile: /var/run/nfacctd.pid syslog: daemon ! ! interested in in and outbound traffic aggregate: src_host,dst_host ! on this network pcap_filter: net 127.0.0.0/8 ! on this interface interface: lo ! ! storage methods !plugins: pgsql !sql_host: localhost !sql_passwd: ! refresh the db every minute !sql_refresh_time: 60 ! reduce the size of the insert/update clause !sql_optimize_clauses: true ! accumulate values in each row for up to an hour !sql_history: 1h ! create new rows on the minute, hour, day boundaries !sql_history_roundoff: mhd ! in case of emergency, log to this file !sql_recovery_logfile: /var/lib/pmacct/nfacctd_recovery_log debian/docs0000644000000000000000000000015411715077244010051 0ustar README TODO docs/INTERNALS EXAMPLES KNOWN-BUGS docs/PLUGINS docs/SIGNALS TOOLS CONFIG-KEYS FAQS sql UPGRADE debian/pmacctd.80000644000000000000000000000351511715077244010706 0ustar .\" Hey, EMACS: -*- nroff -*- .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) .TH PMACCT SECTION "March 24, 2004" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: .\" .nh disable hyphenation .\" .hy enable hyphenation .\" .ad l left justify .\" .ad b justify to both left and right margins .\" .nf disable filling .\" .fi enable filling .\" .br insert line break .\" .sp insert n+1 empty lines .\" for manpage-specific macros, see man(7) .SH NAME pmacct \- program to do something .SH SYNOPSIS .B pmacct .RI [ options ] " files" ... .br .B bar .RI [ options ] " files" ... .SH DESCRIPTION This manual page documents briefly the .B pmacct and .B bar commands. This manual page was written for the Debian distribution because the original program does not have a manual page. Instead, it has documentation in the GNU Info format; see below. .PP .\" TeX users may be more comfortable with the \fB\fP and .\" \fI\fP escape sequences to invode bold face and italics, .\" respectively. \fBpmacct\fP is a program that... .SH OPTIONS These programs follow the usual GNU command line syntax, with long options starting with two dashes (`-'). A summary of options is included below. For a complete description, see the Info files. .TP .B \-h, \-\-help Show summary of options. .TP .B \-v, \-\-version Show version of program. .SH SEE ALSO .BR bar (1), .BR baz (1). .br The programs are documented fully by .IR "The Rise and Fall of a Fooish Bar" , available via the Info system. .SH AUTHOR This manual page was written by jaq , for the Debian project (but may be used by others).