Hello,

On 06/01/06 15:21, Padmaja RV wrote:
Hi all!
can anyone tell me how to check the syntax of the openser.cfg file after adding code for new modules?
you can check the configuration file without actually starting openser with:

openser -c -f /path/to/openser.cfg

See openser -h for more details.

also after saving the file with the changes in it, should the execute permissions be set to it? currently my openser.cfg does not have execute permission for anyone ie owner or user or group.

the configuration file does not need execute permission, it has to be only readable by the openser.

Cheers,
Daniel



Please let me know asap
Thanks and Regards,
Padmaja
----- Original Message ----- From: <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, June 01, 2006 5:08 PM
Subject: Users Digest, Vol 13, Issue 4


Send Users mailing list submissions to
[email protected]

To subscribe or unsubscribe via the World Wide Web, visit
http://openser.org/cgi-bin/mailman/listinfo/users
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]

You can reach the person managing the list at
[EMAIL PROTECTED]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Users digest..."


Today's Topics:

  1. No /var/run/openser.pid file found (Padmaja RV)
  2. Re: Call Hunting: use Avpop or LCR module ?
     (Daniel-Constantin Mierla)
  3. Re: Call Hunting: use Avpop or LCR module ?
     (Daniel-Constantin Mierla)


----------------------------------------------------------------------

Message: 1
Date: Thu, 1 Jun 2006 15:34:14 +0530
From: "Padmaja RV" <[EMAIL PROTECTED]>
Subject: [Users] No /var/run/openser.pid file found
To: "Jayesh Nambiar" <[EMAIL PROTECTED]>
Cc: [email protected]
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset="iso-8859-1"

Hi,
I have openser working now. i have installed it from src yesterday after manually deleting all the files installed from binaries. i have added database support and now it is working fine with authentication. i have tried openserctl start and stop and the first time they worked fine. but now if i type openserctl start, it either tells me no /var/run/openser.pid file found or it shows starting openser and then the cursor keeps blinking but i dont see the pid number of openser. but registrations keep happening . pls let me know what to do..

Thanks a lot for all the help.
Regards,
Padmaja
----- Original Message -----  From: Jayesh Nambiar
 To: Padmaja RV
 Sent: Thursday, June 01, 2006 1:29 PM
 Subject: Re: [Users] Re: how to run openser through monit daemon?


 Hi,
Sorry, but I never tried installing it from binaries. So i have no idea about whether installing it from src will overwrite or not. But I guess, it should overwrite. But not very sure. Another long way to delete is only locating the openser files and removing it mannually.
 w/regards,
 Jayesh

 Padmaja RV <[EMAIL PROTECTED]> wrote:
   Hi Jayesh,
I think you were mentioning about openser-1.0.1_src.tar.gz (that is from src directory of openser download) and i installed from bin directory of openser download area. The bin's tar ball is openser-1.0.1_linux_i386.tar.gz. and when that is installed, it does not show any openser-1.0.1 directory. it automatically loads various modules at their respective places and there is no Makefile i could see in it to edit it for mysql support. I have now openser from src. it is exactly as u mentioned.... this i have downloaded and installed as a user and not as root just to verify the directory structure of openser. i guess it is the right way to do and now i want to install it as root. should i delete the previous openser installations in that path and then install or when i install the src, it will automatically overwrite the existing onces? i am asking this because as root if i delete them it might damage the file system. again thanks so much....pls help me out!
   Thanks and Regards,
   Padmaja
     ----- Original Message -----      From: Jayesh Nambiar
     To: [email protected]
     Cc: [EMAIL PROTECTED]
     Sent: Wednesday, May 31, 2006 3:42 PM
     Subject: [Users] Re: how to run openser through monit daemon?


       Hi padmaja,
I guess there should have been a standalone directory called openser1.0.1 after you untar the .tar.gz file using tar -xzvf. In that directory itself there is file called Makefile in which the mysql module is excluded by default. Did you also check the logs in /var/log/messages about what is the error. Those messages are helpful to debug. You dont always need to go to sbin to start openser, there is a command called openserctl start to start it. I have a suggestion for you. Please visit onsip.org and register on that site. They have very good getting started documents which will help you.
       You can then structure your openser.cfg the way you want.

       w/regards,
       Jayesh.


       Hi Jayesh,
Thank you so much for the reply. I have downloaded the version openser-1.0.1 from cvs. I thought that is a stable release and no changes are going to be made to it. Do i have to again revert to the tar.gx version? Also please look at what happened when i previously installed the .tar.gz version of openser before doing the cvs


       1. downloaded openser-1.0.1-linux_i386.tar.gz version as root.
