No subject


Thu Jan 29 11:41:19 CET 2009


connection between these two servers.

Thanks
JayaPrakash


On Tue, Mar 31, 2009 at 3:48 PM, Anca Vamanu <anca at opensips.org> wrote:

> JayaPrakash wrote:
>
>> Hi All,
>>
>> I installed Opensips 1.5. I enabled XMPP module in component mode.
>> Jabber server (ejabberd 2.0.1) is running in the same machine.
>> I am trying to communicate between Opensips and Jabber server.
>> Opensips is configured with XMPP as described below.
>>
>> **********************************************************************************
>> listen=udp:192.168.1.130:5060 <http://192.168.1.130:5060>
>> loadmodule "xmpp.so"
>> # -- xmpp parameters --
>> modparam("xmpp", "domain_separator", "*")
>> modparam("xmpp", "gateway_domain", "my_host_name.com <
>> http://my_host_name.com>")
>> modparam("xmpp", "xmpp_domain", "my_host_name.com <
>> http://my_host_name.com>")
>> modparam("xmpp", "xmpp_host", "my_host_name.com <http://my_host_name.com
>> >")
>> modparam("xmpp", "backend", "component")
>> modparam("xmpp", "xmpp_port", 5347)
>> modparam("xmpp", "xmpp_password", "secret")
>>
>> #------------XMPP related at route -----------------------------
>>        if (method == "MESSAGE") {
>>                log("*** xmpp-handled MESSAGE message.\n");
>>                if (xmpp_send_message()) {
>>                        t_reply("200", "Accepted");
>>                } else {
>>                        t_reply("404", "Not found");
>>                }
>>                return;
>>        }
>>
>> *************************************************************************************
>> When the server is running it is keep on throwing the following error.
>>  ERROR:xmpp:net_connect: connect() failed: Connection refused
>>
>> Coming to jabber server (here it is ejabberd), it is able to allow
>> connections from outer xmpp servers.(It is able to connect to Gtalk and
>> communicate with it)
>> Can you please give me a suggesion to fix this issue.
>>
>> Thanks
>> Jp
>>
>>
>
> As I have mentioned in the other e-mail, the "xmpp_host"parameter must be
> set to the host of the jabber server.
> For example, for setting the host of the ejabber server you have to edit
> the /etc/ejabberd/ejabberd.cfg and pun in the Hostname section your domain
> name:
>
> %% Hostname
> {hosts, ["my_host_name.com <http://my_host_name.com>"]}.
>
> regards,
> Anca Vamanu
>
>  ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>>
>
>

--000e0cd2bd52c2c031046669804d
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Hi Anca,<br><br>As you said, ejabberd is configured to connect to opensips =
in component mode at port 5347, as described below.<br>=A0 {5347, ejabberd_=
service, [<br>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0=A0=A0=A0=A0=A0 {access, all},<br>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 {shaper_rule, fast},<br>
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0 {ip, {127, 0, 0, 1}},<br>=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 {hosts, [&quot;<a href=3D"http://dev.ongo=
biz.com">dev.ongobiz.com</a>&quot;], [{password, &quot;secret&quot;}]}<br>=
=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=
=A0 ]}<br>
The xmpp_host name is specified as follow, in ejabberd.cfg file.<br>{hosts,=
 [&quot;<a href=3D"http://dev.ongobiz.com">dev.ongobiz.com</a>&quot;]}.<br>=
<br>Now ejabberd is running.<br>Opensips is configured with the following p=
arams of XMPP and pua_xmpp=A0 modules.<br>
***************************************************************************=
*****************************************<br># ----- presence params -----<=
br>/* uncomment the following lines if you want to enable presence */<br>
modparam(&quot;presence|presence_xml&quot;, &quot;db_url&quot;, &quot;mysql=
://opensips:opensipsrw at localhost/opensips&quot;)<br>modparam(&quot;presence=
_xml&quot;, &quot;force_active&quot;, 1)<br>modparam(&quot;presence&quot;, =
&quot;server_address&quot;, &quot;sip:<a href=3D"http://192.168.1.130:5060"=
>192.168.1.130:5060</a>&quot;)<br>
<br>#---------Pua and pua_xmpp params.-------------<br>modparam(&quot;pua&q=
uot;, &quot;db_url&quot;, &quot;mysql://opensips:opensipsrw@localhost/opens=
ips&quot;)<br>modparam(&quot;pua_xmpp&quot;, &quot;server_address&quot;, &q=
uot;sip:<a href=3D"http://192.168.1.130:5060">192.168.1.130:5060</a>&quot;)=
<br>
<br># -- xmpp parameters --<br>modparam(&quot;xmpp&quot;, &quot;domain_sepa=
rator&quot;, &quot;*&quot;)<br>modparam(&quot;xmpp&quot;, &quot;gateway_dom=
ain&quot;, &quot;<a href=3D"http://dev.ongobiz.com">dev.ongobiz.com</a>&quo=
t;)<br>
modparam(&quot;xmpp&quot;, &quot;xmpp_domain&quot;, &quot;<a href=3D"http:/=
/dev.ongobiz.com">dev.ongobiz.com</a>&quot;)<br>modparam(&quot;xmpp&quot;, =
&quot;xmpp_host&quot;, &quot;<a href=3D"http://dev.ongobiz.com">dev.ongobiz=
.com</a>&quot;)<br>
modparam(&quot;xmpp&quot;, &quot;backend&quot;, &quot;component&quot;)<br>m=
odparam(&quot;xmpp&quot;, &quot;xmpp_port&quot;, 5347)<br>modparam(&quot;xm=
pp&quot;, &quot;xmpp_password&quot;, &quot;secret&quot;)<br>***************=
***************************************************************************=
**********************<br>
above, <a href=3D"http://dev.ongobiz.com">dev.ongobiz.com</a> is the host n=
ame of my machine. So gateway_domain and xmpp_domain will be similar.<br>xm=
pp_host is taken from above config file of ejabbed.({hosts, [&quot;<a href=
=3D"http://dev.ongobiz.com">dev.ongobiz.com</a>&quot;]}.)<br>
Even now, opensips is saying that connection with ejabbed is refused.<br><b=
r>ERROR:xmpp:net_connect: connect() failed: Connection refused<br><br>From =
ejabberd server side, there is no log information relating to connection be=
tween these two servers.<br>
<br clear=3D"all">Thanks<br>JayaPrakash<br>
<br><br><div class=3D"gmail_quote">On Tue, Mar 31, 2009 at 3:48 PM, Anca Va=
manu <span dir=3D"ltr">&lt;<a href=3D"mailto:anca at opensips.org">anca at opensi=
ps.org</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"=
border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; paddi=
ng-left: 1ex;">
JayaPrakash wrote:<br>
<blockquote class=3D"gmail_quote" style=3D"border-left: 1px solid rgb(204, =
204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class=3D"im"=
>
Hi All,<br>
<br>
I installed Opensips 1.5. I enabled XMPP module in component mode.<br>
Jabber server (ejabberd 2.0.1) is running in the same machine.<br>
I am trying to communicate between Opensips and Jabber server.<br>
Opensips is configured with XMPP as described below.<br>
***************************************************************************=
*******<br></div>
listen=3Dudp:<a href=3D"http://192.168.1.130:5060" target=3D"_blank">192.16=
8.1.130:5060</a> &lt;<a href=3D"http://192.168.1.130:5060" target=3D"_blank=
">http://192.168.1.130:5060</a>&gt;<div class=3D"im"><br>
loadmodule &quot;xmpp.so&quot;<br>
# -- xmpp parameters --<br>
modparam(&quot;xmpp&quot;, &quot;domain_separator&quot;, &quot;*&quot;)<br>=
</div>
modparam(&quot;xmpp&quot;, &quot;gateway_domain&quot;, &quot;<a href=3D"htt=
p://my_host_name.com" target=3D"_blank">my_host_name.com</a> &lt;<a href=3D=
"http://my_host_name.com" target=3D"_blank">http://my_host_name.com</a>&gt;=
&quot;)<br>

modparam(&quot;xmpp&quot;, &quot;xmpp_domain&quot;, &quot;<a href=3D"http:/=
/my_host_name.com" target=3D"_blank">my_host_name.com</a> &lt;<a href=3D"ht=
tp://my_host_name.com" target=3D"_blank">http://my_host_name.com</a>&gt;&qu=
ot;)<br>

modparam(&quot;xmpp&quot;, &quot;xmpp_host&quot;, &quot;<a href=3D"http://m=
y_host_name.com" target=3D"_blank">my_host_name.com</a> &lt;<a href=3D"http=
://my_host_name.com" target=3D"_blank">http://my_host_name.com</a>&gt;&quot=
;)<div class=3D"im">
<br>
modparam(&quot;xmpp&quot;, &quot;backend&quot;, &quot;component&quot;)<br>
modparam(&quot;xmpp&quot;, &quot;xmpp_port&quot;, 5347)<br>
modparam(&quot;xmpp&quot;, &quot;xmpp_password&quot;, &quot;secret&quot;)<b=
r>
<br>
#------------XMPP related at route -----------------------------<br>
 =A0 =A0 =A0 =A0if (method =3D=3D &quot;MESSAGE&quot;) {<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0log(&quot;*** xmpp-handled MESSAGE message.=
\n&quot;);<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (xmpp_send_message()) {<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0t_reply(&quot;200&quot;, &q=
uot;Accepted&quot;);<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0} else {<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0t_reply(&quot;404&quot;, &q=
uot;Not found&quot;);<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0}<br>
 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0return;<br>
 =A0 =A0 =A0 =A0}<br>
***************************************************************************=
**********<br>
When the server is running it is keep on throwing the following error.<br>
=A0ERROR:xmpp:net_connect: connect() failed: Connection refused<br>
<br>
Coming to jabber server (here it is ejabberd), it is able to allow connecti=
ons from outer xmpp servers.(It is able to connect to Gtalk and communicate=
 with it)<br>
Can you please give me a suggesion to fix this issue.<br>
<br>
Thanks<br>
Jp<br>
 =A0<br>
</div></blockquote>
<br>
As I have mentioned in the other e-mail, the &quot;xmpp_host&quot;parameter=
 must be set to the host of the jabber server.<br>
For example, for setting the host of the ejabber server you have to edit th=
e /etc/ejabberd/ejabberd.cfg and pun in the Hostname section your domain na=
me:<br>
<br>
%% Hostname<br>
{hosts, [&quot;<a href=3D"http://my_host_name.com" target=3D"_blank">my_hos=
t_name.com</a> &lt;<a href=3D"http://my_host_name.com" target=3D"_blank">ht=
tp://my_host_name.com</a>&gt;&quot;]}.<br>
<br>
regards,<br>
Anca Vamanu<br>
<br>
<blockquote class=3D"gmail_quote" style=3D"border-left: 1px solid rgb(204, =
204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
------------------------------------------------------------------------<br=
>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href=3D"mailto:Users at lists.opensips.org" target=3D"_blank">Users at lists.o=
pensips.org</a><br>
<a href=3D"http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target=
=3D"_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br=
>
 =A0<br>
</blockquote>
<br>
</blockquote></div><br>

--000e0cd2bd52c2c031046669804d--



More information about the Users mailing list