|
From: Nikolay H. <ge...@st...> - 2002-09-27 18:18:58
|
hello to all subscribers :) in a few days i'll release new version of netacct-mysql. here are = important changes: - full logging is no longer available .. if you want to log all = conncetions in sql go and get 0.73 it will work just fine. accounting = table removed so if you upgrade and don't need this data you can safely = remove this table. - listen to more that 1 interface, some code rewritten and now using = pthreads .. every interface get its own thread - removed some code about writing in file - now it logs current traffic not only when connection is closed .. = there are no net-acct-dump.o.x.x files any more - support of 4 types traffic - international/peering/direct/local .. so = you can differ traffic in 4 stages - php upgrade script which will convert old traffic in new type = (0.73->0.75) .. 0.74rc1 -> 0.75 don't need any upgrade some explanation: 1. the reason to remove full logging is that holding every connection in = memory and in five minutes write it in sql causes heavy load of mysql in = case you have a heavy network load ... it leads to "mysql resource = temporary unavailable" when strace-ing forked process which writes data = in mysql and possibly lost of accounting data/pc crash/mysql 99% cpu. old way collecting data: you open a web page and then open an ftp and get a file: your_ip web_server_ip send_traffic peer_flag web_server_ip your_ip received_traffic peer_flag your_ip ftp_server_ip send_traffic peer_flag ftp_server_ip your_ip received_traffic peer_flag new way collecting data: your_ip in_traffic out_traffic peer_flag as you see this will not consume large amounts of memory ... there will = be ip's_in_compactnet*peer_types*13bytes in memroy (peer_types =3D 5) 2. i've read some messages from groups.google.com about problems with = libpcap+pthreads .. i've read some code and finally got it to work but = it is tested inly on linux so please go and get latest cvs version and = try it on some bsd .. some ideas, code and #ifdef's taken from = snort/ntop/ethereal ..=20 i;m running this about 3 days and no problems at all on 10Mbit LAN with = > 300 pc's and heavy load of traffic so i'll test it some more time and = will release final version Regards, Nikolay Hristov |