Bandwidth monitoring of invidividual computers?

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> General Questions
Author Message
ownaginatious
DD-WRT Novice


Joined: 19 Aug 2009
Posts: 16

PostPosted: Wed Aug 19, 2009 3:05 pm    Post subject: Bandwidth monitoring of invidividual computers? Reply with quote
Hey guys,

Last year I lived in a house off campus of my school with 6 other people, and we were constantly having problems with exceeding out ISPs bandwidth limits.

So I installed dd-wrt to the router (without them even knowing what happened :p) and was able to monitor the collective bandwidth from the whole house.

Eventually we realized it was one person using the majority, but we never figured out who. Does anyone know if dd-wrt offers any sort of bandwidth monitoring by individual computers rather than the network as a whole?

Thanks,

Dillon
Sponsor
Sash
DD-WRT Guru


Joined: 20 Sep 2006
Posts: 7344
Location: Hesse/Germany

PostPosted: Wed Aug 19, 2009 5:52 pm    Post subject: Reply with quote
its not possible afaik
_________________
Forum Guidelines...How to get help
and
Forum Rules
_________________
I'm NOT rude, just offer pure facts!
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 2934

PostPosted: Thu Aug 20, 2009 12:13 am    Post subject: Reply with quote
It can be done with iptables in your firewall script. You just need to create rules for each computer and then check the byte counters on each rule. The counters will not persist through reboots.

iptables -t mangle -I FORWARD -s [internal ip] -j ACCEPT
iptables -t mangle -I FORWARD -d [internal ip] -j ACCEPT


To view the counters:

iptables -t mangle -vnL

_________________
Stop using old builds. Read the forum announcements.
Looking for bricks and spare routers for testing/tutorials.
ownaginatious
DD-WRT Novice


Joined: 19 Aug 2009
Posts: 16

PostPosted: Tue Sep 15, 2009 6:08 am    Post subject: Reply with quote
phuzi0n wrote:
It can be done with iptables in your firewall script. You just need to create rules for each computer and then check the byte counters on each rule. The counters will not persist through reboots.

iptables -t mangle -I FORWARD -s [internal ip] -j ACCEPT
iptables -t mangle -I FORWARD -d [internal ip] -j ACCEPT


To view the counters:

iptables -t mangle -vnL


Sorry for not replying to this earlier, but I'm not very experienced with DD-WRT or command line networking in linux.

What does the -s and -d represent, and how do I find the firewall script? Do I have to ssh to the router?

Thank you.
Sash
DD-WRT Guru


Joined: 20 Sep 2006
Posts: 7344
Location: Hesse/Germany

PostPosted: Tue Sep 15, 2009 8:20 am    Post subject: Reply with quote
destination
and
source

_________________
Forum Guidelines...How to get help
and
Forum Rules
_________________
I'm NOT rude, just offer pure facts!
ownaginatious
DD-WRT Novice


Joined: 19 Aug 2009
Posts: 16

PostPosted: Mon Sep 21, 2009 1:12 am    Post subject: Reply with quote
Sash wrote:
destination
and
source


Oh okay thanks, I understand what I'm looking at now.

Anyway, how would I edit this script? I'm assuming I would have to log in by means of SSH. Where is the location of the script if I ssh into the router?

Thanks,

Dillon
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 2934

PostPosted: Mon Sep 21, 2009 1:25 am    Post subject: Reply with quote
In the gui admin->commands->save firewall
_________________
Stop using old builds. Read the forum announcements.
Looking for bricks and spare routers for testing/tutorials.
ownaginatious
DD-WRT Novice


Joined: 19 Aug 2009
Posts: 16

PostPosted: Mon Sep 21, 2009 8:06 am    Post subject: Reply with quote
phuzi0n wrote:
In the gui admin->commands->save firewall


Awesome, that worked. Thanks for your help guys, I really appreciate it.
ownaginatious
DD-WRT Novice


Joined: 19 Aug 2009
Posts: 16

PostPosted: Tue Sep 29, 2009 5:36 am    Post subject: Reply with quote
Hey guys,

I realized recently that I'm still having some problems. For some reason, the bandwidth counter appears to randomly reset itself, even though the router itself hasn't been reset.

Anyone know a way to fix this?

Thanks,

Dillon
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 2934

PostPosted: Tue Sep 29, 2009 6:01 am    Post subject: Reply with quote
They weren't intended to be persistent but the counters should last as long as your WAN stays up. If one user is really using the majority of the bandwidth then it should be very noticeable if you check the counters at least once a day.
_________________
Stop using old builds. Read the forum announcements.
Looking for bricks and spare routers for testing/tutorials.
mkaand
DD-WRT User


Joined: 06 Jan 2008
Posts: 62

PostPosted: Sat Nov 07, 2009 12:54 pm    Post subject: Reply with quote
You can do that with RFlow Collector v3. It is free for DDWRT. Just search Rflow
tedm
DD-WRT User


Joined: 13 Mar 2009
Posts: 56

PostPosted: Mon Nov 09, 2009 5:36 am    Post subject: One other thing to keep in mind Reply with quote
You will also need to hard-code all of the client MAC addresses in the DHCP server so that all computers continue to get the same IP address on the private network. You probably are seeing the counters stop and start because machines are being rebooted or turned off and on and getting different IP addresses.
Vaako
DD-WRT Novice


Joined: 10 Jun 2009
Posts: 43
Location: Belgium (Land of BEER)

PostPosted: Tue Nov 10, 2009 1:28 pm    Post subject: Reply with quote
WallWatcher would be interesting to do this job but i dont now if DD-WRT send LOG data at port 514 (SysLog) or 162 (SNMPTrap).
Mabe you can enable this somewhere in the config screens or via a script?

Look here:
http://www.wallwatcher.com/

Mabe you get it to work!?

_________________
Regards,
Vaako

1x Linksys WRT600N v1.1 DD-WRT v24-sp2 (10/10/09) mega
Build 13064
1x Linksys WRT54GL v1.1 (DD-WRT)
1x Linksys WRT54GS v2.2 (DD-WRT)
2x Linksys WAP54G v3.1 (Bridge)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
Vaako
DD-WRT Novice


Joined: 10 Jun 2009
Posts: 43
Location: Belgium (Land of BEER)

PostPosted: Tue Nov 10, 2009 5:30 pm    Post subject: Reply with quote
I have checked out for you.
WallWatcher does work with DD-WRT firmwares.

1. Enable "System Log" under Services, set the IP of the system who is running WallWatcher
2. Choose for router in wallwatcher "IPTables"

Have fun!!!

_________________
Regards,
Vaako

1x Linksys WRT600N v1.1 DD-WRT v24-sp2 (10/10/09) mega
Build 13064
1x Linksys WRT54GL v1.1 (DD-WRT)
1x Linksys WRT54GS v2.2 (DD-WRT)
2x Linksys WAP54G v3.1 (Bridge)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> General Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum