login | register
Sat 17 of May, 2008 [05:15 UTC]

voip-info.org

Search with Google
Search this site with Google. Results may not include recent changes.
 
Google Ads
Shoutbox
  • Juan Ortega, Thu 15 of May, 2008 [10:33 UTC]: Hi everybody, I'm Juan, an ITCom student, and I need to know what basic elements I need to create a VoIP network. Can anybody helpme, please?,Thank you very much
  • gineta, Wed 14 of May, 2008 [03:58 UTC]: any here not fine the configuration of firewall juniper -screem for VOIP asterisk????
  • Anoop Prabhakaran, Tue 13 of May, 2008 [12:16 UTC]: I am developing Asterisk IVR, Whenever i make a internation call to the IVR system, the DTMF is not getting detected properly, this happens only for the first time, second call onwards system works fine. why this is happening
  • joe, Mon 12 of May, 2008 [04:27 UTC]: Is there an opensource browser based softphone, or a system like Busta where everything is not manages through their website?
  • Nick Barnes, Fri 09 of May, 2008 [11:36 UTC]: Christopher - yesterday I tried an Asterisk install on a CentOS 5.1 box with stock GUI and it all worked fine. Sorry I can't help.
  • aero, Fri 09 of May, 2008 [08:20 UTC]: can someone help me out on this, i tried to play some sound files on my asterisk box and this is the error message i got. WARNING[4429]: format_wav.c:169 check_header: Unexpected freqency 22050 May 8 11:17:39 WARNING[4433]: codec_gsm.c:194 gsmtolin_fra
  • Christopher Faust, Thu 08 of May, 2008 [14:15 UTC]: I beleive that I may have to change something in the xserver configuration. Please advise
  • Christopher Faust, Thu 08 of May, 2008 [14:14 UTC]: Everything was perfect. In the bios I have increased the memory allocated Still receive input not supported on my display.
  • Christopher Faust, Thu 08 of May, 2008 [14:13 UTC]: This would not be my main box. I am doing some testing to see if I can install zaptel and asterisk 1.4 on a full centos 5.1 box with development software Its bizzare, because before I went through the asterisk and zaptel installation everything was perfe
  • Nick Barnes, Thu 08 of May, 2008 [13:44 UTC]: Christopher - I can't see any way in which an Asterisk installation would muck your GUI, but remember that it is advised not to use a GUI on an Asterisk box anyway.
Server Stats
  • Execution time: 0.27s
  • Memory usage: 2.20MB
  • Database queries: 33
  • GZIP: Disabled
  • Server load: 0.66

LCR tool for i4l

Least Cost Routing

Tools for i4l, asterisk and others

Asterisk addon rate-engine

From Voop (previously Trollphone) comes the Rate-engine to allow smart LCR routing. For more info, see link above

Meta-ENUM lookup for combined Call and LCR routing



This website aggregates ENUM information from different sources and mixes them up with Call-by-Call LCR data from the german market. You may interface to this service by ENUM itself. An AGI script for Dialplan integration is provided.
The website is in german language only.

Asterisk LCR Routing for Germany



As of 2005-04-11, this site is updated hourly from the providers' web pages. It has an LCR tool for Asterisk (go to "LCR Download") which works very well and includes hour-by-hour tariff variations.

Note: It appears that chan_capi 0.3.5 does not differentiate between provider busy ("Gassenbesetzt") and enduser busy, which makes the Asterisk dialplan a bit uncomfortable in this respect; zaphfc (bristuff) on the other hand appears to handly this issue very well.

rates4linux web site


The rates file is not as up-to-date as one could hope.
xdial.de has more accurate information, although it updated only weekly. Now, all we need is a programm transferring the information xdial provides into a database readable form. And a way to automatically receive updates from xdial. Anyone?!

Taken from the i4l FAQ:


