Cfengine Help: Re: Adding large number of host classes slows down cfengine drastically

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Adding large number of host classes slows down cfengine drastically Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19521,19575#msg-19575 In think we need an option to cache these classes as "persistent".This will be part of the efficiency updat

Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Extended solutions guide and YOUR HELP! Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19429,19574#msg-19574 Let's try to make a short list of programs. In my experience ordinary wikis will fail because they quickly get out of control unless t

Cfengine Help: Re: Question on cf-agent locking

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Question on cf-agent locking Author: Seva Gluschenko Link to topic: https://cfengine.com/forum/read.php?3,19505,19573#msg-19573 Robert, doing things like that, one shouldn't be surprised when changes in policies may become postponed for the indefinite period of

Cfengine Help: Re: Question on cf-agent locking

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Question on cf-agent locking Author: ro Link to topic: https://cfengine.com/forum/read.php?3,19505,19572#msg-19572 JFYI, a simple exec_command => "/bin/bash -c 'if ! [ `pidof cf-agent` ] ; then $(sys.workdir)/bin/cf-agent -f /var/cfengine/inputs/failsafe.cf &&

Cfengine Help: Re: Adding large number of host classes slows down cfengine drastically

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Adding large number of host classes slows down cfengine drastically Author: Sal Link to topic: https://cfengine.com/forum/read.php?3,19521,19570#msg-19570 Thanks for that hint as well. I have not as yet implemented execresult anywhere but I know what to look out

Cfengine Help: Re: Cfengine Help: Re: Class case sensitivity

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Cfengine Help: Re: Class case sensitivity Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,19564,19569#msg-19569 Daniel V. Klein Wrote: --- > After this, you have the short hostname in > $(sh

Cfengine Help: Re: Adding large number of host classes slows down cfengine drastically

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Adding large number of host classes slows down cfengine drastically Author: megamic Link to topic: https://cfengine.com/forum/read.php?3,19521,19567#msg-19567 One other thing that made a difference for me is be careful when using execresult - particularly after 3

Cfengine Help: Re: Adding large number of host classes slows down cfengine drastically

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Adding large number of host classes slows down cfengine drastically Author: Sal Link to topic: https://cfengine.com/forum/read.php?3,19521,19566#msg-19566 Thanks megamic! That did improve performance by about 50% but I am still seeing cf-agent grab 100% of a cpu

Re: Dynamic build of variable names

