jow- / nlbwmon

Simple conntrack based traffic accounting
ISC License
147 stars 33 forks source link

interfaces and bridges #19

Closed rezad1393 closed 6 years ago

rezad1393 commented 6 years ago

in nlbwmon setting in luci I can only see two options for local network. one in called wan, which refers to my pppoe-wan interface and another is called lan that refers to my two wireless interfaces, on 2.4 and 5Gh. but there is no sign of my LAN interfaces, eth0 that is for wan and eth1 which is for ethernet lan. and also no sign of the br-lan which is the bridge between two wirelesses and the ethernet lan (eth10). is this correct? shouldnt it show ethernet lan at least?

I noticed that my wireless connected devices traffic is not counted (almost at all). if I update my app on my tablet for some 50MB traffic then the traffic on nlbwmon is not counted for that device at all.

also how can I set my option to only count my wan (internet traffic) the router that lede is installed is connected in bridge mode to internet modem.(on eth0 port)

this is my ip command output on lede. `

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 532 link/ether xxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff

3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br-lan state UP group default qlen 532 link/etherxxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff

8: teql0: mtu 1500 qdisc noop state DOWN group default qlen 100 link/void

9: br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000 link/ether xxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff inet 192.168.1.1/24 brd 192.168.1.255 scope global br-lan valid_lft forever preferred_lft forever

11: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br-lan state UP group default qlen 1000 link/ether xxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff

12: wlan1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br-lan state UP group default qlen 1000 link/ether xxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff

13: ifb0: <BROADCAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc hfsc state UNKNOWN group default qlen 32 link/ether xxx.xxx.xxx.xxx brd ff:ff:ff:ff:ff:ff

19: pppoe-wan: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1430 qdisc hfsc state UNKNOWN group default qlen 3 link/ppp inet xxx.xxx.xxx.xxx peer 10.255.255.255/32 scop `

jow- commented 6 years ago

Yes this is correct. It enumerates logical devices which are just "lan" and "wan" in your case. "lan" resolves to "br-lan" which in turn resolves to "wlan0", "wlan1" and "eth1". Traffic monitoring is performed via conntrack, which has no concept of interfaces but only source and destination subnets.

rezad1393 commented 6 years ago

the lan part is showing lede and lede5 (two wireless interfaces and not the eth1) but in fact it doesnt track most of wireless traffic. almost exclusively it count my ethernet connected laptop and minibaord.

rezad1393 commented 6 years ago

update after last LEDE install it seems to work now