Problems with expand_template it is not convergent.

2011-05-18 Thread Bas van der Vlies
cfengine3: 3.1.5 os: debian we use expand_template form the standard cfengine library and small examples is included below. The result is not what we expected. body common control { inputs => { "cfengine_stdlib.cf", }; bundlesequence => { template_usage("gpubatc

Cfengine Help: file permissions anomaly

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: file permissions anomaly Author: schattenfell Link to topic: https://cfengine.com/forum/read.php?3,22037,22037#msg-22037 Hello, files: "/etc/default/cfengine3" comment => "CFEngine defaults file for init.d for $(sys.fqhost)", copy_from

Cfengine Help: Re: file permissions anomaly

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: file permissions anomaly Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,22037,22038#msg-22038 This first thing I would do is use preserve or perms, not both. That's a a lie, I would not use preserve at all. Using perms better expresses

Cfengine Help: Reading/Importing Just one line from csv file

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Reading/Importing Just one line from csv file Author: joe77 Link to topic: https://cfengine.com/forum/read.php?3,22039,22039#msg-22039 Hi, I am new to Cfengine and i wonder how it is possible to extract just one line from a huge (csv)file. I want to read the fields a

Cfengine Help: Re: Multiple cf-serverd processes per host

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Multiple cf-serverd processes per host Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,22034,22040#msg-22040 You lost me after you said 'force policy updates'. This is not the Cfengine way. Yes, it can do it but this is not normal opera

Cfengine Help: Re: Reading/Importing Just one line from csv file

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Reading/Importing Just one line from csv file Author: Beto Link to topic: https://cfengine.com/forum/read.php?3,22039,22041#msg-22041 One way to do it is to use the comment parameter of readstringarray to ignore all the lines except the one you want. Here's an e

Cfengine Help: Re: file permissions anomaly

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: file permissions anomaly Author: schattenfell Link to topic: https://cfengine.com/forum/read.php?3,22037,22042#msg-22042 This was also my intention not to use "preserve" => "true". But even with "preserve" => "false" I get the same log output: [...] cf3> -> Co

Re: where to put local promises? site.cf?

2011-05-18 Thread Nicolas Charles
On 17/05/2011 16:59, Aleksey Tsalolikhin wrote: > On Tue, May 17, 2011 at 5:07 AM, Nicolas Charles > wrote: >> On 13/05/2011 09:42, Aleksey Tsalolikhin wrote: >>> Sorry, I don't recall seeing this in any of the documentation >>> I've read so far, but are my promises supposed to go into >>> site.

Race condition between cfengine and an application?

2011-05-18 Thread Michael Schwartzkopff
Hi, I have seen some strange errors in my application. It tells me that the config file is not available. Since no admin messed around with the file the usual suspect is cfengine sice we roll out that file with it. Is it possible that cfengine while rolling out the file prohibits access to tha

Cfengine Help: Re: file permissions anomaly

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: file permissions anomaly Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,22037,22045#msg-22045 There are two steps to your promise. Copy the file and set the permissions. The copy will have some sort of default permission before the per

Cfengine Help: insert_lines, whitespace_policy, and regex characters

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: insert_lines, whitespace_policy, and regex characters Author: bbomgardner Link to topic: https://cfengine.com/forum/read.php?3,22046,22046#msg-22046 I have noticed that if I use whitespace_policy when inserting a string that has regex characters in it cfengine does n

Re: Cfengine Help: Re: Multiple cf-serverd processes per host

2011-05-18 Thread Andrey Bondarenko
> You lost me after you said 'force policy updates'. > This is not the Cfengine way. "To force" is probably wrong word. I wan't to notify agents that the policy definition was updated. I beleive that notifying agents about policy updates and allowing them to obtain new versions inputs by admin s

Cfengine Help: Re: Multiple cf-serverd processes per host

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Multiple cf-serverd processes per host Author: neilhwatson Link to topic: https://cfengine.com/forum/read.php?3,22034,22048#msg-22048 Cfengine is about automatic promise keeping. You describe what policies should be up to date. Let that agents check in automati

Cfengine Help: Re: Multiple cf-serverd processes per host

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Multiple cf-serverd processes per host Author: bbomgardner Link to topic: https://cfengine.com/forum/read.php?3,22034,22049#msg-22049 To answer some of your questions about the design and intent of cfengine, I would recommend the system automation and network ser

Create array from list

2011-05-18 Thread Daniel Dehennin
Hello, I'm trying to create an array with list expansion and wonder why there is no coordinated iteration. Here is my test case: #v+ body common control { bundlesequence => { "test" }; version => "0.0.5"; } bundle agent test { vars: "l1" slist => { "test1" }; "arra

Cfengine Help: Re: Problems with expand_template it is not convergent.

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Problems with expand_template it is not convergent. Author: bbomgardner Link to topic: https://cfengine.com/forum/read.php?3,22036,22051#msg-22051 Try emptying the target file first: bundle agent template_usage(server) { files: "/var/tmp/config" create => "true

Cfengine Help: Re: Race condition between cfengine and an application?

2011-05-18 Thread no-reply
Forum: Cfengine Help Subject: Re: Race condition between cfengine and an application? Author: bbomgardner Link to topic: https://cfengine.com/forum/read.php?3,22044,22052#msg-22052 Sounds strange. Do you have the error msg? How do you update your policy?

Re: where to put local promises? site.cf?

2011-05-18 Thread Aleksey Tsalolikhin
On Wed, May 18, 2011 at 7:22 AM, Nicolas Charles wrote: > On 17/05/2011 16:59, Aleksey Tsalolikhin wrote: >> >> On Tue, May 17, 2011 at 5:07 AM, Nicolas Charles >>  wrote: >>> >>> On 13/05/2011 09:42, Aleksey Tsalolikhin wrote: Sorry,  I don't recall seeing this in any of the documentat

still trying to set a persistent class. help, please?

2011-05-18 Thread Aleksey Tsalolikhin
I'm stuck, guys. I'm trying to set a persistent class, and then use it. No go. :: test.cf - set a persistent class :: bundle agent example { classes: "myclass" expression => classmatch (".*cfeng.*"), classes => set_to_persist; } body classes set_to_persi

Re: Race condition between cfengine and an application?

2011-05-18 Thread Aleksey Tsalolikhin
On Wed, May 18, 2011 at 7:28 AM, Michael Schwartzkopff wrote: > Hi, > > I have seen some strange errors in my application. It tells me that the config > file is not available. Since no admin messed around with the file the usual > suspect is cfengine sice we roll out that file with it. > > Is it p

Re: still trying to set a persistent class. help, please?

2011-05-18 Thread Aleksey Tsalolikhin
This does not work either, I do not get a report. What I tried was I moved the class definition into a common bundle, to make the persistent class be global. :: test.cf :: bundle common set_persistent_class { classes: "myclass" expression => classmatch (".*cfeng

Re: Create array from list

2011-05-18 Thread Daniel Dehennin
Daniel Dehennin writes: > Hello, > > I'm trying to create an array with list expansion and wonder why there > is no coordinated iteration. > > Here is my test case: > [...] > #v+ > bin/cf-agent -K -I > !! Redefinition of a constant list "index" > cf3> -- Was {'cf_null'}cf3> now {'test1'}cf3