2010-12-01 Thread Michael Potter
I would suggest you approach the problem this way: bundle common hostinfo { vars: hati:: "ip" string => "192.168.1.2"; srv1:: "ip" string => "192.168.1.3"; } bundle agent test { classes: "ok" expression => "any"; reports: ok::

Dynamic build of variable names

2010-12-01 Thread Daniel Dehennin
Hello, I have a common bundle per host to store per host variables like ip addresses. I would like to use $(sys.host) to reference the scope of a variable, the following does not work: = promises.cf body common control { bundlesequence => { "test" }; version => "0.0.1"; } bundle com

Re: Cfengine Help: Re: Class case sensitivity

2010-12-01 Thread Daniel V. Klein
This seems like an awful lot of work to get the long/short hostname. What about: classes: "xxx" expression => regextract("([\w-]+)\..*", "$(sys.fqhost)", "short_host"); After this, you have the short hostname in $(short_host[1]), and the long one has always been available as $(sys.fqhost)

Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread Seva Gluschenko
Thank you Mike, it was really significant piece of information to know about Solaris 10 FMRI. 2010/12/1 Mike Svoboda : > For what its worth, I originally had been running cf-execd as a daemon > managed by a Solaris 10 SMF service > > This ended up being a bad idea.  When cf-execd, cf-agent spawn c

Cfengine Help: Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Cfengine Help: cf-execd: is daemon or cron better? Author: Seva Gluschenko Link to topic: https://cfengine.com/forum/read.php?3,19554,19562#msg-19562 Why doing it that hard? Solaris10 has a poverful FMRI service which monitors processes and restarts them. You onl

Cfengine Help: Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Cfengine Help: cf-execd: is daemon or cron better? Author: ro Link to topic: https://cfengine.com/forum/read.php?3,19554,19561#msg-19561 My line in /etc/crontab looks like this: */5 ** * * root /usr/local/sbin/watchdog.cfengine The script that is calle

Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Extended solutions guide and YOUR HELP! Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,19429,19560#msg-19560 Some good ideas coming in. I think we need to look at this more formally so that in the end we get something that works. First

Cfengine Help: Re: Class case sensitivity

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Class case sensitivity Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,19548,19559#msg-19559 Hi Neil. I'm the one who posted that question regarding the hostnames about a month or so ago. My "feature request" is on the Bug Tracker (issue #3

Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Extended solutions guide and YOUR HELP! Author: ro Link to topic: https://cfengine.com/forum/read.php?3,19429,19558#msg-19558 I don't agree with all of his points, maybe we could discuss things further and set on a common base? Then we could have a look at the cu

Cfengine Help: Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Cfengine Help: cf-execd: is daemon or cron better? Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,19554,19557#msg-19557 Bas van der Vlies Wrote: --- > I run cf-execd as daemon. This runs cf

Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Extended solutions guide and YOUR HELP! Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19429,19556#msg-19556 Christian's article is nice. We should definitely add this to the best practice manual. I pretty much agree with his points, I'll look

Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread Mike Svoboda
For what its worth, I originally had been running cf-execd as a daemon managed by a Solaris 10 SMF service This ended up being a bad idea. When cf-execd, cf-agent spawn child processes -- all of these processes are inherited by the same Solaris "contract id". This means if you have a module that

Re: Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread Bas van der Vlies
On 1 dec 2010, at 17:49, no-re...@cfengine.com wrote: > Forum: Cfengine Help > Subject: cf-execd: is daemon or cron better? > Author: babudro > Link to topic: https://cfengine.com/forum/read.php?3,19542,19542#msg-19542 > > Does anyone have experience or a knowledgeable opinion on this topic? >

Re: Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread Jesse Becker
On Tue, Nov 30, 2010 at 02:01:07PM -0500, Natxo Asenjo wrote: >On Fri, Nov 26, 2010 at 3:42 PM, wrote: >> Forum: Cfengine Help >> Subject: Re: Extended solutions guide and YOUR HELP! >> Author: neilhwatson >> Link to topic: https://cfengine.com/forum/read.php?3,19429,19430#msg-19430 >> >> I've be

Cfengine Help: package version

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: package version Author: bidwell Link to topic: https://cfengine.com/forum/read.php?3,19552,19552#msg-19552 I am running 3.0.5p1 on an ubuntu 10.4 machine and am getting an the following error: !! You must supply a method for determining the version of existing pack

Cfengine Help: Re: SOLVED: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: SOLVED: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19530,19551#msg-19551 Excellent, good luck! ___ Hel

Cfengine Help: SOLVED: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: SOLVED: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: sdodier Link to topic: https://cfengine.com/forum/read.php?3,19530,19550#msg-19550 Mark, Thanks for your help. Your suggestion of: cf-agent -f failsafe.cf &

Cfengine Help: Re: Extended solutions guide and YOUR HELP!

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Extended solutions guide and YOUR HELP! Author: ro Link to topic: https://cfengine.com/forum/read.php?3,19429,19549#msg-19549 I was more thinking along the lines of visual code appearance, i.e. the use of tabs, indents, whitespace, line length and comments as wel

Cfengine Help: Class case sensitivity

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Class case sensitivity Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,19548,19548#msg-19548 I think we've discussed this before but, don't recall any resolution. It's very difficult to know in advance what the agent will set as a class. Fo

cf-report core dumps on FreeBSD

2010-12-01 Thread Deb Heller
All, I'm using Nova, latest release. However, this problem has been present for all versions I've seen. I had hoped the latest release might have fixed it, but no joy. cf-report core-dumps on all our FreeBSD hosts running Nova: Dec 1 10:18:44 washamp kernel: pid 48208 (cf-report), uid 0: ex

Cfengine Help: Re: recurse_ignore?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: recurse_ignore? Author: bidwell Link to topic: https://cfengine.com/forum/read.php?3,19538,19546#msg-19546 Here is what worked after reading through the cfengine_stdlib.cf file again: vars: "svnexclude" slist => { "\.svn" }; file: any:: "/var/cfengine/inp

Cfengine Help: Re: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: cf-execd: is daemon or cron better? Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,19542,19545#msg-19545 Thanks for the responses. I wondered if there was any criteria for choosing, but it sounds like it's a coin toss. It's been working so

Cfengine Help: Re: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: cf-execd: is daemon or cron better? Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19542,19544#msg-19544 The comments still apply. cf-execd is very stable these days, and can be restarted by a cf-agent that was started by a cf-execd, that..., w

Cfengine Help: Re: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: cf-execd: is daemon or cron better? Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,19542,19543#msg-19543 I do both. Cf-execd runs at a scheduled interval. At another interval a cron job runs cf-execd non-forked. In this way if cf-exec

Cfengine Help: cf-execd: is daemon or cron better?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: cf-execd: is daemon or cron better? Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,19542,19542#msg-19542 Does anyone have experience or a knowledgeable opinion on this topic? In section 4.2 of the Reference Manual it demonstrates putting cf-exec

Cfengine Help: Re: recurse_ignore?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: recurse_ignore? Author: pieterb Link to topic: https://cfengine.com/forum/read.php?3,19538,19541#msg-19541 Does this work for you? body depth_search recurse(d) { depth => "${d}"; exclude_dirs => { "\.svn" }; ___ Help

Cfengine Help: Re: Stopping cf-execd?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Stopping cf-execd? Author: babudro Link to topic: https://cfengine.com/forum/read.php?3,18691,19540#msg-19540 I use the init script to start & stop daemons. Looking at /etc/init.d/cfengine3 (I believe I got this one with the 3.0.5p1 RPM) I see three ways it han

Cfengine Help: recurse_ignore?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: recurse_ignore? Author: bidwell Link to topic: https://cfengine.com/forum/read.php?3,19538,19538#msg-19538 My masterfiles directory is populated from subversion and I am trying to copy_from(...) without getting the .svn directory. I have tried the following: files:

Re: Singleton list is not iterated

2010-12-01 Thread Mark Burgess
Upgrade, upgrade, upgrade :-) There was a significant change in the computation of lists in 3.1.0 and this led to a couple of issues that pulled in two directions and led to some bugs. I believe all these are fixed in the current svn. On 12/01/2010 05:13 PM, Daniel Dehennin wrote: > Hello, > >

