Xymon Mailing List Archive search

Question on Alert Notifications

list Takeshi Nishioka
Wed, 30 Nov 2005 13:54:17 +0900
Message-Id: <user-f84683466111@xymon.invalid>

Would you please let us know how to edit Sender entry. It's "Hobbit <user-20f528d1c120@xymon.invalid>" in my environment.


On Wed, 23 Nov 2005 13:24:06 +0100
user-ce4a2c883f75@xymon.invalid (Henrik Stoerner) wrote:
On Wed, Nov 23, 2005 at 07:13:00AM -0500, Bill Perez wrote:
Thanks Thomas.
I am trying to find out how to take the word 'Hobbit' out of the alert
subject and didn't find any info on that in the Configuring Alerts page.
That's because it isn't configurable. You'll have to edit the hobbit-4.1.2p1/hobbitd/do_alert.c file - look for the "message_subject"
routine. In there you'll find some code that goes like this:

        switch (alert->state) {
	  case A_PAGING:
	  case A_ACKED:
		subjfmt = (include_configid ? "Hobbit [%d] %s:%s %s [cfid:%d]" :  "Hobbit [%d] %s:%s %s");

The "%s" and "%d" are placeholders for the hostname, testname etc. But if you just want to delete the word "Hobbit", you can just delete it.
Run "make", stop Hobbit, run "make install" and start Hobbit after the
change.


Regards,
Henrik