help-cfengine
[Top][All Lists]
Advanced

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

Re: Class definitions - is "_" (underscore) an operator?


From: Jon-Finngard Moe
Subject: Re: Class definitions - is "_" (underscore) an operator?
Date: Wed, 30 Nov 2005 14:15:59 +0100
User-agent: Mutt/1.4.2.1i

Ed Brown wrote:
> The docs say about the 'IPRange(...) function:
> True if the current host lies within the specified IP range
> 
> So 'customer' and 'customer_location' (a valid classname) are true if
> any ip addresses on the current host are in range.
> 
> Without seeing the ipaddresses on the host in question, and the range
> expressions, it would be hard to say why both classes are being defined.
> 
> -Ed

Thanks. If I understand you correctly you say that the addresses overlap in 
some 
way, the both classes will be active for the current range.

That is not the case. (As these are different /24-networks they could not 
overlap).

*****************************************

To fill in with bogus adress ranges: 

        customer = (
                IPRange(172.24.200.0/24)
        )

        customer_location = (
                IPRange(172.24.212.0/24)
        )



*******************************************

From the file I do the imports:

import:
        
      mnemonic::               cf.mnemonic              # Config file for 
mnemonic
      customer::               cf.customer              # Config file for 
customer
      customer_location::      cf.customer_location     # Config file for 
customer 
at location

     .....

*******************************************



From cfagent output on host 172.24.212.117 (Running FreeBSD 5.4-STABLE and 
cfengine 2.1.17):

Defined Classes = ( ... customer customer_location ... )

*********************************************************************^M
 Main Tree Sched: checktimezone pass 1 @ Wed Nov 30 14:01:16 2005^M
*********************************************************************^M

....

Looking for an input file cf.sensors
Looking for an input file cf.mss
Looking for an input file cf.backup
Looking for an input file cf.crontab
Looking for an input file cf.nagioskeys
Looking for an input file cf.rootshell
Looking for an input file os/cf.freebsd
Looking for an input file cf.customer
Looking for an input file cf.customer_location

....


*********************


Again I find that very strange as this is the only place I define the mentioned 
classes. 

I could try to alter the classname "customer_location" to "customerlocation" to 
see if that fixes the problem.


-- 

Jon-Finngard Moe                   Email: finngard@mnemonic.no
mnemonic AS, Wergelandsveien 25         Mob  : +47 98 64 58 62
N-0167 Oslo, Norway                     Tlf  : +47 23 20 47 45 
                                        Fax  : +47 23 20 47 01
PGP key EEAADBBA available from pgp.mit.edu

Attachment: pgpjjGvto83gY.pgp
Description: PGP signature


reply via email to

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