Singleton list is not iterated

2010-12-01 Thread Daniel Dehennin
Hello, I filled a debian bug report[1] but it may be a better place for this. The following recipe show that singleton list are not iterated, I must add "cf_null" at the end of the list to make it works: = promises.cf body common control { bundlesequence => { "test" }; version => "0.

Cfengine Help: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: mark Link to topic: https://cfengine.com/forum/read.php?3,19530,19535#msg-19535 The standard way to avoid this is to set up execd (or cron) to run the command cf-age

Cfengine Help: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,19530,19534#msg-19534 Unless you don't trust your network I don't know why you would keep a local re

Re: Cfengine Help: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread Jesse Becker
On Wed, Dec 01, 2010 at 08:42:58AM -0500, no-re...@cfengine.com wrote: >Forum: Cfengine Help >Subject: Should it take two cf-agent runs before a change on policyhost is >implemented on client? >Author: sdodier >Link to topic: https://cfengine.com/forum/read.php?3,19530,19530#msg-19530 > >Implement

Cfengine Help: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: sdodier Link to topic: https://cfengine.com/forum/read.php?3,19530,19533#msg-19533 Hi Neil, Thanks for your comment. Could you elaborate? I currently have the clie

Cfengine Help: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,19530,19532#msg-19532 I stagger my schedule. In your example you run the agent every hour. In that

Cfengine Help: Re: Array member

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Re: Array member Author: Igor Link to topic: https://cfengine.com/forum/read.php?3,19475,19531#msg-19531 It would be nice to do slist based on an array... :( https://cfengine.com/forum/read.php?3,13991,18938#msg-18938 ___

Cfengine Help: Should it take two cf-agent runs before a change on policyhost is implemented on client?

2010-12-01 Thread no-reply
Forum: Cfengine Help Subject: Should it take two cf-agent runs before a change on policyhost is implemented on client? Author: sdodier Link to topic: https://cfengine.com/forum/read.php?3,19530,19530#msg-19530 Implementing changes to a cfengine 3 (cf3) client takes two cf-agent runs. ISSUE: In m