Yes, this feature is now being supported by isdnlog. What it does is that it allows isdnlog to choose your telephone provider when placing a call through your ISDN card, depending on the time of day and the current rate information. Since isdnlog 4.16 an external script is called (if configured) to change various ISP settings (e.g. DNS lookup, proxy setup,...).

Note: the ABC-extensions (s. docu_abc) must be installed. Also, isdnlog should always be running (otherwise your dialout will be delayed by 3 seconds). If the ABC-extensions are not installed, isdnlog prints hints to the log file, which provider would have been chosen.

More tips:

Get isdn4k-utils from isdn4linux.de; don't worry, you don't actually need to have ISDN, we just need the isdnrate utility for finding the best provider. The "stable" versions won't work, so get some CVS snapshot instead.

Get recent provider data from ** rates4linux.sourceforge.net **. Fix /etc/isdn/rates.conf to list the providers of your choice.

Example:

Here is what I've done to make my asterisk* act as a LCR. First, you'll have to install isdnrate (part of isdnutils) and get a recent rate-??.dat (check rates4linux.sourceforge.net for that.)

to test isdnrate just try the following command:

 isdnrate -o -b3 -l60 *any_number_you_want_to_test*

the -o tells isdnrate to only use provides activated in /etc/isdn/rate.conf (e.g. if you have some preselection providers or tisdn-xxl) -b3 is for the best 3 providers -l60 says call duration 60 seconds (the default-value I also used in my AGI is 153 secs. so if you want to use annother duration please change the commandline in the agi)

then I wrote a very little (and simple) AGI.

lcr.agi

#!/usr/bin/perl
$|=1;
while(<STDIN>) {
        chomp;
        last unless length($_);
        if (/^agi_(\w+)\:\s+(.*)$/) {
                $AGI{$1} = $2;
        }
}

$number = $ARGV[0];
$length = 60;

$raw = `/usr/bin/isdnrate -o -b1 -L -l$length $number`;
$raw =~ /([0-9]*)_.;(.*?);/;
$prefix = $1;
$provider = $2;

print "VERBOSE \"Using LCR Provider $provider - $prefix!\"\n";
$result = <STDIN>;

print "SET VARIABLE LCR $prefix\n";
$result = <STDIN>;

as you can see, my AGI just sets a variable called LCR. here is how I use it in my dialplan:

 exten => _0.,1,Answer
 exten => _0.,2,DigitTimeout,5           ; Set Digit Timeout to 5 seconds
 exten => _0.,3,ResponseTimeout,10               ; Set Response Timeout to 10 seconds 
 exten => _0.,4,agi,/lcr.agi|${EXTEN:${TRUNKMSD}} 
 exten => _0.,5,Dial,CAPI/@6294096:b${LCR}${EXTEN:${TRUNKMSD}}|60|T

I know that this is all very simple - and maybe there are some errors in my setup but I just wanted to share my expirence with you.


bye
... thorsten aka FastJack



I've just changed my LCR.agi script so it uses 3 CBC-provides so it can fallback to the next most least one in case the other is to busy or not working anyway. I'm using it at home and I hope it may work for others, too.

Here is the new script:
lcr.agi

#!/usr/bin/perl
$|=1;
while(<STDIN>) {
        chomp;
        last unless length($_);
        if (/^agi_(\w+)\:\s+(.*)$/) {
                $AGI{$1} = $2;
        }
}

$number = $ARGV[0];
$length = 60;

$x = 1;
foreach (`/usr/bin/isdnrate -o -b3 -L -l$length $number`) {
    $_ =~ /([0-9]*)_.;(.*?);/;
    $prefix = $1;
    $provider = $2;
    print "VERBOSE \"Using LCR Provider($x) $provider - $prefix!\"\n";
    $result = <STDIN>;

    print "SET VARIABLE LCR$x $prefix\n";
    $result = <STDIN>;
    $x++;
}



and here is a sample how to use it in your extensions.conf

