[Top][All Lists]

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

Re: defined classes in cfagent.conf not present from cfrun

From: Brendan Strejcek
Subject: Re: defined classes in cfagent.conf not present from cfrun
Date: Wed, 16 Feb 2005 14:52:38 -0600
User-agent: Mutt/1.5.6+20040818i

I don't think this is related to your problem, but is there a reason
you are using a shell callout to /usr/bin/test rather than FileExists?

If behavior is different on the command line than using cfrun, I would
suspect a difference in the environment. Maybe PATH... except that test
is absolutely qualified. You might want to have a shellcommand of
/usr/bin/env and compare the output in both cases.

Greg Retkowski wrote:

> I've got a weird problem with cfengine, and I'm curious if anyone else
> has encountered it, or if it's a 'feature' and if so how I work around
> it. I define lots of classes/groups in my cfagent.conf file, mostly
> based on if a file exists, and then various actions occur based on if a
> system is in a given class. For example, if the system is a webserver
> then there's a section in 'processes:' that'll restart a dead webserver
> (and so on). This works fine running cfagent locally on the command
> line, but when run remotely via cfrun none of the classes/groups I
> define in cfagent.conf are defined when cfagent remotely runs.
> So I've got in my cfagent.conf something like:
> groups:
>         is_webserver = ( "/usr/bin/test -f /etc/httpd/conf/httpd.conf" )
> when  i run cfagent on the command line (with arguments -v --no-splay )
> on the local host I get:
> Defined Classes = ( ... is_webserver ... )
> But if I run it remotely with 'cfrun somehost -- -v' the is_webserver
> does not show up in Defined Classes.
> This is on cfengine version 2.1.11.
> Any clue??
> -- Greg
> -- 
> Greg Retkowski /     I.T. Infrastructure Consultant      | RAGE
> address@hidden C:408-455-3913 | .NET
> _______________________________________________
> Help-cfengine mailing list
> address@hidden

reply via email to

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