help-cfengine
[Top][All Lists]
Advanced

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

problem with AppendIfNoLineMatching


From: Frank Smith
Subject: problem with AppendIfNoLineMatching
Date: Fri, 16 Jul 2004 11:08:43 -0500

AppendIfNoLineMatching isn't working the way I expect, perhaps I
misunderstand how it's supposed to work and someone can point out
the error in my assumptions.

In my editfiles section I have:

 myclass::
  { /etc/inetd.conf
  SetLine "amanda  dgram   udp     wait    backup  /usr/local/libexec/amandad 
amandad"
  AppendIfNoLineMatching "^amanda*"
  DefineClasses "NEEDS_INETD_RESTART"
  }

I thought that if there wasn't a line in the file starting with
'amanda' that it would append the line defined by SetLine.  However,
what is actually happening is that the line is appended on every
run, so I end up with mmultiple copies of that line in the file.

Does ^ not match the begining of a line or do I perhaps need to
escape it? What am I overlooking?

Thanks,
Frank






reply via email to

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