luci-mod-admin-full: use `nf_conntrack_count` for counting connections (#1114)
authorJo-Philipp Wich <jo@mein.io>
Thu, 20 Apr 2017 14:55:29 +0000 (16:55 +0200)
committerJo-Philipp Wich <jo@mein.io>
Thu, 20 Apr 2017 14:57:58 +0000 (16:57 +0200)
commit16ffea4bf503f88d5561fbfbaaa48b2dfe66ebec
tree2619e1e6e7e2c1597839298a997c21eec5e124ea
parent29fabe26399fbaecf9231e24f9ac1ee5773cafa6
luci-mod-admin-full: use `nf_conntrack_count` for counting connections (#1114)

As suggested by PR #1114, use `/proc/sys/net/netfilter/nf_conntrack_count`
instead of counting the lines in `/proc/net/nf_conntrack` but use a slightly
more efficient approach which avoids spawning an extra `cat` command.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
modules/luci-mod-admin-full/luasrc/view/admin_status/index.htm