2. It is now under / (the root directory). after that i did unzip and untar on that. 3. the file and modules are loaded into the subdirectories of the /usr directory.I could not anywhere find a standalone directory called openser-1.0.1 with the directory sip-server in it. also there is no makefile here.... (All these i see when i download it thru CVS in the /usr/local/src directory.) 4. I tried to see through the list for the module mysql.so but i could not find it....and so for uri_db module also. these modules are present when i install openser thru cvs 5. i did not do any make on it. I thought it is precompiled version and will automatically get installed when i do the untar and unzip. please correct me if the tar version also has to go thru make 6. i ran openser through /usr/local/sbin/openser start. and it ran successfully... it showd the tcp and udp ports on which it is running..i could register my sip UA without authentication. 7. then i wanted to set it up for mysql support. i edited the config file and uncommented the necessary modules and tried to create the openser databse in mysql. here it failed stating ha1 calculation failed.. also it states there is no mysql.so module which is true.

Please let me know if I have made any mistakes in the installation process.... I am new to openser.. now if i want to revert to .tar.gz version, will all the openser modules and config files from the cvs be replaced by the tar.gz version? or will there be duplicate entries left?

       Thanks again
       Regards,
       Padmaja
       ----- Original Message -----        From: Jayesh Nambiar
       To: [email protected]
       Cc: [EMAIL PROTECTED]
       Sent: Wednesday, May 31, 2006 12:08 PM
       Subject: [Users] Re: how to run openser through monit daemon?


       Hi padmaja,
Running openser from cvs would not solve your problem. Openser from cvs is the development version which will be released after final testing is done. To be safe, its better if you use .tar.gz file to install. For enabling mysql, go to the openser directory and you'll find a makefile. In the makefile there is a line exclude_modules?= somewhere around line no.49. From there just remove mysql and recompile it again. You can start openser using openserctl start from the command line. To check for some errors you can set debug=9 in the openser.cfg file. Normally the logs are stored into /var/log/messages. You can check for errors in this file.

       Hi!
there is something I need to mention here with respect to openser not
       working.....

Initially I had openser installed from .tar.gz and i could run it from /usr/local/sbin/openser. It worked fine that way without any authentication. I could see local registration of my sip UAs with the openser being successful. then i set up mysql. It too started successfulyy thru webmin.
       next I tried to create the openser database in mysql from
/usr/sbin/openser_mysql.sh create. It prompted me for the root password of mysql, the domain name and then failed stating that the Ha1 calculation failed. also when i tried to modify the openser.cfg file to support mysql
       database i found that there is no mysql.so module in the
       /usr/local/lib/openser/modules/ path.

Because of the above problems, I tried installing openser from CVS and here all the modules and configuration files are present in the respective locations as mentioned in the web link for installing openser. I could even create the openser database structures in mysql. i tried uncommenting the needed modules for database suppport. now when i try to run openser thru monit, there is absolutely no response and openser does not look like
       running............

I am a newbie at openser......please help me which way i should run
       openser.....

       thanks and regards,
       Padmaja





-------------------------------------------------------------------------- Yahoo! India Answers: Share what you know. Learn something new Click here Send free SMS to your Friends on Mobile from your Yahoo! Messenger Download now




------------------------------------------------------------------------------ Yahoo! India Answers: Share what you know. Learn something new Click here Send free SMS to your Friends on Mobile from your Yahoo! Messenger Download now
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://openser.org/pipermail/users/attachments/20060601/e110ed3c/attachment.htm

------------------------------

Message: 2
Date: Thu, 01 Jun 2006 13:20:28 +0300
From: Daniel-Constantin Mierla <[EMAIL PROTECTED]>
Subject: Re: [Users] Call Hunting: use Avpop or LCR module ?
To: Alexandre Snarskii <[EMAIL PROTECTED]>
Cc: [EMAIL PROTECTED], "[email protected]" <[email protected]>
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed



On 06/01/06 12:53, Alexandre Snarskii wrote:
On Wed, May 31, 2006 at 12:04:41AM +0300, Daniel-Constantin Mierla wrote:

Hello,

On 05/30/06 19:47, Rafael J. Risco G.V. wrote:

hi
I would like to read some opinions to know which method its better to
implement Call Hunting, using serial forking with 'avpops' or 'lcr'
module 'load_contacts()/next_contact()' functions, does someone has an
example of any of these methods?

