bmon (and other utils) on EdgeOS

I’m really not a huge fan of Ubiquiti or EdgeOS. I am a huge fan of vyatta and VyOS though. I switched from a virtualized instance of VyOS to the Edgerouter POE over a year ago and I miss some of the tools I had on a full blown linux box. But really though, the EdgeRouter is a linux box too and I can’t resist tinkering with linux appliances. There’s lots of fun network monitoring tools out there and if you’re the type that doesn’t log into your edgerouter’s web gui like I, then you might be hungry for graphs and statistics.

Hello World

Your Edge router is dying to talk to the outside world. And Ubiquiti documents how to do just that.

https://help.ubnt.com/hc/en-us/articles/205202560-EdgeRouter-Add-other-Debian-packages-to-EdgeOS

It’s nothing hard and you can stay in the vyatta configuration mode to make the system changes. DON’T run the below if you’re on FW 1.6 or older. Go to the link above for alternative instructions.

configure set system package repository wheezy components 'main contrib non-free' set system package repository wheezy distribution wheezy set system package repository wheezy url http://http.us.debian.org/debian commit save exit

Once that’s done, use sudo apt-get/apt-cache like any other debian box.

DO NOT RUN SUDO APT-GET UPGRADE THOUGH!!!

keep to apt-get update, apt-cache search, apt-get install <package>

Utils worth checking out

So bmon is a quick easy way to diagnose large traffic flows, but there’s quite a few to choose from. Anything mentioned can be installed with

apt-get install <package>

Just keep an eye on your disk space with

df -h

Most of the Utils are pretty small, but so is your storage.

bwm-ng

This one’s similar and it can do graphs which aren’t that great. Tapping t toggles between 30second averages, max, sum, and real time numbers. I find this one to be a little more useful with the amount of interfaces I have

vnstat

Vnstat is actually a service. After it runs for a while it will gather some useable information. I’m going to give this one a shot for the long term but I’m a bit nervous as it’s going to grow a database. I’ve tried getting the router to mount an nfs share so I could save the database on a local server but have had no success. Even with nfs-common package, it simply can’t do it. I’m guessing it’s lacking kernel support.

iptraf

iptraf is something that I really can’t really sum up in words. When you need detail this is it. If you haven’t checked it out it’s definitely worth a look. It’s pretty much going to be netstat for your router plus throw in a MAC table so you know who’s on each interface.

So this is really just the start. All debian utilities (assuming kernel and storage support) are available to you. I just thought you might find use in the network utils. Experiment, tweak, just watch your disk usage. Oh and if you figure out how to mount an NFS share to these things let me know.