Forum archive
Run a script when IP address changes
Guys, do you know any method to run a script when there is a system IP address change? I would like to know a good method for another TKLPatch I'm preparing. It could be usefull maybe if confconsole had some hooks on this event to plug in users script.
Thanks for your support. I'll continue searching google ;)
I'm not exactly sure what you want to do, but here are some pointers that might help:
/etc/network/{if-down.d, if-post-down.d, if-pre-up.d, if-up.d}
If what you want is dhcp specific, you might be interested in /etc/udhcpc/* (but I'm not sure I would recommend this direction as you never know if a user, or TurnKey will change the dhcp client).
I hope the above helps.