[Top][All Lists]

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

RE: ReturnsZero(): command does not return zero. Is classcreatedwith val

From: Villalovos, John L
Subject: RE: ReturnsZero(): command does not return zero. Is classcreatedwith value of false?
Date: Wed, 28 Apr 2004 09:44:45 -0700

> Has anything happened on this issue?
> I just upgraded from 2.0.7p3 to 2.1.5 and now my ReturnsZero
> statements don't seem to work anymore :(
>     groups:
>         # The web server is called httpd in Red Hat 8.0 forward
>         hasWebServer_rh8 = ( ReturnsZero(/bin/rpm -q --quiet httpd) )
>         # The web server is called apache in Red Hat 7.x
>         hasWebServer_rh7 = ( ReturnsZero(/bin/rpm -q --quiet apache) )
>         # See if phpMyAdmin is installed
>         has_phpMyAdmin = ( ReturnsZero(/bin/rpm -q --quiet
> phpMyAdmin) ) 
>     shellcommands:
>         webServer.redhat_7.!hasWebServer_rh7::
>             "/usr/sbin/up2date apache"
>             "/sbin/chkconfig httpd on"
>             "/sbin/service httpd start"
>         webServer.redhat_8.!hasWebServer_rh8::
>             "/usr/sbin/up2date httpd"
>             "/sbin/chkconfig httpd on"
>             "/sbin/service httpd start"
>         # Install phpMyAdmin if a phpMyAdmin server
>         phpMyAdminServer.!has_phpMyAdmin::
>             "/usr/sbin/up2date phpMyAdmin"
> After upgrading to 2.1.5, none of my ReturnsZero commands are working.
> The classes are not being created.

I played around with this some more and ran cfagent -d0 -v and found the

RVAL-FUNCTION ReturnsZero(/bin/rpm -q --quiet httpd)
HandleFunctionObject(ReturnsZero(/bin/rpm -q --quiet httpd))
IsBuiltinFunction(ReturnsZero(/bin/rpm -q --quiet httpd))
IsBuiltinFunction: ReturnsZero(/bin/rpm -q --quiet httpd)
ExpandVarstring(/bin/rpm -q --quiet httpd)
HandleFunction: ReturnsZero(/bin/rpm -q --quiet httpd)
HandleReturnsZero(/bin/rpm -q --quiet httpd)
cfengine:: Wait for child failed
HandleGroupRVal(XX_CF_opposite_any_XX) group (hasWebServer_rh8), type=0
[No match of class XX_CF_opposite_any_XX]

So does anyone know why cfengine would have "Wait for child failed"?
This did NOT happen in 2.0.7.  Did the exec code get changed?


A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting
Q: What is the most annoying thing on usenet and in e-mail?

reply via email to

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