help-cfengine
[Top][All Lists]
Advanced

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

Re: Repository behavior


From: Ralph Angenendt
Subject: Re: Repository behavior
Date: Thu, 9 Nov 2006 15:12:54 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

lothian+cfengine@cs.utk.edu wrote:
> So, I'm trying out the Repository variable with cfengine-2.1.21.  It
> copies the .cfsaved files to the repository directory just fine.
> However,  a .cfsaved file is still being left in the original directory.
> 
> The intent behind using the repository was to avoid problems like
> changing a file in /etc/cron.daily/ (on a Redhat-ish machine), and
> having a backup .cfsaved made which also gets executed.

This behaviour began to show with version 2.1.21, before that it worked
as you (and I) would expect. I assume that it has to to with the changes
in image.c from 2.1.20 to 2.1.21:

| @@ -1584,30 +1584,28 @@
|     /* rely on prior BufferOverflow() and on strlen(CF_SAVED) < 
CF_BUFFERMARGIN
| */
|     strcat(backup,CF_SAVED);
| 
| -   if (IsItemIn(VREPOSLIST,backup))
| +   if (!IsItemIn(VREPOSLIST,backup))
[...]

I'm not a programmer, so I cannot say if I really found the place where
it broke, but seeing that this went from "item is in list" to "item is
not in list", I'm a little positive about that this is where something
could go wrong.

> Is this how the Repository functionality is supposed to work?  I know I
> could do something like have a tidy: that cleans all the .cfsaved files
> from /etc, but that seems like a hack.

No, it's not supposed to work like that.

Cheers,

Ralph
-- 
Ralph Angenendt......ra@br-online.de | .."Text processing has made it possible
Bayerischer Rundfunk...80300 München | ....to right-justify any idea, even one
Programmbereich.Bayern 3, Jugend und | .which cannot be justified on any other
Multimedia.........Tl:089.5900.16023 | ..........grounds." -- J. Finnegan, USC

Attachment: pgp66oIsMfBKD.pgp
Description: PGP signature


reply via email to

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