<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:΢ÈíÑźÚ
}
--></style>
</head>
<body class='hmmessage'>
Hello Daniel,<BR>&nbsp;<BR>Thanks for your suggestion.<BR>I&nbsp; search on the net and find there's some limits on the Solaris in the limits.h:<BR><BR>#define _XOPEN_IOV_MAX&nbsp; 16&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* max # iovec/process with readv()/writev() */<BR>#define _XOPEN_NAME_MAX 255&nbsp;&nbsp;&nbsp;&nbsp; /* max # bytes in filename excluding null */<BR>#define _XOPEN_PATH_MAX 1024&nbsp;&nbsp;&nbsp; /* max # bytes in a pathname */<BR>#define IOV_MAX&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; _XOPEN_IOV_MAX<BR><BR>And <BR>The writev() function may fail if:<BR>&nbsp;&nbsp;&nbsp;&nbsp; EINVAL&nbsp;&nbsp;&nbsp; The iovcnt argument was less than or equal to 0 or<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; greater&nbsp; than {IOV_MAX}; one of the iov_len values<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; in the iov array was negative; or the sum&nbsp; of&nbsp; the<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; iov_len&nbsp; values&nbsp; in&nbsp; the&nbsp; iov&nbsp; array overflowed an<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ssize_t.<BR><BR><FONT color=#0070c0>can't send command to a RTP proxy (Invalid argument/22)</FONT><FONT color=#ff0000> [sock 7 (0), vcnt 18]</FONT><BR><BR>Does it mean the iovcnt is bigger than 16&nbsp;in our case?&nbsp;&nbsp;<BR>&nbsp;<BR>If this is the case, could you suggest how should I modify the nathelper.c?<BR>&nbsp;<BR>Thanks,<BR>Kevin<BR>&nbsp;<BR>
<HR id=stopSpelling>
Date: Mon, 30 Aug 2010 12:25:37 +0200<BR>From: miconda@gmail.com<BR>To: kevin.jzh@hotmail.com<BR>CC: sr-users@lists.sip-router.org<BR>Subject: Re: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR><BR>
<META name=Generator content="Microsoft SafeHTML">Hello,<BR><BR>On 8/26/10 7:18 PM, KevinJin wrote: 
<BLOCKQUOTE cite=mid:SNT110-W53CD83DDEC7E05930A1AEEE6850@phx.gbl>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}

