* Paolo Lucente <[EMAIL PROTECTED]>, 2004-11-20 20:43 +0100:
> Hello Andre,
> how to aggregate your traffic depends on your needs. If you are just
> interested in having the grand total of bytes transferred over your DSL
> then i would suggest to use 'none' instead of any 'sum_whatever': you
> are absolutely not interested in any primitive, you don't want to know
> who generates your traffic; you need only to roll counters.
> If, instead, you wish to know who generates your traffic maybe the
> 'sum_host' may better suit your needs.
>
> Having successfully compiled pmacctd with PostgreSQL support i would also
> advice to take rid of it and forget the memory plugin. Enable historical
> breakdown of counters so it could help with calculations ('sql_history'
> config directive).
Thanks for the advice. It seems I'm having trouble with my setup,
nothing is accounted for so far. I've configured ppp0 for testing
purposes:
root# pmacctd -f /usr/local/etc/pmacctd.conf
OK: link type is: 9
INFO: default/pgsql: 2048 bytes are available to address shared memory segment;
buffer size is 1024 bytes
INFO: default/pgsql: Trying to allocate a shared memory segment of 524288 bytes
^C
394 packets received by filter
0 packets dropped by kernel
*** Purging PGSQL queries queue ***
*** Purging cache - START ***
*** Purging cache - END (QN: 0, ET: 0) ***
So packet were received, but they don't show up in the database:
(As user postgres; db and tables were created using the supplied
scripts pmacct-create-db.pgsql and pmacct-create-table_v2.pgsql):
pmacct=# select * from acct_v2 ;
agent_id | mac_src | mac_dst | vlan | ip_src | ip_dst | port_src | port_dst |
ip_proto | packets | bytes | stamp_inserted | stamp_updated
----------+---------+---------+------+--------+--------+----------+----------+----------+---------+-------+----------------+---------------
(0 rows)
Here's my /usr/local/etc/pmacctd.conf:
debug: true
interface: ppp0
daemonize: false
post_tag: 1
aggregate: none
plugins: pgsql
sql_db: pmacct
sql_table: acct_v2
sql_table_version: 2
sql_passwd: arealsmartpwd
sql_user: pmacct
sql_refresh_time: 10
sql_history: 100m
plugin_buffer_size: 1024
I must be missing something, but I don't know what.
> PS: thank you for inaugurating the list. Yours has been the first message
> here.
Fun :)
Thanks for your patience and friendly help!
-Andre