> Maybe it is useful for someone else. I have written an bundle that reports
> back if a client did not see the policy server for an hour. That is the
> smallest value that can be set.  I realy wanted to use 0.15 (each quarter
> of a hour)
>
> ## Report if we lost contact with our policy server for an hour
> #
> bundle agent cfengine3_check_server_connectivity
> {
> vars:
>    "myhosts" slist =>  { hostsseen("1","notseen","address") };
>
> classes:
>    "cfengine_no_connectivity"   expression =>  reglist("@(myhosts)",
> escape("$(g.policyserver)"));
>
> reports:
>    cfengine_no_connectivity::
>     "Not seen cfengine3 policy server: $(g.policyserver) for at least a
> hour";
> }
>
>

Just a warning for this bundle when i run in verbose mode i get strange 
messages like:
cf3  !! Duplicate selection of value for variable "myhosts" in scope test
cf3  !! Rule from /var/tmp/lastseen.cf at/before line 17

multiple time. I have reported this: 
https://cfengine.com/bugtracker/view.php?id=448

This is with a version cf3 from trunk

regards
-- 
********************************************************************
*  Bas van der Vlies                    e-mail: b...@sara.nl       *
*  SARA - Academic Computing Services   Amsterdam, The Netherlands *
********************************************************************
_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to