help-cfengine
[Top][All Lists]
Advanced

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

Understanding output, modifying output, importing groups


From: Brian E. Seppanen
Subject: Understanding output, modifying output, importing groups
Date: Thu, 27 Jan 2005 16:44:21 -0500 (EST)

I'm trying to understand the output of cfengine a bit better.   I have 
several hosts that run cfexecd on a 15 minute interval.

I'm running 2.1.10.   My cfagent consists of


import:

        any::
                /var/cfengine/inputs/cf.groups
                /var/cfengine/inputs/cf.main


My cf.groups is something

        service1 = ( hosta hostb hostc hostd )
        service2 = ( hoste hostf hostg )

my cf.main consists of

control:


        actionsequence  = ( copy shellcommands )
        TrustKey        = ( true )
        TrustKeysFrom   = ( master )
        domain          = ( domaina )
        Underscore_Classes = ( on )
        sysadm          = ( address@hidden )  
        access          = ( root )
        smtpserver      = ( smtp.domaina )
        EmailFrom       = ( address@hidden )
        EmailMaxLines   = ( 10000 )
        EditfileSize    = ( 800000 )
        IfElapsed       = ( 2 )
        ExpireAfter     = ( 2 )
        SkipVerify      = ( true )
        OutputPrefix    = ( "main=>" )


copy:

        servicea::

                /var/cfengine/services/servicea/cf.servicea
                        dest=/var/cfengine/inputs/cf.servicea
                        server=master
                        trustkey=true
                        encrypt=true
                        force=true

        serviceb:: 

                /var/cfengine/services/serviceb/cf.serviceb 
                        dest=/var/cfengine/inputs/cf.serviceb 
                        server=master               
                        trustkey=true
                        encrypt=true
                        force=true

shellcommands:

        servicea::

                "/var/cfengine/sbin/cfagent -i -f 
/var/cfengine/inputs/cf.servicea"

        serviceb::

                "/var/cfengine/sbin/cfagent -i -f 
/var/cfengine/inputs/cf.serviceb


So my undertanding of the scenario is that cfexecd calls cfagent which 
uses cfagent.conf,  cfagent.conf does nothing more than import some groups 
into play.   Those groups are evaluated and if the host belongs to one of 
those groups it pulls a specific service cf.  

So I get the following output.   And I see the same action twice.   Once 
listed under cfagent output denoted by main=> and once under os/linux.cf 
denoted by linux+host->

cfengine::in/cfagent -i -: main=>:in/cfagent -i -:  
linux+host->:newaliases: /etc/aliases: 154 aliases, longest 287 bytes,
8244 bytes total 
main=>:in/cfagent -i -: linux+hostr->:newaliases:
/etc/aliases: 154 aliases, longest 287 bytes, 8244 bytes total

Is there any way that I can either have all output listed under cfagent 
and not listed under subcategories, or vice versa?   Or would I need to 
restructure so that I'm using a single cfagent.conf?     

I like the method we have for maintaining seperate cf's under a seperate 
hierarchy.    It could be that I'm just blind to an obvious solution.   
Would anyone mind commenting?   How have others handled groups and 
imports and the corresponding output.     

Thanks for the help.



Brian Seppanen
address@hidden
608.826.1464




reply via email to

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