<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hello,</p>
    <p>do you mean that it writes "ERROR" in the prefix of the log
      message?</p>
    <p>That is the default log level for xlog() function. You can write
      to another log level by providing it as first parameter:</p>
    <p>xlog("L_INFO", "$mb");</p>
    <p>Cheers,<br>
      Daniel<br>
    </p>
    <div class="moz-cite-prefix">On 26.12.18 22:24, Andrew Chen wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAEytwJ0SvLQGuceUw0ofAx2Tcp5znJtvwLPO6nQ5o6o2kQzgLw@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">Hey community,
            <div><br>
            </div>
            <div>I'm currently trying to config our new 5.1.2 kamailio
              server and I want to xlog $mb.  Whenever I do this, I get
              an ERROR logged to my syslog </div>
            <div><br>
            </div>
            <div>Dec 26 21:15:58 sjomainkama55 /usr/sbin/kamailio[5954]:
              {1 1 INVITE <padding>@<padding>} ERROR:
              <script>: INVITE sip:<padding>@<a
                href="http://sjomainkama55.a.fuzemeeting.com:443"
                moz-do-not-send="true">sjomainkama55.a.fuzemeeting.com:443</a><br>
            </div>
            <div><br>
            </div>
            <div>Does anyone know why this is?<br>
            </div>
            <div><br>
            </div>
            <div>Also, I noticed I can't get rid of #012#015 at all.  I
              modified the rsyslogd.conf file as instructed here:</div>
            <div><br>
            </div>
            <div>"<span style="color:rgb(0,0,0);font-family:"Times
                New Roman";font-size:medium">i need to add the next
                line to /etc/rsyslog.conf
                "$EscapeControlCharactersOnReceive off"</span><span
                style="color:rgb(0,0,0);font-family:"Times New
                Roman";font-size:medium"> </span></div>
            <br class="gmail-Apple-interchange-newline">
            <div>
              <div>and when I did this, the control characters disappear
                but all it printed out was the first line of the SIP
                message.  I also try to assign $mb to a $var() and do a
                {re.replace} on </div>
              <div>that string and that didn't work either.</div>
              <div><br>
              </div>
              <div>I ended up having to create a side script to parse
                the whole /var/log/syslog and do regex replace the
                #012#015 with real newline which is not what I really
                want for me or anyone else who needs to analyze the
                Kamailio logs.</div>
              <div><br>
              </div>
              <div>Please advise.</div>
              <div><br>
              </div>
              <div>Thanks.</div>
              <div><br>
              </div>
              -- <br>
              <div dir="ltr" class="gmail_signature">
                <div dir="ltr">
                  <div dir="ltr">
                    <div dir="ltr" style="font-size:12.8px">Andy Chen</div>
                    <div dir="ltr" style="font-size:12.8px">
                      <div><a href="mailto:achen@thinkingphones.com"
                          target="_blank" moz-do-not-send="true">achen@</a><a
                          href="http://fuze.com" target="_blank"
                          moz-do-not-send="true">fuze.com</a><br>
                      </div>
                      <div><br>
                        <br>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">*Confidentiality
        Notice: The information contained in this e-mail and any</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">attachments
        may be confidential. If you are not an intended recipient, you</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">are
        hereby notified that any dissemination, distribution or copying
        of this</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">e-mail
        is strictly prohibited. If you have received this e-mail in
        error,</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">please
        notify the sender and permanently delete the e-mail and any</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">attachments
        immediately. You should not retain, copy or use this e-mail or</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">any
        attachment for any purpose, nor disclose all or any part of the</span><br
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">
      <span
style="color:rgb(51,51,51);font-family:Arial,sans-serif;font-size:14px;background-color:rgb(255,255,255)">contents
        to any other person. Thank you.*</span>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Kamailio (SER) - Users Mailing List
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.kamailio.org">sr-users@lists.kamailio.org</a>
<a class="moz-txt-link-freetext" href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
    </blockquote>
    <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a>
<a class="moz-txt-link-abbreviated" href="http://www.twitter.com/miconda">www.twitter.com/miconda</a> -- <a class="moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda">www.linkedin.com/in/miconda</a>
Kamailio World Conference - May 6-8, 2019 -- <a class="moz-txt-link-abbreviated" href="http://www.kamailioworld.com">www.kamailioworld.com</a>
Kamailio Advanced Training - Mar 4-6, 2019 in Berlin; Mar 25-27, 2019, in Washington, DC, USA -- <a class="moz-txt-link-abbreviated" href="http://www.asipto.com">www.asipto.com</a></pre>
  </body>
</html>