Hi everyone,<br><br>As you may have already been aware by now, we're here to stay. :)<br><br>Here's one interesting problem (and maybe simple) for you: We've seen that "HOST=%^asd$" matches both hosts named "asd" and "asdf", not respecting the "$" at the end. Can you guys please confirm that regex matching for "HOST=" does not care about the "$" sign?<br>

<br>For those that need some expanded case-study (all others can now stop), here's the story behind: we are managing various servers of ours and our customers. Due to the fact that we do not control DNS entries for all these machines we have come up with a naming scheme like this:<br>
<br>
--- cut here ---<br>junkyard-starbox # clientID=junkyard, starbox=actual machine<br>junkyard-starbox-v_trash # v_trash=vserver named trash running on starbox<br>junkyard-starbox-v_trashcan # v_trashcan=vserver named trashcan running on starbox<br>

junkyard-starbox-x_dustbin # x_dustbin=xen server running on starbox<br>--- and here ---<br><br>We need to send these "special" alerts:<br>* ONLY cto@junkyard.tld for events on junkyard-starbox-v_trash<br>* ONLY ceo@junkyard.tld for events on junkyard-starbox-x_dustbin<br>
<br>Also, we need to send these alerts for all other hosts & events:<br>* stars@sysadmins.tld for purple, yellow & red w/ REPEAT=60<br>* cto@sysadmins.tld for red w/ DURATION>30 and REPEAT=60<br>* cto@sysadmins.tld for yellow&purple w/ DURATION>60 and REPEAT=60<br>
<br>Exercising our brain muscles we came up with these:<br>--- cut here ---<br>#alert CTO for v_trash<br>HOST=junkyard-starbox-v_trash<br>  MAIL=cto@junkyard.tld<br><br>#alert CEO for x_dustbin<br>HOST=junkyard-starbox-x_dustbin<br>
  MAIL=ceo@junkyard.tld<br><br>#stop alerting for the private boxes above<br>HOST=*<br>  IGNORE HOST=%^junkyard-starbox-(v_trash|x_dustbin)$<br><br>HOST=* COLOR=purple,yellow<br>  MAIL=stars@sysadmins.tld REPEAT=60 RECOVERED NOTICE<br>
  MAIL=cto@sysadmins.tld DURATION>60 REPEAT=60 RECOVERED NOTICE<br><br>HOST=* COLOR=red<br>  MAIL=stars@sysadmins.tld REPEAT=10 RECOVERED NOTICE<br>  MAIL=cto@sysadmins.tld DURATION>30 REPEAT=60 RECOVERED NOTICE<br>
--- and here ---<br><br>However, even with the "$" at the end of our regex we are no longer receiving any alerts for v_trashcan because the regex wrongly matches on the "IGNORE HOST=" line. We could use 2 lines to match each host on its own line but that's not the point of this exercise.<br>
<br>So, can anyone confirm our finding?<br>-- <br>kN<br>