help-cfengine
[Top][All Lists]
Advanced

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

Re: files: patterns getting ignored


From: Adrian Phillips
Subject: Re: files: patterns getting ignored
Date: 06 Nov 2001 07:23:56 +0100
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1

>>>>> "Christopher" == Christopher Browne <cbbrowne@cbbrowne.com> writes:

    Christopher> I'm planning to do some "personal account" cleanup
    Christopher> via cfengine; I've got a script that I invoke via the
    Christopher> "#!/usr/bin/cfengine" magic, and it does various bits
    Christopher> of process management AOK.

    Christopher> But then I get to the files: section, and things go a
    Christopher> bit haywire.

    Christopher> My files section looks like:

    Christopher> files: /home/cbbrowne/public_html r=inf
    Christopher> include="*.sgml" m=600 action=fixall
    Christopher> /home/cbbrowne/public_html r=inf include="*.html"
    Christopher> m=664 action=fixall /home/cbbrowne/public_html r=inf
    Christopher> include="*.rtf" m=664 action=fixall
    Christopher> /home/cbbrowne/public_html r=inf include="*.css"
    Christopher> m=664 action=fixall /home/cbbrowne/public_html r=inf
    Christopher> include="*.txt" m=664 action=fixall


    Christopher> When I run this, it proceeds to gripe thusly:

    Christopher> 
---------------------------------------------------------------------
    Christopher> Checking files
    Christopher> 
---------------------------------------------------------------------

    Christopher> Checking file(s) in /home/cbbrowne/public_html
    Christopher> cfengine:chvatal: Skipping ignored root-search
    Christopher> directory /home/cbbrowne/public_html Checking file(s)

Hmm, groping in the dark a bit but ..

Here is the relevant code from wrapper.c :-

   if (S_ISDIR(statbuf.st_mode) && (ptr->recurse != 0))
      {
      if (!IgnoreFile(startpath,ReadLastNode(startpath),ptr->ignores))
         {
         Verbose("%s: Skipping ignored root-search directory 
%s\n",VPREFIX,startpath);
         
CheckExistingFile(startpath,ptr->plus,ptr->minus,ptr->action,ptr->uid,ptr->gid,&statbuf,ptr,ptr->acl_aliases);
         }

This is in CheckFileWrapper which is called by ExpandWildCardsAndDo
which does :-

 /* This function recursively expands a path containing wildcards */
 /* and executes the function pointed to by function for each     */
 /* matching file or directory                                    */

Okay, its too early for me to check any further (brain hurts). Hope
this helps somewhat.

Sincerely,

Adrian Phillips

-- 
Your mouse has moved.
Windows NT must be restarted for the change to take effect.
Reboot now?  [OK]



reply via email to

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