Page 2 of 2

Re: Inbound Email Configuration problem

Posted: Thu May 02, 2019 11:23 am
by stf_792
It sort of working.

Inbound configuration did not change FROM address automatically as promised :) , no big deal, I changed it sending configuration to match.

I simulated failure and got email with

Code: Select all

---- Respond above this line ----

***** Nagios XI Alert *****

Nagios has detected a problem with this service.
I typed ack and reply.

Shortly I got message saying

Code: Select all

Missing response command. Did you send a valid command?

Valid commands: https://assets.nagios.com/downloads/nagiosxi/docs/Inbound-Email-Commands-for-Nagios-XI.pdf

- Nagios XI System

Re: Inbound Email Configuration problem

Posted: Thu May 02, 2019 3:05 pm
by tgriep
If the reply with the ack message is not sent as text, it will not be recognized as the html code in the reply caused the command to fail.
This is a known issue and should be fixed in the next release if XI.

If you edit this file

Code: Select all

/usr/local/nagiosxi/html/includes/components/xicore/xicore.inc.php
and add this line

Code: Select all

$line = strip_tags($line);
Under line 600 like this

Code: Select all

// Verify if line is empty and continue
                $line = trim($msg_lines[$x]);                            <== line 600
                $line = strip_tags($line);
                $line = strtolower(str_replace(' ', '', $line));
                if (empty($line)) {
That will strip out the html code so the command will be recognized.

Re: Inbound Email Configuration problem

Posted: Fri May 03, 2019 11:13 am
by stf_792
That did the trick - everything is working now.

Re: Inbound Email Configuration problem

Posted: Fri May 03, 2019 11:19 am
by scottwilkerson
stf_792 wrote:That did the trick - everything is working now.
Great!

Locking thread