please cc the mailing list, otherwise your emails will be ignored.
do you have the mysql client installed? Can you connect to the mysql server from terminal with 'mysql' command?
Cheers, Daniel
On 25.11.2009 19:42 Uhr, YÜKSEL wrote:
Dear Daniel,
Thanks for your response : Actually I am getting an error below when I try to create DB with `/usr/local/sbin/kamdbctl create`
debian:/usr/local/src/kamailio-1.5.0/sip-server# /usr/local/sbin/kamdbctl create MySQL password for root: INFO: test server charset /usr/local/lib/kamailio/kamctl/kamdbctl.mysql: line 105: mysql: command not found /usr/local/lib/kamailio/kamctl/kamdbctl.mysql: line 106: mysql: command not found Usage: grep [OPTION]... PATTERN [FILE]... Try `grep --help' for more information. /usr/local/lib/kamailio/kamctl/kamdbctl.mysql: line 112: [: =: unary operator expected INFO: creating database openser ... /usr/local/lib/kamailio/kamctl/kamdbctl.mysql: line 71: mysql: command not found ERROR: Creating core database and grant privileges failed!
I`ve applied the instructor one by one but I didn`t understand whay I am getting this error.
Regards,
Yuksel
--- On *Wed, 11/25/09, Daniel-Constantin Mierla /miconda@gmail.com/* wrote:
From: Daniel-Constantin Mierla <miconda@gmail.com> Subject: Re: [Kamailio-Users] /usr/local/sbin/kamdbctl create error To: "lazturk" <lazturk@yahoo.com> Cc: users@lists.kamailio.org Date: Wednesday, November 25, 2009, 12:33 PM Hello, On 25.11.2009 17:59 Uhr, lazturk wrote: > Hello, > > How did you solve this problem bcz I am getting a similar error ; > which one? the one related to no database engine specified or the one related to mysql socket file? First: updated the kamctlrc file -- see the comments inside. Second: check if mysql server is running and if yes, check the mysql config to see where the server is listening and where the mysql client tries to connect to. They must be the same. Cheers, Daniel > > Thanks for your feedback. > > > vivi-8 wrote: > >> Hi all >> I have specify the wanted db type (DBENGINE=MYSQL) in the >> /usr/local/etc/kamailio/kamctlrc >> then I using "/usr/local/sbin/kamdbctl create" to create MySQL database, >> but I got this error: >> >> >> >> ERROR: database engine not specified, please setup one in the config >> script >> >> root@acer:/usr/local/src/kamailio-1.5.0/sip-server# vim >> /usr/local/etc/kamailio/kamctlrc >> >> root@acer:/usr/local/src/kamailio-1.5.0/sip-server# >> /usr/local/sbin/kamdbctl >> create >> >> MySQL password for root: >> >> INFO: test server charset >> >> ERROR 2002 (HY000): Can't connect to local MySQL server through socket >> '/var/run/mysqld/mysqld.sock' (2) >> >> ERROR 2002 (HY000): Can't connect to local MySQL server through socket >> '/var/run/mysqld/mysqld.sock' (2) >> >> Usage: grep [OPTION]... PATTERN [FILE]... >> >> Try `grep --help' for more information. >> >> /usr/local/lib/kamailio/kamctl/kamdbctl.mysql: line 112: [: =: unary >> operator expected >> >> INFO: creating database openser ... >> >> ERROR 2002 (HY000): Can't connect to local MySQL server through socket >> '/var/run/mysqld/mysqld.sock' (2) >> >> ERROR: Creating core database and grant privileges failed! >> >> >> >> Cheers, >> >> vivi >> >> >> _______________________________________________ >> Kamailio (OpenSER) - Users mailing list >> Users@lists.kamailio.org </mc/compose?to=Users@lists.kamailio.org> >> http://lists.kamailio.org/cgi-bin/mailman/listinfo/users >> http://lists.openser-project.org/cgi-bin/mailman/listinfo/users >> >> > > -- Daniel-Constantin Mierla * http://www.asipto.com/
Hello,
I am trying to realize simple redirect server (via 302) like calls will be coming from softswitch (IP : x.x.x.x) to SER to get necessary route information then turn back to same Softswitch in order to terminate same call over the Softswitch.as below ;
A-leg ------ MSC ------- B-leg | | | | | |
SER
I don't know what steps is required .cfg (modules,routes etc.) and how SER gets traffic from a peer then send back to them. Kindly sort of my steps that I need to apply.
Regards,
Yuksel
YÜKSEL schrieb:
Hello,
I am trying to realize simple redirect server (via 302) like calls will be coming from softswitch (IP : x.x.x.x) to SER to get necessary route information then turn back to same Softswitch in order to terminate same call over the Softswitch.as below ;
A-leg ------ MSC ------- B-leg | | | | | | SER
I don't know what steps is required .cfg (modules,routes etc.) and how SER gets traffic from a peer then send back to them. Kindly sort of my steps that I need to apply.
You just have to send back 302 response with the new target as contact header.
e.g.:
append_to_reply("Contact: sip:user@1.2.3.4\r\n"); sl_send_reply("302","moved"); exit;
I think if you send 302 response after lookup(), the branches will automatically be added as Contact header (not sure about this).
regards klaus
On 1/29/10 9:50 AM, Klaus Darilion wrote:
YÜKSEL schrieb:
Hello,
I am trying to realize simple redirect server (via 302) like calls will be coming from softswitch (IP : x.x.x.x) to SER to get necessary route information then turn back to same Softswitch in order to terminate same call over the Softswitch.as below ;
A-leg ------ MSC ------- B-leg | | | | | | SER
I don't know what steps is required .cfg (modules,routes etc.) and how SER gets traffic from a peer then send back to them. Kindly sort of my steps that I need to apply.
You just have to send back 302 response with the new target as contact header.
e.g.:
append_to_reply("Contact: sip:user@1.2.3.4\r\n"); sl_send_reply("302","moved"); exit;
I think if you send 302 response after lookup(), the branches will automatically be added as Contact header (not sure about this).
yes, branches are added to contact headers. Same is done for r-uri, so in this case might be better:
rewriteuri("sip:user@1.2.3.4"); sl_send_reply("302","moved"); exit;