{"id":16164275,"url":"https://github.com/troglobit/nlmon","last_synced_at":"2026-03-08T22:32:49.913Z","repository":{"id":136803900,"uuid":"371082288","full_name":"troglobit/nlmon","owner":"troglobit","description":"Simple example of how to use libnl and libev to monitor kernel netlink events","archived":false,"fork":false,"pushed_at":"2022-06-07T11:18:50.000Z","size":6,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-17T00:34:08.558Z","etag":null,"topics":["libev","libnl","linux","netlink","networking"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/troglobit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-05-26T15:25:41.000Z","updated_at":"2024-02-01T03:34:42.000Z","dependencies_parsed_at":"2024-07-22T12:06:37.224Z","dependency_job_id":null,"html_url":"https://github.com/troglobit/nlmon","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/troglobit%2Fnlmon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/troglobit%2Fnlmon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/troglobit%2Fnlmon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/troglobit%2Fnlmon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/troglobit","download_url":"https://codeload.github.com/troglobit/nlmon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244318675,"owners_count":20433961,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["libev","libnl","linux","netlink","networking"],"created_at":"2024-10-10T02:46:02.502Z","updated_at":"2026-03-08T22:32:44.892Z","avatar_url":"https://github.com/troglobit.png","language":"C","readme":"nlmon\n=====\n\nSimple example of how to use libnl and libev to monitor kernel netlink\nevents.  Beware, there's a lot of boiler plate code you might not need.\n\n\nBuilding\n--------\n\nTo build and use nlmon, you need the libnl and libev libraries.  On\nDebian/Ubuntu and Linux Mint, the following command installs the\nrequired development libraries and their runtime equivalents:\n\n    sudo apt install libnl-route-3-dev libnl-3-dev libev-dev\n\nProvided the code of this project is cloned to `~/nlmon`, do:\n\n    cd ~/nlmon\n    gcc -o nlmon  nlmon.c -I/usr/include/libnl3 -lnl-3 -lnl-route-3 -lev\n\nor type `make` to let it call GCC for you.\n\n\nTesting\n-------\n\nIn one terminal window, run nlmon:\n\n    ./nlmon -v\n\nIn another terminal window, create and delete a VETH pair:\n\n    sudo ip link add veth1 type veth peer name veth1-peer\n    sudo ip link del veth1\n\nThere should be output from nlmon in the first window:\n\n    ./nlmon -v\n    nlmon: veth iface veth1 deleted\n    nlmon: veth iface veth1-peer deleted\n    nlmon: veth iface veth1-peer added\n    nlmon: veth iface veth1 added\n\n\nOrigin \u0026 References\n-------------------\n\nThis project is based on a deprecated external netlink plugin for the\n[finit][] init system.  It was developed by various people at Westermo\nover the years.  It has since been replaced by a native plugin.\n\nBrought back to life by [Joachim Wiberg][] for use as an example of how\nto utilize libnl and libev.\n\n[finit]:          https://github.com/troglobit/finit\n[Joachim Wiberg]: http://troglobit.com\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftroglobit%2Fnlmon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftroglobit%2Fnlmon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftroglobit%2Fnlmon/lists"}