Hi,

In logfile i see this

Feb  9 16:47:46 oam02 sfacctd[14477]: DEBUG ( default/mysql ): INSERT INTO
`acct_v5_06` (stamp_updated, stamp_inserted, vlan, src_port, dst_port, tos,
ip_proto, agent_id, class_id, mac_src, mac_dst, ip_src, ip_dst, packets,
bytes, flows) VALUES (FROM_UNIXTIME(1265730466), FROM_UNIXTIME(1265730300),
200, 6007, 54654, 104, 'ip', 0, 'unknown', '0:0:0:0:0:0', '0:0:0:0:0:0',
'0.0.0.0', '0.0.0.0', 1, 242, 0)

As you can see a lot of fields are inserted with null values.
This is my config

debug: true
daemonize: true
plugins: mysql
aggregate: vlan,tos
nfacctd_port: 6343
sql_refresh_time: 120
sql_history: 5m
sql_history_roundoff: mhd
sql_table_version: 5
sql_passwd: sflow
sql_table: acct_v5_%W
sql_table_schema: /var/lib/pmacct/mysql_v5.schema
syslog: local0
!

Here is sample output from my mysql.

mysql> select * from acct_v5_06 limit 10;
+----------+----------+-------------+-------------+------+---------+---------+----------+----------+----------+-----+---------+-------+-------+---------------------+---------------------+
| agent_id | class_id | mac_src     | mac_dst     | vlan | ip_src  | ip_dst
| src_port | dst_port | ip_proto | tos | packets | bytes | flows |
stamp_inserted      | stamp_updated       |
+----------+----------+-------------+-------------+------+---------+---------+----------+----------+----------+-----+---------+-------+-------+---------------------+---------------------+
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 104 |      67 | 36641 |     0 |
2010-02-09 15:25:00 | 2010-02-09 15:30:01 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 252 |       2 |   228 |     0 |
2010-02-09 15:25:00 | 2010-02-09 15:30:01 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       |   0 |       7 |   693 |     0 |
2010-02-09 15:25:00 | 2010-02-09 15:30:01 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 104 |      10 |  5740 |     0 |
2010-02-09 15:30:00 | 2010-02-09 15:32:02 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       |   0 |      10 |   990 |     0 |
2010-02-09 15:30:00 | 2010-02-09 15:36:03 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  100 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 104 |       5 |   430 |     0 |
2010-02-09 15:30:00 | 2010-02-09 15:36:03 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  100 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       |   0 |       1 |    68 |     0 |
2010-02-09 15:35:00 | 2010-02-09 15:36:03 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  100 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 104 |       2 |   172 |     0 |
2010-02-09 15:35:00 | 2010-02-09 15:38:02 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       |   0 |       7 |   662 |     0 |
2010-02-09 15:35:00 | 2010-02-09 15:40:01 |
|        0 | unknown  | 0:0:0:0:0:0 | 0:0:0:0:0:0 |  200 | 0.0.0.0 | 0.0.0.0
|        0 |        0 | ip       | 104 |      39 | 17610 |     0 |
2010-02-09 15:35:00 | 2010-02-09 15:40:01 |
+----------+----------+-------------+-------------+------+---------+---------+----------+----------+----------+-----+---------+-------+-------+---------------------+---------------------+


I probably have missed something in my config. But i cant find what. I also
need help undestanding the TOS values? What is tos 67?  in VLAN 200 i only
should see DSCP AF31, and DSCP 47.
Im also including a capture of sflow packets.

//Regards Jonas

Attachment: sflow.cap
Description: Binary data

_______________________________________________
pmacct-discussion mailing list
http://www.pmacct.net/#mailinglists

Reply via email to