Regulatrix - Control your network's traffic

I recently installed a new network for a small non-profit that has a 100Mbit connection but is limted to 100GB/month. They use a lot of video (seven Ring cameras, video playback through laptops and projectors, etc.). And the usual administrative and employee uses.

In order to make this work I’ve put together a package that allows upload/download maximum rates to be specified for fixed devices (by MAC address), as well as imposing download quotas on transient devices. The quotas are designed to permit full network utilization for most users, but to impose limits on users using their devices to provide video service for long intervals for projectors.

There’s also a statistics function to allow the administrator to see how everything is working.

The basic idea is that many video sources/sinks will use as much bandwidth as they can to provide maximum quality images. Unfortunately six or eight 4k streams will go through 100GB very quickly. Limiting the available bandwidth for these devices to as low as 300kbit can provide the desired service sustainably. Meanwhile users can use 100Mbit for interactive use, but if their use beings to consume problematic quantities of data, they can be restricted (for the remainder of the day) to - for example - 800kbit.

Of course this application is generally useful beyond the specific context I wrote it for. Please try it out if you like - it’s available as two APKs, one for the application and another for the LuCI management of the app: Regulatrix - https://github.com/signetica/signetica-feed for the latest release.

1 Like

I’ve added sorted tables to provide additional insight into traffic consumption, and multi-language i18n support in the latest release.

If there is interest in additional languages, please request them here.

Any reason you didn’t implement using nftables? Iptables is long since removed from OpenWrt and only legacy packages depend on it now.

I’m not a fan of iptables, but it’s ubiquitous. The translation layer works easily, and in this context iptables is simple and the things I don’t like about it are not an issue.

I like nftables more. But they both work fine and I don’t feel strongly about it either way.

The real problem is that when you start to seriously think about these implementations, there are lots of things to disagree with. Perhaps it would be more accurate to say I do feel strongly about it, but I try not to.