Hello,

the error is related to is_method() function, which is exported by textops module -- do you have it loaded?

Anyhow, maybe you should describe what you want to achieve, because the snippet you provided is no related to remote registrations, at least not the form you pasted here. Do you want to register as you start kamailio or you want to sort of forward registrations?

Also, read the README for uac module, there is a section for remote registrations -- you have to add some records to uacreg table and configure uac module to load them -- maybe then you have a better understanding.

Cheers,
Daniel


On 25.07.17 21:38, Anuradha Selvarajan wrote:

 

Hello Daniel,

 

Thank you so much for your reply! Below is my code (just testing our UAC module) and I am unable to start kamailio after adding these codes:

 

I have loadmodule tm and rr as well.

 

loadmodule "uac.so"

 

request_route {

.

.

        $uac_req(ruri)="sip:10.118.226.43";

        uac_req_send();

 

.

.

 

In request route I added the above 2 lines of code and then I tried to start Kamailio…

 

root@emps116:/etc/kamailio# service kamailio start

Job for kamailio.service failed because the control process exited with error code. See "systemctl status kamailio.service" and "journalctl -xe" for details.

root@emps116:/etc/kamailio# systemctl status kamailio.service

● kamailio.service - Kamailio (OpenSER) - the Open Source SIP Server

   Loaded: loaded (/lib/systemd/system/kamailio.service; enabled; vendor preset: enabled)

   Active: failed (Result: exit-code) since Tue 2017-07-25 12:35:45 PDT; 6s ago

  Process: 29891 ExecStart=/usr/sbin/kamailio -P /var/run/kamailio/kamailio.pid -f $CFGFILE -m $SHM_MEMORY -M $PKG_MEMORY -u $USER -g $GROUP (code=exited, status=255)

Main PID: 27407 (code=exited, status=0/SUCCESS)

 

Jul 25 12:35:45 emps116 systemd[1]: Starting Kamailio (OpenSER) - the Open Source SIP Server...

Jul 25 12:35:45 emps116 kamailio[29891]: ERROR: <core> [cfg.y:3235]: yyparse(): cfg. parser: failed to find command is_method (params 1)

Jul 25 12:35:45 emps116 kamailio[29891]: CRITICAL: <core> [cfg.y:3375]: yyerror_at(): parse error in config file /etc/kamailio/kamailio.cfg, line 473, column 24: unknow

Jul 25 12:35:45 emps116 kamailio[29891]: ERROR: bad config file (5 errors)

Jul 25 12:35:45 emps116 kamailio[29891]: loading modules under config path: /usr/lib/x86_64-linux-gnu/kamailio/modules/

Jul 25 12:35:45 emps116 systemd[1]: kamailio.service: Control process exited, code=exited status=255

Jul 25 12:35:45 emps116 systemd[1]: Failed to start Kamailio (OpenSER) - the Open Source SIP Server.

Jul 25 12:35:45 emps116 systemd[1]: kamailio.service: Unit entered failed state.

Jul 25 12:35:45 emps116 systemd[1]: kamailio.service: Failed with result 'exit-code'.

root@emps116:/etc/kamailio#

 

root@emps116:/etc/kamailio# kamailio -v

version: kamailio 4.4.6 (x86_64/linux)

flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES

ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB

poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.

id: unknown

compiled with gcc 4.9.2

root@emps116:/etc/kamailio#

 

 

Thanks,

Anu

From: Daniel-Constantin Mierla [mailto:miconda@gmail.com]
Sent: Tuesday, July 25, 2017 12:42 AM
To: Kamailio (SER) - Users Mailing List <sr-users@lists.kamailio.org>; Anuradha Selvarajan <anuradha.selvarajan@ericsson.com>
Subject: Re: [SR-Users] Can kamaillio act as user?

 

Hello,

uac is the module that is able to do registrations to remote servers. What are the error you get? Also, give the output of kamailio -v

Cheers,
Daniel

 

On 24.07.17 23:07, Anuradha Selvarajan wrote:

Hello,

 

Can Kamaillio act as a user and send SIP registration? If yes, how/which module and any sample config?

I tried to use UAC module but errored while loading the module inspite of loading it after TM/RR module.

 

Thanks

Anu




_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users



-- 
Daniel-Constantin Mierla
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training - www.asipto.com
Kamailio World Conference - www.kamailioworld.com

-- 
Daniel-Constantin Mierla
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training - www.asipto.com
Kamailio World Conference - www.kamailioworld.com