<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 31 July 2018 at 05:35, Gabo Suárez <span dir="ltr"><<a href="mailto:jgsuareza1984@gmail.com" target="_blank">jgsuareza1984@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail-m_-4802982056649259937gmail_signature"><div dir="ltr">

<span style="font-size:12.8px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Hi greetings from Ecuador,</span></div></div></div></blockquote><div><br></div><div>Hello Gabo</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail-m_-4802982056649259937gmail_signature"><div dir="ltr"><span style="color:rgb(33,33,33);white-space:pre-wrap">Please your help, I need that the XYMON monitoring mails include the IP of the host-client</span> <br></div></div></div></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail-m_-4802982056649259937gmail_signature"><div dir="ltr"><br></div><div dir="ltr"><span style="color:rgb(33,33,33);text-align:left;white-space:pre-wrap;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">How do i do it?</span> </div></div></div></blockquote><div><br></div><div>The IP address of the client is in the variable $MACHIP. I think this variable is only available to scripts, not the standard MAIL function. To do this, you can create a script that sends an email.</div><div><br></div><div>For example, use this in alerts.cfg:</div><div><br></div><div>HOST=<a href="http://client.host.name">client.host.name</a></div><div>    SCRIPT /usr/local/bin/mailscript placeholder FORMAT=TEXT</div><div><br></div><div>Then create a script that goes something like this:</div><div><br></div><div>#!/bin/sh</div><div>mail -s "$BBHOSTNAME $BBSVCNAME - $BBCOLORLEVEL $ACKCODE $RECOVERED $DOWNSECMSG" $RCPT <<EOF<br></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">$BBALPHAMSG</span><br></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">IP is $MACHIP</span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">EOF</span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div>For more information about the Xymon alert environment variables, check out the Alerts documentation:<br></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><a href="http://xymon.sourceforge.net/xymon/help/xymon-alerts.html">http://xymon.sourceforge.net/xymon/help/xymon-alerts.html</a></span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"> and the alerts.cfg man page:</span></div><div><span style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><a href="http://xymon.sourceforge.net/xymon/help/manpages/man5/alerts.cfg.5.html">http://xymon.sourceforge.net/xymon/help/manpages/man5/alerts.cfg.5.html</a><br></span></div><div><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div>J<br></div><div><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div></div></div></div>