[lug] Polling a file under linux

Rob Judd rjudd at mlug.missouri.edu
Mon Apr 21 11:59:51 MDT 2003


On Mon, 21 Apr 2003, John E. Koontz wrote:

> At 11:57 AM 4/21/2003 -0500, you wrote:
> >I have a C/C++ application that has to connect to an IP address every few
> >minutes/seconds (exact timing is not yet clear).  The IP address may
> >change as the application is running, and the exact address is stored in
> >/etc/myapp.config
> >
> >Since this file may change at any time I have to check it before each
> >connection.
>
> Why change a config file?   Can't the changing agent just communicate the
> information to the application directly, say through a port?

Unfortunately this is the design that has been mandated, partly because of
Ed's point about this being a standard daemon that should be configured in
standard ways.

Rob



More information about the LUG mailing list