[OpenSIPS-Users] Opensips Control Pannel does not take effect into Opensips Server

Duong Manh Truong ngoahotanglongbk at gmail.com
Thu Mar 24 19:31:49 CET 2011


Hi Dave,
My default config in was :
// default: $boxes[$box_id]['mi']['conn']="127.0.0.1:8000";
// default: $boxes[$box_id]['mi']['conn']="/tmp/opensips_fifo";

then i changed it to
$boxes[$box_id]['mi']['type']="fifo";
$boxes[$box_id]['mi']['fifo']="/tmp/opensips_fifo";

And i found some functions of CP works such as: Add/edit users; Add/edit
domain.
But a lot of others still dont work such as: cdrs, show online users,
........

I see the "apply changes to server" button, i hit it and get this message
for a new web browser tab:
"http://10.2.14.122/cp/tools/system/domains/apply_changes.php
Cannot connect to OpenSIPS Server via Management Interface ()"

I come to /cp/tools/system/domains but find no "apply_changes.php" file :-(

Please help me to find out how i can connect to Opensips Server and making
changes

Thanks!

2011/3/24 Dave Singer <dave.singer at wideideas.com>

> Duong,
>
> The MI commands are for opensips and ps does NOT take any arguments.
> The easiest way for it to connect when on the same box is with fifo.
> Here is a snippet from the boxes.global.inc.php:
> /*==================== DEFINITION OF BOXES (servers)
> ========================*/
> // each server is a box
> $box_id=0;
> $boxes[$box_id]['mi']['type']="fifo";
> $boxes[$box_id]['mi']['fifo']="/tmp/opensips_fifo";
>
> This does require that opensips module mi_fifo is loaded and
> configured with the same path/file as you set in the config above
> (above path is the default path).
> opensipsctl uses it also (unless it was configured to use xmlrpc (not
> sure it can)).
> Opensips xmlrpc module by default lisetns on port 8000, not the sip
> port 5060. That is why you got that message.
> I've not been able to get xmlrpc to compile and work on Centos 5 servers.
>
> Dave
>
> On Thu, Mar 24, 2011 at 12:17 AM, Duong Manh Truong
> <ngoahotanglongbk at gmail.com> wrote:
> >
> > Thank Dave!
> > When going to the "MI commands" tab, surprisingly i found that
> > "Cannot connect to OpenSIPS Server via Management Interface (
> 127.0.0.1/8000)
> > Execute MI Command"
> >
> > After i executed the "ps -A" command, i only got this
> > "14:02:20  |  ps -A   |  127.0.0.1:8000"
> > The same result for "opensipsctl online" command
> >  "14:04:37  |   opensipsctl online   |  127.0.0.1:8000"
> > And i think the problem is my CP does not connect to my Opensips server
> on 5060 port. I remember that i have not configured CP listening port
> before, it is default :-(
> > (CP & Opensips server were installed in the same machine)
> > Checking these files "db.inc.php" ; local.inc.php; globals.php  in the CP
> config directory "/var/www/opensips-cp/config"
> > I don't see anywhere to config CP listening port !
> > Please help me to figure out, thanks!
> > 2011/3/24 Dave Singer <dave.singer at wideideas.com>
> >>
> >> Duong,
> >>
> >> Yea missed that. :-)
> >> To check basic CP connection to opensips, go to System, MI Commands.
> >> In box under Execute MI Command, put "ps" and click "execute". It
> >> should show a bunch of lines about the opensips processes that are
> >> running.
> >>
> >> As far as showing Online Users, it may be using presence module/table
> >> rather than active registrations to qualify a user as "online".
> >> Someone else will have to answer that or you can look at the CP source
> >> code for that answer.
> >>
> >> Dave
> >>
> >> On Wed, Mar 23, 2011 at 12:35 PM, Duong Manh Truong
> >> <ngoahotanglongbk at gmail.com> wrote:
> >> > Thank David,
> >> > But i found that in my opensips.cfg file:
> >> > "
> >> > # ----- usrloc params -----
> >> > # modparam("usrloc", "db_mode",   0)
> >> > /* uncomment the following lines if you want to enable DB persistency
> >> >    for location entries */
> >> > modparam("usrloc", "db_mode",   2)
> >> > modparam("usrloc", "db_url",
> >> > "mysql://opensips:opensipsrw@localhost/opensips")
> >> > "
> >> > So i think that my "db_mode" is not the cause of my failed CP
> >> > " 2 - Write-Back scheme. This is a combination of previous two
> schemes. All
> >> > changes are made to memory and database synchronization is done in the
> >> > timer. The timer deletes all expired contacts and flushes all modified
> or
> >> > new contacts to database. Use this scheme if you encounter high-load
> peaks
> >> > and want them to process as fast as possible. The mode will not help
> at all
> >> > if the load is high all the time. Also, latency of this mode is much
> lower
> >> > than latency of mode 1, but slightly higher than latency of mode 0."
> >> > My CP still does  not work :-( , even the simple function like "show
> online
> >> > user"  --- "no data found"
> >> > (While checking by using opensipsctl is ok)
> >> >  opensipsctl online
> >> > database engine 'MYSQL' loaded
> >> > Control engine 'FIFO' loaded
> >> > 1001
> >> >
> >> > Please tell me how to check my CP and its connection to Opensips
> server?
> >> > Thanks !
> >> >
> >> >
> >> >
> >> >
> >> > ----------------------------------------------------------------------
> >> >
> >> > Message: 1
> >> > Date: Tue, 22 Mar 2011 21:06:21 -0700
> >> > From: Dave Singer <dave.singer at wideideas.com>
> >> > Subject: Re: [OpenSIPS-Users] Opensips Control Pannel does not take
> >> >        effect into Opensips Server
> >> > To: OpenSIPS users mailling list <users at lists.opensips.org>
> >> > Message-ID:
> >> >        <AANLkTimB=bQZ1buVKaWzMKq2LM=UsLhEsAQWW+uFrrw7 at mail.gmail.com>
> >> > Content-Type: text/plain; charset=ISO-8859-1
> >> >
> >> > The key I think is usrloc db mode is 0, which means db is not used.
> >> > http://www.opensips.org/html/docs/modules/1.6.x/usrloc.html#id292029
> >> >
> >> > On Tue, Mar 22, 2011 at 6:47 PM, Duong Manh Truong
> >> > <ngoahotanglongbk at gmail.com> wrote:
> >> >> Dear Dave!
> >> >> Thanks for your help.
> >> >> I've checked the opensips.cfg again but i still can not find out what
> >> >> stuff
> >> >> is incorrect ! :-(
> >> >> I attached my config file in this email, hope that will help my
> problem to
> >> >> be?clearer!
> >> >> If anyone has had the same issue, please tell me how can i check or
> fix
> >> >> it.
> >> >> (Hope to receive relatively specific informations)
> >> >> Thanks and Best Regards.
> >> >>
> >> >>
> >> >>
> >> >> Date: Mon, 21 Mar 2011 08:45:03 -0700
> >> >> From: Dave Singer <dave.singer at wideideas.com>
> >> >> Subject: Re: [OpenSIPS-Users] Opensips Control Pannel does not take
> >> >> ? ? ? ?effect into Opensips Server
> >> >> To: OpenSIPS users mailling list <users at lists.opensips.org>
> >> >> Message-ID:
> >> >> ? ? ? ?<AANLkTinGLDzzbUgJgQXOd_93r31hjnHAVAzPMo64K-MQ at mail.gmail.com
> >
> >> >> Content-Type: text/plain; charset=ISO-8859-1
> >> >>
> >> >> Duong,
> >> >>
> >> >> Some modules, like drouting, you have to click a reload module button
> >> >> in the control pannel.
> >> >> However, I think your problem is that you haven't implemented the
> >> >> needed stuff in opensips.cfg script.
> >> >> CP only provides an interface to managing/accessing the databases
> >> >> tables. You still have to impliment the logic in opensips.cfg.
> >> >>
> >> >> Dave
> >> >>
> >> >> On Sat, Mar 19, 2011 at 3:04 AM, Duong Manh Truong
> >> >> <ngoahotanglongbk at gmail.com> wrote:
> >> >>> Hi all,
> >> >>> I have followed all instructions about Opensips CP installations
> >> >>> After done all configurations, the Web interface is appeared
> >> >>> but unfortunately, when i use modules in this interfaces, it seems
> there
> >> >>> is
> >> >>> no connection between Opensips CP and Opensips Server Core!
> >> >>> Take add/manage users module as an example: I registered user 1001,
> then
> >> >>> i
> >> >>> selected this module to show online users
> >> >>> => But the result was "no data found" :-(
> >> >>> I've created opensips database, correctly insert parameters to
> opensips
> >> >>> CP
> >> >>> config files (including mysql user/pass to connect to opensips
> database)
> >> >>> No error found !
> >> >>> But i still can not use Opensips CP, someone help me to figure out
> why
> >> >>> Opensips CP has no effect ??
> >> >>> Do i misconfig ?(or forget to config) some important parameters to
> make
> >> >>> Opensips CP connect properly to Opensips Server Core?
> >> >>> (Something likes authentications........etc)
> >> >>> Thanks a lot!
> >> >>> _______________________________________________
> >> >>> Users mailing list
> >> >>>?Users at lists.opensips.org
> >> >>>?http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >> >>>
> >> >>>
> >> >>
> >> >>
> >> >>
> >> >> _______________________________________________
> >> >> Users mailing list
> >> >> Users at lists.opensips.org
> >> >> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >> >>
> >> >>
> >> > _______________________________________________
> >> > Users mailing list
> >> > Users at lists.opensips.org
> >> > http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> >> >
> >> >
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20110325/00bdcd18/attachment-0001.htm>


More information about the Users mailing list