; LCR for outgoing calls
exten => _0.,1,AGI,lcr.agi|${EXTEN:${TRUNKMSD}}
exten => _0.,2,Dial,CAPI/${CALLERIDNUM}:${LCR1}${EXTEN:${TRUNKMSD}}|60|T
exten => _0.,3,Dial,CAPI/${CALLERIDNUM}:${LCR2}${EXTEN:${TRUNKMSD}}|60|T
exten => _0.,4,Dial,CAPI/${CALLERIDNUM}:${LCR3}${EXTEN:${TRUNKMSD}}|60|T
exten => _0.,5,Congestion


you see, we now have 3 vars (LCR1-3) and can use them in our dialplan.

Note: After reinstalling my asterisk-machine and trying to use my own scripts from this page I had to find out, that the wikki didn't display the '[' and ']'. But I hope this is fixed now!!

... bye
thorsten aka FastJack

Additional info in German

Linux Magazin

http://www.linux-magazin.de/Artikel/ausgabe/2001/05/voip/voip.html
Der Least Cost Router (LCR) Isdnrate ist Bestandteil von Isdn4linux. Damit der LCR korrekte Daten liefert, ist es wichtig, dass das ISDN-System korrekt konfiguriert ist. Vor allem muss in /etc/isdn/isdn.conf unter AREACODE die eigene Vorwahl eingetragen sein. Ob der LCR korrekt konfiguriert ist, lsst sich feststellen:

isdnrate -b 0 -H 04181
Eine 153 Sekunden lange Verbindung von +49 40/ Hamburg
nach +49 4181/ Buchholz kostet am Mon Jan 22 10:18:46 2001

Hierbei sollte statt Hamburg der Ort angezeigt werden, in dem sich das Gateway befindet. Ist der LCR richtig konfiguriert, kann er als Daemon gestartet werden:

isdnrate -D2

Wenn der Daemon korrekt l�uft, funktioniert folgender Befehl ohne Probleme:

isdnrate -C -b 1 04181 01013_1:Tele 2 Preselection DEM 0.153

Mediatronix

http://i4l.mediatronix.de/de-dwabc-extension-howto-9.htm
9. Least Cost Router
9.1. Einf�hrung in die Theorie

Ein W�hlvorgang wird vom ISDN Treiber normalerweise direkt erledigt. Durch aktivieren des Least Cost Routers wird dieses verhindert. Bei Ausl�sung eines Wahlvorganges �bergibt der ISDN Treiber die anzurufende Telefonnumer an den ISDNLOG weiter. Der ISDNLOG sucht nun wiederum in einer Providerdatenbank nach dem zu diesem Ziel (Unter einbeziehung der Uhrzeit) preiswertesten Telefon netzanbieter. Wird er fandig baut er die Rufnummer um inklusive der Providervorwahl und gibt diese Telefonnummer an den ISDN Treiber zur�ck, der dann wiederum diese neue Telefonnummer anw�hlt. Sicherheitshalber wurde das Zeitfenster, welches der ISDNLOG zum suchen eines Providers hat auf 3 Sekunden beschr�nkt. Das hei�t sollte der ISDNLOG crashen oder die Information nicht schnellgenug zur�ckliefern so w�hlt der ISDN Treiber von sich aus die urspr�ngliche Rufnummer.

9.2 Konfiguration des ISDNLOG f�r LCR Support

Zur Zeit ist der LCR Support im Kernel ISDN-Treiber implementiert,
die eigentliche Arbeit im ISDNLOG ist noch nicht abgeschlo�en, daher
ist dieses Feature zur Zeit noch nicht benutzbar.

See also



Go back to Asterisk

Created by JustRumours, Last modification by rkarlsba on Sun 01 of Jan, 2006 [19:39 UTC]

Please update this page with new information, just login and click on the "Edit" or "Add Comment" button above. Get a free login here: Register Thanks! - support@voip-info.org

Page Changes | Comments

Sponsored by:

Terms of Service Privacy Policy
© 2003-2008 VOIP-Info.org LLC

Powered by bitweaver