Hi,

Is there a typo in your process_select body?
You seem to take an argument c, but try to expand p..

--
Regards,
Eystein

2010/3/26  <nwat...@symcor.com>:
> Greetings,
>
> I'm trying to make a promise that will kill procs that use too much
> memory.
>
> Using version Community 3.0.2.  Upgrading soon but need to work with this
> temporarily.
>
> My target for this test:
> [nwat...@unxxhd01 inputs]$ ps -eo rss,args|grep cf-monitord
> 105152 /var/cfengine/bin/cf-monitord
>
> My policy
> body common control {
>    bundlesequence => { "neil" };
>
>    #inputs => { "cfengine_stdlib.cf" };
> }
>
> bundle agent neil {
>
>    processes:
>
>        "cf-monitord"
>            process_select => memleak("cf-monitord"),
>            signals => { "stop", "term", "kill" };
>
> }
>
> body process_select memleak(c) {
>    rsize => irange("100000","200000");
>    command => "${p}";
>    process_result => "command.rsize";
> }
>
> Command:
> ../bin/cf-agent -IKnf ./foo.cf
>
> Expected results
> Should see a warning printed about having to stop, term or kill
> cf-monitord.
>
> Actual results
> Returns no output.  Verbose output returns
> cf3  -- Matches in range for cf-monitord - process count promise kept
> cf3
> cf3      +  Private classes augmented:
> cf3
> cf3      -  Private classes diminished:
> cf3
> and
> cf3 Observe process table with /bin/ps auxw
> cf3 Outcome of version (not specified) (agent-0): Promises observed to be
> kept 100%, Promises repaired 0%, Promises not repaired 0%
>
> Have I done something wrong?
>
> Sincerely,
> --
> Neil Watson
> 416-673-3465
>
>
>
> CONFIDENTIALITY WARNING
> This communication, including any attachments, is for the exclusive use of 
> addressee and may contain proprietary and/or confidential information. If you 
> are not the intended recipient, any use, copying, disclosure, dissemination 
> or distribution is strictly prohibited. If you are not the intended 
> recipient, please notify the sender immediately by return e-mail, delete this 
> communication and destroy all copies.
>
> AVERTISSEMENT RELATIF À LA CONFIDENTIALITÉ
> Ce message, ainsi que les pièces qui y sont jointes, est destiné à l’usage 
> exclusif de la personne à laquelle il s’adresse et peut contenir de 
> l’information personnelle ou confidentielle. Si le lecteur de ce message n’en 
> est pas le destinataire, nous l’avisons par la présente que toute diffusion, 
> distribution, reproduction ou utilisation de son contenu est strictement 
> interdite. Veuillez avertir sur-le-champ l’expéditeur par retour de courrier 
> électronique et supprimez ce message ainsi que toutes les pièces jointes.
>
> _______________________________________________
> Help-cfengine mailing list
> Help-cfengine@cfengine.org
> https://cfengine.org/mailman/listinfo/help-cfengine
>
>
_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to