if it is a global scope you can use any of them, Which is better?
Depends on your environment and how you organize  your data.

If is per user, then avpops is more suitable. An example of using avpops
you can find at:

http://www.voice-system.ro/docs/avpops/ar01s08.html#ex_serial_forking


It is suitable, but for some scenarios it require much more complicated
config, which is not easy to understand.

Scenario:
User A (PSTN side) calls user B (SIP). With avpops we select some numbers for this user, trying original number (returns 486/BUSY), hunting to next
number (creating new transaction on router).
it does not create a new transaction, just adds a new branch to it.
 Phone B2 starts with
100/Trying 180/Ringing, then user A hangs.
CANCEL message first visits original number, which returns
481/Call leg/transaction does not exists [1],
you mean that sends CANCEL to B1? I do not think so, CANCEL is not sent
to completed branches, just to ones that haven't received a final response.
 then hunts to second
number and successfully cancel's call. But, at point [1], first transaction _does not store_ new reply code (modules/tm/t_reply.c, line 762 just logs
message
LOG(L_ERR, "ERROR: t_should_relay_response: status rewrite by UAS: "
            "stored: %d, received: %d\n",
            Trans->uac[branch].last_received, new_code );
        goto discard;
), and again hunts, so, third number of user B starts ringing...

What version of openser do you use?

The only solution for this which I found yet is:

