Detecting a change of IP address in Linux

前端 未结 7 1353
轮回少年
轮回少年 2020-12-29 10:53

Does anyone know a way to detect a change of IP address in Linux. Say I have dhcpcd running, and it assigns a new IP address, is there a way I can get a notification when it

7条回答
  •  悲&欢浪女
    2020-12-29 11:17

    This is an older thread but in case someone finds it like I did, I wrote something that does network change detection/notification in Linux awhile back (mostly targeted at helping VPN users), and thanks to some pushy friends I put it up for others to use. It's a pet project now and I'm actively maintaining it, so feature requests and feedback are welcome.

    http://code.google.com/p/ipcheck/source/browse/ipcheck.sh

提交回复
热议问题