<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi Bogdan,<br>
    <br>
    I found the issue, in opensips 1.11.5, default root path is "xmlrpc"
    and in opensips 2.1 the default is "RPC2"<br>
    <br>
    If you ask an opensips 2.1 with wrong root path, the response is 400
    Bad request.<br>
    <br>
    After modify my script, it's ok, <br>
    <br>
    thanks for your help.<br>
    <br>
    <div class="moz-cite-prefix">Le 01/09/2015 21:21, Bogdan-Andrei
      Iancu a écrit :<br>
    </div>
    <blockquote cite="mid:55E5FAC3.6060605@opensips.org" type="cite">
      <meta content="text/html; charset=windows-1252"
        http-equiv="Content-Type">
      <tt>Hi Alan,<br>
        <br>
        Just tested with a simple Python script (with xmlrpclib class)
        like:<br>
        <br>
            import xmlrpclib<br>
            opensips = xmlrpclib.ServerProxy('<a moz-do-not-send="true"
          class="moz-txt-link-freetext"
          href="http://127.0.0.1:8888/RPC2">http://127.0.0.1:8888/RPC2</a>')<br>
            print opensips.get_statistics('tm:')<br>
        <br>
        <br>
        And here is the successful output:<br>
        <br>
        T 2015/09/01 22:18:59.709381 127.0.0.1:41540 -&gt;
        127.0.0.1:8888 [AP]<br>
        POST /RPC2 HTTP/1.1.<br>
        Host: 127.0.0.1:8888.<br>
        Accept-Encoding: gzip.<br>
        User-Agent: xmlrpclib.py/1.0.1 (by <a moz-do-not-send="true"
          class="moz-txt-link-abbreviated"
          href="http://www.pythonware.com">www.pythonware.com</a>).<br>
        Content-Type: text/xml.<br>
        Content-Length: 161.<br>
        .<br>
        &lt;?xml version='1.0'?&gt;<br>
        &lt;methodCall&gt;<br>
        &lt;methodName&gt;get_statistics&lt;/methodName&gt;<br>
        &lt;params&gt;<br>
        &lt;param&gt;<br>
        &lt;value&gt;&lt;string&gt;tm:&lt;/string&gt;&lt;/value&gt;<br>
        &lt;/param&gt;<br>
        &lt;/params&gt;<br>
        &lt;/methodCall&gt;<br>
        <br>
        <br>
        T 2015/09/01 22:18:59.710212 127.0.0.1:8888 -&gt;
        127.0.0.1:41540 [AP]<br>
        HTTP/1.1 200 OK.<br>
        Content-Length: 409.<br>
        Content-Type: text/xml; charset=utf-8.<br>
        Date: Tue, 01 Sep 2015 19:18:59 GMT.<br>
        .<br>
        &lt;?xml version="1.0" encoding="UTF-8"?&gt;.<br>
        &lt;methodResponse&gt;.<br>
        &lt;params&gt;.<br>
        &lt;param&gt;&lt;value&gt;&lt;string&gt;tm:received_replies:: 0<br>
        tm:relayed_replies:: 0<br>
        tm:local_replies:: 0<br>
        tm:UAS_transactions:: 0<br>
        tm:UAC_transactions:: 0<br>
        tm:2xx_transactions:: 0<br>
        tm:3xx_transactions:: 0<br>
        tm:4xx_transactions:: 0<br>
        tm:5xx_transactions:: 0<br>
        tm:6xx_transactions:: 0<br>
        tm:inuse_transactions:: 0<br>
        &lt;/string&gt;&lt;/value&gt;&lt;/param&gt;.<br>
        &lt;/params&gt;.<br>
        &lt;/methodResponse&gt;.<br>
      </tt><tt><br>
      </tt><tt>Regards,</tt><br>
      <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
      <div class="moz-cite-prefix">On 01.09.2015 12:33, Alain Bieuzent
        wrote:<br>
      </div>
      <blockquote cite="mid:55E570E5.9020808@free.fr" type="cite">
        <meta http-equiv="content-type" content="text/html;
          charset=windows-1252">
        Hi all,<br>
        <br>
        I'trying to migrate my opensisps 1.11.5 to 2.1 and i have a
        probleme with xmlrpc_ng<br>
        <br>
        When i post a request to my opensips 1.11.5, it work :<br>
        <br>
        <small><small>    HTTP/1.1 200 OK    <br>
                Content-Length: 452<br>
                Content-Type: text/xml; charset=utf-8<br>
                Date: Tue, 01 Sep 2015 09:23:31 GMT<br>
            <br>
                &lt;?xml version="1.0" encoding="UTF-8"?&gt;<br>
                &lt;methodResponse&gt;<br>
                &lt;params&gt;<br>
               
            &lt;param&gt;&lt;value&gt;&lt;string&gt;tm:received_replies::
            1331345<br>
                tm:relayed_replies:: 902120<br>
                tm:local_replies:: 422824<br>
                tm:UAS_transactions:: 587390<br>
                tm:UAC_transactions:: 41524<br>
                tm:2xx_transactions:: 482865<br>
                tm:3xx_transactions:: 0<br>
                tm:4xx_transactions:: 137567<br>
                tm:5xx_transactions:: 7074<br>
                tm:6xx_transactions:: 171<br>
                tm:inuse_transactions:: 2077<br>
                &lt;/string&gt;&lt;/value&gt;&lt;/param&gt;<br>
                &lt;/params&gt;<br>
                &lt;/methodResponse&gt;</small></small><br>
        <br>
        but when i run the same request on my opensips 2.1, the module
        return a 400 Bad Request.<br>
            <small><small>HTTP/1.1 400 Bad Request<br>
                Content-Length: 46<br>
                Content-Type: text/xml; charset=utf-8<br>
                Date: Tue, 01 Sep 2015 09:23:42 GMT</small></small><br>
        <br>
        Is there a change in opensips 2.1 ?<br>
        <br>
        my request :<br>
        <small><small><br>
            &lt;?xml version='1.0'?&gt;<br>
            &lt;methodCall&gt;<br>
            &lt;methodName&gt;get_statistics&lt;/methodName&gt;<br>
            &lt;params&gt;<br>
 &lt;param&gt;&lt;value&gt;&lt;string&gt;tm:&lt;/string&gt;&lt;/value&gt;&lt;/param&gt;<br>
            &lt;/params&gt;<br>
            &lt;/methodCall&gt;<br>
            <br>
            <big><big>thanks</big></big><br>
          </small></small> <br>
        <fieldset class="mimeAttachmentHeader"></fieldset>
        <br>
        <pre wrap="">_______________________________________________
Users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
      </blockquote>
      <br>
    </blockquote>
    <br>
  </body>
</html>