#The only way to really check return code is to check it in onreply_route,
#then set flag which will permit failure_route to hunt this call again.
#You can't check status with t_check_status within failure_route,
#because t_check_status in failure_route returns the lowest value
#of all branches..
onreply_route[1] {
        if(status=~"40[48]" || status=~"486") {
                #not-so-fatal response, should hunt
                setflag(2);
        };
}
failure_route[1] {
        if(isflagset(2)) {
                resetflag(2);
                if(avp_pushto("$ruri","$serial_fork")) {
#and then everytingh should work as in example.


You can use t_was_cancelled() in failure route:
http://openser.org/docs/modules/1.1.x/tm.html#AEN479 . It will ensure
that you get the proper status of canceled transactions.

But, this config is not yet complete - with this configuration
CANCEL's does not hunt after 481 Call leg does not exists, so,
in situation when we need to cancel call on second or third number,
we're not able to do that :(
Just adding another code (481) to our list of not-so-fatal response
does nothing but returns us to initial problem, and the only
solution found is to complicate configuration again to:

#main post-routing code
route[1] {
if(method=="CANCEL") {
t_on_reply("2");
} else {
t_on_reply("1");
};
t_on_failure("1");
t_relay();
};

onreply_route[1] { #onreply for everyting but CANCEL
        if(status=~"40[48]" || status=~"486") {
                #not-so-fatal response, should hunt
                setflag(2);
        };
}
onreply_route[2] { #onreply for CANCEL's
        if(status=~"481") {
                #not-so-fatal response, should hunt
                setflag(2);
        };
}

failure_route[1] {
        if(isflagset(2)) {
                resetflag(2);
                if(avp_pushto("$ruri","$serial_fork")) {


Please note, that config is in pre-production stage, tested, but
without really massive tests. Also, note that this is not complete
config, just parts to allow serial hunting without noted problem.

If anyone knows more elegant solution for my problem - please, let
me know. Also, if anyone can see a problem with my config - let me
know how to test it...


Could you try the latest version of OpenSER CVS, it is now in
frozen/testing phase, just to be release in a few weeks. Any feedback
will help to fix eventual issues. The part with reply code selections
and CANCEL processing was refurbished and should have fixed some old issues.

Cheers,
Daniel


PS: another problem may arise with maximal number of branches.
With default configuration of ser (config.h, #define MAX_BRANCHES 12)
maximum number of hunts is limited to 11. If you need more hunts than
this - you need to recompile ser.






------------------------------

Message: 3
Date: Thu, 01 Jun 2006 14:38:06 +0300
From: Daniel-Constantin Mierla <[EMAIL PROTECTED]>
Subject: Re: [Users] Call Hunting: use Avpop or LCR module ?
To: Alexandre Snarskii <[EMAIL PROTECTED]>
Cc: "[email protected]" <[email protected]>
Message-ID: <[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed



On 06/01/06 14:32, Alexandre Snarskii wrote:
On Thu, Jun 01, 2006 at 01:20:28PM +0300, Daniel-Constantin Mierla wrote:

On 06/01/06 12:53, Alexandre Snarskii wrote:

On Wed, May 31, 2006 at 12:04:41AM +0300, Daniel-Constantin Mierla wrote:


Hello,

On 05/30/06 19:47, Rafael J. Risco G.V. wrote:


hi
I would like to read some opinions to know which method its better to
implement Call Hunting, using serial forking with 'avpops' or 'lcr'
module 'load_contacts()/next_contact()' functions, does someone has an
example of any of these methods?


if it is a global scope you can use any of them, Which is better?
Depends on your environment and how you organize  your data.

If is per user, then avpops is more suitable. An example of using avpops
you can find at:

http://www.voice-system.ro/docs/avpops/ar01s08.html#ex_serial_forking


It is suitable, but for some scenarios it require much more complicated
config, which is not easy to understand.

Scenario:
User A (PSTN side) calls user B (SIP). With avpops we select some numbers for this user, trying original number (returns 486/BUSY), hunting to next
number (creating new transaction on router).

it does not create a new transaction, just adds a new branch to it.

Phone B2 starts with
100/Trying 180/Ringing, then user A hangs.
CANCEL message first visits original number, which returns
481/Call leg/transaction does not exists [1],

you mean that sends CANCEL to B1? I do not think so, CANCEL is not sent to completed branches, just to ones that haven't received a final response.

then hunts to second
number and successfully cancel's call. But, at point [1], first transaction _does not store_ new reply code (modules/tm/t_reply.c, line 762 just logs
message
LOG(L_ERR, "ERROR: t_should_relay_response: status rewrite by UAS:
       "
           "stored: %d, received: %d\n",
           Trans->uac[branch].last_received, new_code );
       goto discard;
), and again hunts, so, third number of user B starts ringing...


What version of openser do you use?


ser 0.9.6, freebsd 6.1, database backend is postgresql.
Did not tried that setup with openser yet.
Initial question was in ser-users mailing list..


it seems that was doubled posted, I answered to [email protected] and
overlooked that is for serusers, too.

Cheers,
Daniel



The only solution for this which I found yet is:

#The only way to really check return code is to check it in onreply_route, #then set flag which will permit failure_route to hunt this call again.
#You can't check status with t_check_status within failure_route,
#because t_check_status in failure_route returns the lowest value
#of all branches..
onreply_route[1] {
       if(status=~"40[48]" || status=~"486") {
               #not-so-fatal response, should hunt
               setflag(2);
       };
}
failure_route[1] {
       if(isflagset(2)) {
               resetflag(2);
               if(avp_pushto("$ruri","$serial_fork")) {
#and then everytingh should work as in example.


You can use t_was_cancelled() in failure route:
http://openser.org/docs/modules/1.1.x/tm.html#AEN479 . It will ensure
that you get the proper status of canceled transactions.


But, this config is not yet complete - with this configuration
CANCEL's does not hunt after 481 Call leg does not exists, so,
in situation when we need to cancel call on second or third number,
we're not able to do that :(
Just adding another code (481) to our list of not-so-fatal response
does nothing but returns us to initial problem, and the only
solution found is to complicate configuration again to:

#main post-routing code
route[1] {
if(method=="CANCEL") {
t_on_reply("2");
} else {
t_on_reply("1");
};
t_on_failure("1");
t_relay();
};

onreply_route[1] { #onreply for everyting but CANCEL
       if(status=~"40[48]" || status=~"486") {
               #not-so-fatal response, should hunt
               setflag(2);
       };
}
onreply_route[2] { #onreply for CANCEL's
       if(status=~"481") {
               #not-so-fatal response, should hunt
               setflag(2);
       };
}

failure_route[1] {
       if(isflagset(2)) {
               resetflag(2);
               if(avp_pushto("$ruri","$serial_fork")) {


Please note, that config is in pre-production stage, tested, but
without really massive tests. Also, note that this is not complete
config, just parts to allow serial hunting without noted problem.

If anyone knows more elegant solution for my problem - please, let
me know. Also, if anyone can see a problem with my config - let me
know how to test it...


Could you try the latest version of OpenSER CVS, it is now in
frozen/testing phase, just to be release in a few weeks. Any feedback
will help to fix eventual issues. The part with reply code selections
and CANCEL processing was refurbished and should have fixed some old issues.

Cheers,
Daniel



PS: another problem may arise with maximal number of branches.
With default configuration of ser (config.h, #define MAX_BRANCHES 12)
maximum number of hunts is limited to 11. If you need more hunts than
this - you need to recompile ser.









------------------------------

_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users


End of Users Digest, Vol 13, Issue 4
************************************



_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/users

Reply via email to