help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: server iteration


From: Tim Nelson
Subject: RE: server iteration
Date: Thu, 26 May 2005 15:05:27 +1000 (EST)

On Wed, 25 May 2005, Luke Youngblood wrote:

Hey, I really like the idea of copy templating that's presented in that web
page.  It would eliminate a lot of redundant lines from my cfagent.conf
file, and make copy statements a lot easier to read.

I'm not so sure about the Action templating idea though.  The problem is
this:  With a copy statement, using DefaultCopyType = ( checksum ), the file
will only be copied if the checksum differs from the master.  The checksum
is easy to check, because the file should be exactly the same as it is on
the master.  If you are using Action Templating and some perl code to
"customize" each config file for that particular server, now the checksum
will never match, and the copy statement will be invoked every single time,
causing bandwidth issues, as well as chewing up quite a bit of CPU time
invoking perl for every config file on every cfagent run.  How do you work
around this issue?

Hmm. Interesting. I think we have to take it on a case-by-case basis:
PreCopy: Simple; regenerate the template if the source file is newer than
        the destination (with an option to just regenerate anyway); do the
        checksum on the generated file
PostCopy, PreRun, InRun: Do the checksum after copying, but before
        templating

As for the load thing, I've only thought of uses for PreCopy and InRun. I'd be using PreCopy to do the copy stanzas, and it wouldn't get invoked very often. As for InRun, I'd probably be using it for TextSQL (editfiles replacement idea) or Perl, and editing files with it. I find editfiles slow anyway, so going to this would be nothing new. I'd hope that the InRun stuff would only be triggered if the appropriate classes were defined.

As for PostCopy and PreRun, I can't see a specific use for them, but they have potential.

        :)

--
Tim Nelson
Server Administrator
WebAlive Technologies Global
Level 1 Innovation Building, Digital Harbour
1010 LaTrobe Street
Docklands, Melbourne, Vic, 3008
Phone: +61 3 9934 0812
Fax: +61 3 9934 0899
E-mail: address@hidden
http://www.webalive.biz/

"Your Business, Your Web, Your Control"




reply via email to

[Prev in Thread] Current Thread [Next in Thread]