Wednesday, May 18 2005 @ 03:59 AM EDT Contributed by: glosser
Linux.com offers this tutorial on "ifplugd", an interface plug daemon.
I can't count the times I've set up my laptop, only to forget to plug in the network cable. If I do this on my Slackware laptop, I have to open a terminal and configure the interface manually with the ifconfig and route commands. Every time, I think, "Gee, it would be nice if Slackware took care of this automatically." If that sounds familiar to you, I have good news.
The ifplugd interface plug daemon, written by Lennart Poettering and released under the GPL, is just the tool to handle this situation. ifplugd listens on a specified interface for a new or lost network connection and issues commands based on either event.
If you're running Mandrake or some other distros, there's a good chance you've already got ifplugd on your system. If not, it's a simple matter to install it yourself. Installation requires two packages: libdaemon, also written by Poettering, and ifplugd itself. Both are available as source code, though binaries are available for some distributions.