Re: Detecting process death for anycast named process monitoring

From: Chris Friesen
Date: Wed May 02 2007 - 18:31:34 EST


Glen Turner wrote:

The question is, how can a process with no relationship to another
process detect that process unexpectedly dying? If named goes
away to a better place, we want to shut down the interface
which causes Quagga to inject the anycast route.

We don't want to be the parent of the running process, because that
doesn't add robustness. If the parent process dies, then the service
dies, and the interface still stays up.

We don't want to poll, because that isn't pretty and the polling
interval needs to be very short on a big ISP's DNS servers.

We did something similar where arbitrary processes can register to be sent an arbitrary signal when the state of other processes change. The caller passes in the pid, the signal to be sent, and an event mask describing which events you're interested in (stop/start/exit/kill/etc.).

A signal number of 0 means to deregister interest in the specified pid.

Chris
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/