On Fri, 2005-06-10 at 15:27 +0200, Philippe de Rochambeau wrote:
> Hello,
> 
> I need to rotate, compress and delete old copies of logs written to, by 
> on-going perl scripts.
> 
> When cfengine rotates logs, how does it know which applications/scripts 
> created the logs?

It doesn't.

> Assuming that it somehow figures out the name of the log-writing 
> applications/scripts (via a cfengine configuration file, perhaps), how 
> does it tell them to temporarily stop writing to the logs while 
> cfengine rotates them, compresses them, and deletes the old logs, and 
> to resume writing afterwards?

It makes a copy of the current log and then empties the current log,
so that the file descriptor never changes. That way, it never has to
close a file or make a change,

> Do you need to write a HUP signal handler in your log-writing scripts 
> for cfengine to send signals to?

Nope

M



_______________________________________________
Help-cfengine mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-cfengine

Reply via email to