Commit graph

55 commits

Author SHA1 Message Date
Daniel Eklöf
24842d9b28 module/network: RTM_NEWLINK/DELLINK: don't do anything if nothing's changed
We're only interrested in a few of the attributes. Thus, there's no
need to log or update anything, if none of those attributes haven't
changed.
2018-12-31 13:40:43 +01:00
Daniel Eklöf
dcf8051f1a module/network: break out message parsing code
This also allows us to actually handle errors (by aborting run())
2018-12-31 13:36:44 +01:00
Daniel Eklöf
8352d89491 module/network: break out message receiving code 2018-12-31 13:27:37 +01:00
Daniel Eklöf
b3f3f91dc2 module/network: drop libnl dependency, use raw netlink sockets instead 2018-12-31 13:19:01 +01:00
Daniel Eklöf
4c4f0ce7a0 module: network: monitor ethernet interfaces
State exposed (tag names):

* name: the interface name ("eth0" etc)
* index: the interface index, "ifindex"
* state: operational state (down, up etc)
* mac: the Ethernet hardware address
* ipv4: the *last* IPv4 address added to the interface
* ipv6: the *last* IPv6 address added to the interface

State we monitor (for changes):

* state
* ipv4 addresses
* ipv6 addresses
2018-12-30 20:40:10 +01:00