[<< | Prev | Index | Next | >>]

Saturday, May 06, 2023

Trax (network activity tracker)



[Nerdy stuff of possible interest to linux sys admins]

For years I've wanted/needed a good network activity tracker but haven't found one that suited me, so I finally decided I'd waste less time writing one than looking for or not having one.

Iftop is the go-to for this, but I find it mostly useless in practice because it doesn't let you organize or focus on the things of interest. So two days later, I have trax (which I named before realizing how over-used the name already is, but I'll probably be the only one ever using it so who cares).

I'm quite happy with the result. It's all in python. There's a one-file server that has to run as root but it's light weight with only standard imports and sits idle (in select()) when no clients are connected. The user-space client uses a small subset of my personal libraries (included) plus Trio.

The client looks like this (you can open and close the hierarchy as you like):

Here's the source.

Let me know how it goes if you actually try it.



[<< | Prev | Index | Next | >>]


Simon Funk / simonfunk@gmail.com