OSLEC installation with DAHDI

From Kolmisoft Wiki

Jump to: navigation, search


[edit] What is OSLEC?

Oslec is an open source high performance line echo canceller. When used with Asterisk it works well on lines where the built-in Zaptel echo canceller fails.
No tweaks like rxgain/txgain or fxotrain are required. Oslec is supplied as GPL licensed C source code and is free as in speech.

More information can be found here

Attention - this manual is addressed to MOR users who are experienced in Linux and Asterisk!

[edit] Download and unpack Dahdi

cd /usr/src
wget http://downloads.asterisk.org/pub/telephony/dahdi-linux/dahdi-linux-current.tar.gz
tar xvfz dahdi-linux-current.tar.gz

[edit] Download and unpack your Linux kernel sources

At this stage make sure you download the correct kernel sources

Check the current kernel by using command

[root@linux ~]# uname -a
Linux ns205179.ovh.net 2.6.28-grsec-xxxx-grs-ipv6-64 #2 SMP Thu Aug 25 16:40:22 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux

Next, download the kernel sources

wget http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.28.tar.bz2


tar xvfz linux-2.6.28.tar.bz2

[edit] Prepare the downloaded DAHDI sources to compile with OSLEC included

mkdir /usr/src/dahdi-linux-
cp -fR /usr/src/linux-2.6.28/drivers/staging/echo /usr/src/dahdi-linux-
sed -i "s|#obj-m += dahdi_echocan_oslec.o|obj-m += dahdi_echocan_oslec.o|" /usr/src/dahdi-   linux-
sed -i "s|#obj-m += ../staging/echo/|obj-m += ../staging/echo/|" /usr/src/dahdi-linux-
echo 'obj-m += echo.o' > /usr/src/dahdi-linux-

[edit] Compile DAHDI and DAHDI tools

cd / usr/src/dahdi-linux-
make install

Download and install DAHDI tools

cd /usr/src
wget http://downloads.asterisk.org/pub/telephony/dahdi-tools/dahdi-tools-current.tar.gz
tar xvfz dahdi-tools-current.tar.gz
cd dahdi-tools-2.4.1
make install
make config

[edit] Check the results

After everything has been done, run the following command


Check if OSLEC was installed:

locate oslec | grep /lib/modules

You should see similar output:


[edit] See also

Alternative guide can be found here

Personal tools


Try M2