I have a FreeBSD 7.3-RELEASE-p2 server communication with various workstations (it is mainly a subversion server). I need to measure the amount of data that is transferred from my server to one specific client.

If possible I would like to do this using base system utilities, but any hint is appreciated.

link|improve this question
feedback

2 Answers

up vote 3 down vote accepted

You can use ipfw count rules:

ipfw add 00008 count tcp from 10.1.1.1 to me
ipfw add 00009 count tcp from me to 10.1.1.1

Also you can use NetFlow(ng_netflow), trafd or ipcap.

link|improve this answer
Using ipfw make sure you don't already have rules n°8 and/or n°9 or ipfw will group those rules and if you have to delete one of them later you'll lost the others. – Shadok Feb 21 '11 at 14:13
Yes, using ipfw count rules is exactly what I was looking for. Using sh, awk and crontab I get daily accounting in csv files that can be visualized and processed fürther. Thanks for pointing out the obvious ;) – enoch Feb 22 '11 at 7:54
feedback

You should try http://iperf.sourceforge.net/

link|improve this answer
iperf is useful for benchmarking connection speed, but does not provide usage accounting, which is what the questioner is asking for I believe.. – Chris S Feb 21 '11 at 17:10
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.