help-cfengine
[Top][All Lists]
Advanced

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

RE: Class is not created despite proper conditions.


From: Wheeler, John
Subject: RE: Class is not created despite proper conditions.
Date: Thu, 21 Aug 2003 09:31:17 -0500

classes:
        hdredhat = ( ReturnsZero(/bin/test -f /etc/services) )
control:
        actionsequence = (
                        shellcommands
                        )
        IfElapsed = ( 0 )

alerts:
        hdredhat::
                "this is a test"

http://www.cfengine.org/docs/cfengine-Reference.html#Evaluated%20classes


-----Original Message-----
From: Hans Deragon [mailto:hans@deragon.biz] 
Sent: Wednesday, August 20, 2003 10:42 AM
To: help-cfengine@gnu.org
Subject: Class is not created despite proper conditions.

Greetings.


  Total newbie here.  Got a problem with defining a class.  I have the
following:

---->
groups:

    hdredhat = ( "test -f /etc/redhat-release" )

control:

    IfElapsed    = ( 0 )
    EditFileSize = ( 0 )

    timezone = ( EST )

  hdredhat::

    actionsequence =
    (
      checktimezone     # check time zone
    )
<----

  Yet, the timezone checking is not executed.  In the debugging output
I see:

---->
[...deleted lines...]

LVALUE hdredhat
HandleLVALUE(hdredhat) in action Groups:
EQUALS =
LEFTBRACK
RVAL-QSTRING "test -f /etc/redhat-release"
 
HandleGroupRvalue(test -f /etc/redhat-release)
HandleGroupRVal(test -f /etc/redhat-release) group (hdredhat), type=0
[No match of class]

[...deleted lines...]

Defined Classes = ( any cfengine_2_1_0a6 redhat redhat_9 opt_debug
Wednesday Hr11 Min31 Min30_35 Q3 Hr11_Q3 Day20 August Yr2003 linux
snah1 32_bit linux_2_4_20_6 i686 linux_i686 linux_i686_2_4_20_6
linux_i686_2_4_20_6__1_Thu_Feb_27_10_06_59_EST_2003
compiled_on_linux_gnu localhost_localdomain localhost net_iface_lo
net_iface_eth0 142_133_112_30  142_133_112 ipv4_142_133_112_30
ipv4_142_133_112 ipv4_142_133 ipv4_142 )

[...deleted lines...]
<----

Why isn't my hdredhat class defined?  The file does exist and the test
is successfull:

[root@snah1 cfengine] test -f /etc/redhat-release; echo $?
0

So why isn´t the class defined?  BTW, I know that the ¨redhat¨ class
is defined and I could use it, but this is not the point.  I want to
understand what I am doing wrong here.


Sincerely,
Hans Deragon
_______________________________________________
Help-cfengine mailing list
Help-cfengine@gnu.org
http://mail.gnu.org/mailman/listinfo/help-cfengine




reply via email to

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