</STYLE>
Hello,<BR>&nbsp;<BR>May I have any comments on the issue? <BR>It blocks the application for monthes.<BR></BLOCKQUOTE><BR>if you are in a hurry, then maybe you can find a consultant. The public mailing list is best effort, many of us having other jobs/travelings/vacations, and cannot guarantee a solution in a given time. Besides, your deployment is particular, running solaris, which may require to get access to fix it.<BR><BR>I looked over the log udp_rtpproxy_log and rtpproxy is found at start up (pids: 24610, ...). Then one of the processes (24613, line 1462) can communicate fine with it for an INVITE. The second process gets the error (24613, line 1630). I assume it may have to do something with the limits of your system. Are there any limits on writev() or UDP on solaris? Not being is solaris devel, maybe you can find someone else to answer if you don't know.<BR>&nbsp;<BR><BR><BR>Cheers,<BR>Daniel<BR><BR>
<BLOCKQUOTE cite=mid:SNT110-W53CD83DDEC7E05930A1AEEE6850@phx.gbl>&nbsp;<BR>Thanks,<BR>Kevin<BR>&nbsp;<BR>
<HR id=ecxstopSpelling>
From: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A>; <A class=ecxmoz-txt-link-abbreviated href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</A><BR>Subject: RE: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR>Date: Thu, 19 Aug 2010 21:24:45 +0800<BR><BR>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
<BR>&nbsp;Hi Daniel,<BR>&nbsp;<BR>Attached please find the logs in zip.<BR>thanks for the help.<BR>&nbsp;<BR>BR<BR>Kevin<BR>
<HR id=ecxstopSpelling>
Date: Wed, 18 Aug 2010 19:14:05 +0200<BR>From: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A>; <A class=ecxmoz-txt-link-abbreviated href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</A><BR>Subject: Re: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR><BR>Hello,<BR><BR>apart of the email with logs, or private data that was required, please continue the discussion on public mailing list.<BR><BR>I need some time to check the logs, the first inconvenience is the rar archive, a zip or tgz is much better -- not a fan of installing binaries from unknown companies on mac os x, going to get unrar from macports. Then solaris is not an OS i have at hand nor use frequently, so need to read about. It is also why using mailing list keeps you in touch with others that can help.<BR><BR>Cheers,<BR>Daniel<BR><BR>On 8/18/10 7:04 PM, KevinJin wrote: 
<BLOCKQUOTE cite=mid:SNT110-W285EEEE5E4F41F3B27B006E69D0@phx.gbl>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
Hi Daniel,<BR>&nbsp;<BR>Does the logs have any hint for what's&nbsp;cause of the issue? I didn't include the user list in the previous email since logs have&nbsp;the actual&nbsp;IP info.<BR>&nbsp;<BR>Thanks in advance!<BR>&nbsp;<BR>Best Regard<BR>Kevin<BR>&nbsp;<BR>
<HR id=ecxstopSpelling>
From: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A><BR>Subject: RE: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR>Date: Tue, 17 Aug 2010 18:51:02 +0800<BR><BR>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
<BR>&nbsp;Hi Daniel,<BR>&nbsp;<BR>Attached are the two kamailio logs, <BR>unix_socket_log&nbsp;&nbsp;&nbsp;&nbsp; --- run rtp proxy wth -s unix:/tmp/rtpproxy.sock<BR>udp_rtpproxy_log&nbsp;&nbsp; --- run rtp proxy with -s udp:*:7722<BR>&nbsp;<BR>Please help to check what's wrong with it.<BR>&nbsp;<BR>Thanks,<BR>Kevin<BR>
<HR id=ecxstopSpelling>
Date: Tue, 17 Aug 2010 11:29:46 +0200<BR>From: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A><BR>CC: <A class=ecxmoz-txt-link-abbreviated href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</A><BR>Subject: Re: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR><BR>Hello,<BR><BR>please send full log at startup, your snippets include just few lines per process, being mixed from different processes.<BR><BR>Cheers,<BR>Daniel<BR><BR><BR>On 8/14/10 3:54 AM, KevinJin wrote: 
<BLOCKQUOTE cite=mid:SNT110-W20E7A24FA08314F3E5D220E6990@phx.gbl>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
Hello,<BR>&nbsp;<BR>
<HR id=ecxstopSpelling>
Date: Thu, 12 Aug 2010 22:16:18 +0200<BR>From: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A><BR>CC: <A class=ecxmoz-txt-link-abbreviated href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</A><BR>Subject: Re: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR><BR>Hello,<BR><BR>On 8/12/10 8:34 PM, KevinJin wrote: 
<BLOCKQUOTE cite=mid:SNT110-W46A39E3EA42A726790A067E6970@phx.gbl>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
Hello,<BR>&nbsp;<BR>
<HR id=ecxstopSpelling>
Date: Thu, 12 Aug 2010 18:46:19 +0200<BR>From: <A class=ecxmoz-txt-link-abbreviated href="mailto:miconda@gmail.com">miconda@gmail.com</A><BR>To: <A class=ecxmoz-txt-link-abbreviated href="mailto:kevin.jzh@hotmail.com">kevin.jzh@hotmail.com</A><BR>CC: <A class=ecxmoz-txt-link-abbreviated href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</A><BR>Subject: Re: [SR-Users] Kamailio 3.0 cann't access the RTPProxy<BR><BR>Hello,<BR><BR>On 8/12/10 4:47 PM, KevinJin wrote: 
<BLOCKQUOTE cite=mid:SNT110-W304E04ABB14FFBFB478657E6970@phx.gbl>
<STYLE>
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:΢ÈíÑźÚ;}
</STYLE>
Hi Daniel,<BR>&nbsp;<BR>What does the log below means? Does it mean nathelper has issue to send the request to RTP proxy first or nathelper doesn't receive a response after sending a request to the rtp proxy?<BR><FONT color=#ff0000>0(27429) ERROR: nathelper [nathelper.c:2457]: can't send command to a RTP proxy<BR></FONT></BLOCKQUOTE>this error is printed when write to socket fails. Do you have any firewall running on the system? Is the user under which kamailio runs allowed to write to sockets? 
<BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr><BR><FONT color=#0070c0>There's no firewall on the system, and I run the kamailio as root, </FONT><BR><FONT color=#0070c0>&nbsp;root 26310&nbsp;&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp; 0 02:24:19 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 /usr/local/kamailio-3.0.2/sbin/kamailio -f /usr/local/kamailio-3.0.2/etc/kamail</FONT><BR><BR>You can edit module_k/nathelper/nathelper.c and replace the line 2457 with:<BR><BR>LM_ERR("can't send command to a RTP proxy (%s/%d)\n", strerror(errno), errno);<BR><BR>Recompile and reinstall. Hopefully will get more hints about what happens.<BR></BLOCKQUOTE><BR>&nbsp;Here is the error message after the change: <BR><FONT color=#0070c0>2(26312) ERROR: nathelper [nathelper.c:2457]: can't send command to a RTP proxy<FONT color=#ff0000>(Invalid argument/22)</FONT><BR>&nbsp;2(26312) ERROR: nathelper [nathelper.c:2492]: proxy &lt;udp:210.13.124.15:7722&gt; does not respond, disable it<BR>&nbsp;2(26312) ERROR: nathelper [nathelper.c:3144]: no available proxies</FONT><BR>what could be the cause?<BR></BLOCKQUOTE>hmm, invalid argurment ... try with this line:<BR><BR>LM_ERR("can't send command to a RTP proxy (%s/%d) [sock %d (%d), vcnt %d]\n",<BR>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; strerror(errno), errno, rtpp_socks[node-&gt;idx], node-&gt;idx, vcnt);<BR><BR>maybe will give some hints about which value is invalid.<BR>&nbsp;<BR><FONT color=#0070c0>&nbsp;Here's the log after the change:</FONT><BR><FONT color=#0070c0>4(14415) ERROR: nathelper [nathelper.c:2457]: can't send command to a RTP proxy (Invalid argument/22) [sock 7 (0), vcnt 18]<BR>&nbsp;4(14415) ERROR: nathelper [nathelper.c:2492]: proxy &lt;udp:210.13.x.y:7722&gt; does not respond, disable it<BR>&nbsp;4(14415) ERROR: nathelper [nathelper.c:3144]: no available proxies</FONT><BR><BR><BR>Can you try as well with an unix file socket:<BR><BR>modparam("nathelper", "rtpproxy_sock", "unix:/tmp/rtpproxy.sock")<BR><BR>then start rtpproxy with -s unix:/tmp/rtpproxy.sock<BR><BR>&nbsp;<BR><FONT color=#0070c0>&nbsp;4(17530) INFO: nathelper [nathelper.c:2369]: rtp proxy &lt;unix:/tmp/rtpproxy.sock&gt; found, support for it re-enabled<BR>&nbsp;3(17529) ERROR: nathelper [nathelper.c:2429]: can't send command to a RTP proxy<BR>&nbsp;3(17529) ERROR: nathelper [nathelper.c:2492]: proxy &lt;unix:/tmp/rtpproxy.sock&gt; does not respond, disable it<BR>&nbsp;3(17529) ERROR: nathelper [nathelper.c:3144]: no available proxies</FONT><BR>&nbsp;<BR><FONT color=#0070c0>Thanks,</FONT><BR><FONT color=#0070c0>Kevin</FONT><BR><BR>I have no solaris (sparc) to try myself...<BR><BR>Cheers,<BR>Daniel<BR></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE><BR><PRE class=ecxmoz-signature>-- 
Daniel-Constantin Mierla
<A class=ecxmoz-txt-link-freetext href="http://www.asipto.com/" target=_blank>http://www.asipto.com/</A>
</PRE>                                               </body>
</html>