Friday, December 19, 2008

Her pictures, wow!



Test report of Intel Atom CPU with asterisk G729-g711 codec transcoding

Some people buy the Intel CPU (Atom 230) to build an asterisk server. I did a simple test for codec transcoding.
The purpose of test case is only for reference when you build a Atom CPU based asterisk server,
maybe the test environment is not really completed due to some limitations such as test tools, bandwidth of LAN,
Network card, version of g729 and the duration of timing, but I try to give you a picture for asterisk server with transcoding.
In this paper, I will cover installation of G729, testing tools, result of testing and some screens. Note: please download the PDF file for more details.
1) Installation of Open Source G729
Before installing g729 codec, make sure the asterisk server can run properly,
then go to the official website to get the binary files and copy those two files into the default path.
2) Set testing tools
Here, three tools are used: Sipp, tpcdump and wireshark. Please go to those official websites to get those tools.
You must use tcpdump or wireshark to get a G729 code pcap file.
The easy way to get G729 file is that, using Xlite-Pro version to call other SIP phone and record down the file with G729 codec by this:
tcpdump -T rtp -vvv dst 192.168.2.108 -w g729.pcap
This should capture the RTP stream from asterisk server and save it as g729.pcap file.
You must make sure the Xlite-pro solely use G729 codec.
You also can use Wireshark to capture G729 codec and save as G729.pcap. Capturing the G729 RTP stream by Wireshark filter:
(ip.dst == 192.168.2.10 && (rtp.p_type == 1
this will filter the G729 codec from 192.168.2.108. Once you get the G729 codec file, you put the file under pacp folder under Sipp:
After that, you have to edit the uac_pcap.xml to make sure Sipp will play with RTP stream.
Once the Sipp side is done, you have to add a sip account in asterisk server 1.
The sip is named sipp. Please add an account in asterisk sip.conf.
And you add other sip (for example 1000) account with codec allow=ulaw or alaw only. SIP 1000 will forward the sip call from Spp to asterisk 2, in asterisk 2, some sound files will be played for certain periods.
In this scenario, transcoding will be done from G729 to G711. If you do not set it properly, asterisk server will report codec compatibility error. The Sipp test can not be made, please double check that. Until this step, you can execute the Sipp command to test:
sipp –sf uac_pcap.xml –s 2005 192.168.2.108 –r 20 –rp 10000
sipp will call uac_pcap.xml file first, and go to asterisk dialplan, the context “internal” will be called with asterisk server 1. It will generate 20 calls in 10 seconds. You can test it with different time variables. You also can press =-*/ to increase the calls or decrease calls. You can monitor the calls during call connection time by running sip show channels under asterisk console,
3) Result of Testing
The results are summarized to give users some statistical data. The scenarios are:
The scenario one:
Sipp(g711)->asterisk-1 with Atom CPU (g711)->asterisk-2(g711)
The scenario two:
Sipp(g729)->asterisk-1 with Atom CPU (g729->g711)->asterisk-2(g711)

In conclusion, codec contanscoding will consume much CPU resource. During the test, some factors must be considered. They are duration of each events, codecs, length of RTP streams, condition of Lan transmission, Network cards of asterisk servers. For Intel Atom CPU, the current calls should be limited less 30 calls. When the peak time reaches, the SIP calls will generate some warning. For further test improvement, it is very necessary to make a further investigation with g729 codec under Sipp RTP test for more accurate result.
please download the PDF for more details:
http://openvox.com.cn/downloadsFile/Test_Report_of_Atom_CPU_with_asterisk_G729-G711.pdf

References:
www.openvox.com.cn
asterisk.org
voip-info.org
http://www.woojar.com/sipp-testing-about-rtp.html
http://www.voipphreak.ca/2007/04 ... risk-14-pbx-system/
http://sipp.sourceforge.net/wiki ... k_server_using_SIPp
http://sipx-wiki.calivia.com/ind ... n_performance_tests
http://www.transnexus.com/White% ... _as_a_SIP_B2BUA.pdf
http://transnexus.blogspot.com/2 ... rmance-testing.html
http://callsolutions.org/voip-tu ... -14-h323-g729-g723/
http://asteriskglobe.blogspot.co ... -discussion-on.html
http://www.wireshark.org/
http://www.asteriskblog.com/sniffin-the-voip-traffic/
http://www.panoramisk.com/151/analyzing-voip-with-wireshark/en/

Test environments:
Cnetos-5.0
Intel Atom 230 CPU
Tools: Sipp-3.1, tcpdump and Wireshark
Asterisk-1.4.21

Asterisk PRI D210P/D410P + dahdi

hello, all of users:
To install D210P with dahdi, install some support packages as zaptel requires, then please go through these steps:
1) get dahdi-linux, dahdi-tools and asterisk
wget http://downloads.digium.com/pub/asterisk/releases/asterisk-1.6.0.1.tar.gz
wget http://downloads.digium.com/pub/telephony/dahdi-linux/dahdi-linux-2.0.0.tar.gz
wget http://downloads.digium.com/pub/telephony/dahdi-tools/dahdi-tools-2.0.0.tar.gz
wget http://downloads.digium.com/pub/libpri/releases/libpri-1.4.7.tar.gz
please unzip and cpoy those files to /usr/src/dahdi/dahdi-com(please note that this my dir, you can set to /usr/src)
2) please change back to /usr/src/dahdi/dahdi-com/libpri-1.4.7
run: make, make install
3) please change back to /usr/src/dahdi/dahdi-com/dahdi-linux-2.0.0
run: make, make install
4) change the directory to /usr/src/dahdi/dahdi-com/dahdi-tools-2.0.0
run: ./configure, make, make install
5) change to asterisk directory, in my case is /usr/src/dahdi/asterisk-1.6
5.1) ./configure
5.2) make
5.3) make install
5.4) make samples
6) please edit the dahdi files
6.1) edit the system.conf under /etc/dahdi, some files are there:
[root@new-host-8 asterisk-1.6]# cd /etc/dahdi/
[root@new-host-8 dahdi]# ls
init.conf modules system.conf
please keep in mind that the system.conf works as zaptel.conf in zaptel
the part of system.conf will be like this:
# And change channel 2 to use the kb1 echo canceller.
#echocanceller=kb1,2
#
=================D210P==
span=1,0,0,ccs,hdb3
span=2,0,0,ccs,hdb3
bchan=1-15,17-31
dchan=16
bchan = 32-46,48-62
dchan = 47
======================
6.2) edit the chan.dahdi.conf in /etc/asterisk
the part of chan_dahdi.conf should be like this:
;stripmsd=1
;callerid=asreceived
==================
context=zap-in
switchtype=euroisdn
pridialplan=national
signalling=pri_cpe
usecallerid=yes
hidecallerid=no
callwaiting=yes
callwaitingcallerid=yes
threewaycalling=yes
transfer=yes
cancallforward=yes
echocancel=yes
rxgain=0.0
txgain=0.0
group=1
callgroup=1
pickupgroup=1
immediate=no
callprogress=no
callerid=asreceived
group=1
signalling=pri_cpe
channel => 1-15,17-31
group=2
signalling=pri_cpe
channel => 32-46,48-62
==================
the chan_dahdi.conf works as zapata.conf, so do not be confused.
6.3) edit extensions.conf
for incoming line: // for example only
================
[zap-in]
;
; We start with what to do when a call first comes in.
;
exten => s,1,Wait(1) ; Wait a second, just for fun
exten => s,n,Answer ; Answer the line
exten => s,n,Dial(dahdi/13) // zap has been changed to dahdi
exten => s,n,Hangup
==================

7) modprobe dahdi
Cool modprobe wct4xxp // for D110P, run wcte11xp
Cool dahdi_cfg -vvvvvvv // note: ztcfg changes dahdi_cfg. more commands are under /usr/sbin
============result of dahdi_cfg=========
DAHDI Tools Version - 2.0.0

DAHDI Version: 2.0.0
Echo Canceller(s):
Configuration
======================

SPAN 1: CCS/HDB3 Build-out: 0 db (CSU)/0-133 feet (DSX-1)
SPAN 2: CCS/HDB3 Build-out: 0 db (CSU)/0-133 feet (DSX-1)

Channel map:

Channel 01: Clear channel (Default) (Slaves: 01)
Channel 02: Clear channel (Default) (Slaves: 02)
Channel 03: Clear channel (Default) (Slaves: 03)
Channel 04: Clear channel (Default) (Slaves: 04)
Channel 05: Clear channel (Default) (Slaves: 05)
Channel 06: Clear channel (Default) (Slaves: 06)
Channel 07: Clear channel (Default) (Slaves: 07)
Channel 08: Clear channel (Default) (Slaves: 0Cool
Channel 09: Clear channel (Default) (Slaves: 09)
Channel 10: Clear channel (Default) (Slaves: 10)
Channel 11: Clear channel (Default) (Slaves: 11)
Channel 12: Clear channel (Default) (Slaves: 12)
Channel 13: Clear channel (Default) (Slaves: 13)
Channel 14: Clear channel (Default) (Slaves: 14)
Channel 15: Clear channel (Default) (Slaves: 15)
Channel 16: D-channel (Default) (Slaves: 16)
Channel 17: Clear channel (Default) (Slaves: 17)
Channel 18: Clear channel (Default) (Slaves: 1Cool
Channel 19: Clear channel (Default) (Slaves: 19)
Channel 20: Clear channel (Default) (Slaves: 20)
Channel 21: Clear channel (Default) (Slaves: 21)
===========skip some channels========
9) start asterisk by asterisk -vvvvvvvvgc
under asterisk console, run: dahdi show channels
===================================
new-host-11*CLI> dahdi show channels
Chan Extension Context Language MOH Interpret Blocked State
pseudo zap-in default In Service
1 zap-in default In Service
2 zap-in default In Service
3 zap-in default In Service
4 zap-in default In Service
5 zap-in default In Service
6 zap-in default In Service
7 zap-in default In Service
8 zap-in default In Service
9 zap-in default In Service
10 zap-in default In Service
11 zap-in default In Service
12 zap-in default In Service
13 zap-in default In Service
14 zap-in default In Service
15 zap-in default In Service
17 zap-in default In Service
18 zap-in default In Service

10) make a inbound call to test calls
this is only very brief info for dahdi, later, i will add more details for that. if you have any problem, please always refer these links:
voip-info.org
asterisk.org
openvox.com.cn
README file under dahdi-linux
=======================
test environments:
OpenVox D110P/D210P/D410P
Dhadi-linux-2.0.0
libpri-1.4.7
asterisk-1.6.0.1
Centos-5.0
OpenVox D110P/D210P/D410P
========================
regards!
James.zhu

Thursday, December 18, 2008

Four port Asterisk Analog cards + Dahdi

hello, all of users:
To install OpenVox a400p with dahdi, install some support packages as zaptel requires, then please go through these steps:
1) get dahdi-linux, dahdi-tools and asterisk
wget http://downloads.digium.com/pub/asterisk/releases/asterisk-1.6.0.1.tar.gz
wget http://downloads.digium.com/pub/telephony/dahdi-linux/dahdi-linux-2.0.0.tar.gz
wget http://downloads.digium.com/pub/telephony/dahdi-tools/dahdi-tools-2.0.0.tar.gz
please unzip and cpoy those files to /usr/src/dahdi/dahdi-com(please note that this my dir, you can set to /usr/src)
2) please change back to /usr/src/dahdi/dahdi-com/dahdi-linux-2.0.0
run: make, make install
3) change the directory to /usr/src/dahdi/dahdi-com/dahdi-tools-2.0.0
run: ./configure, make, make install
4) change to asterisk directory, in my case is /usr/src/dahdi/asterisk-1.6
4.1) ./configure
4.2) make
4.3) make install
4.4) make samples
5) please edit the dahdi files
5.1) edit the system.conf under /etc/dahdi, some files are there:
[root@new-host-8 asterisk-1.6]# cd /etc/dahdi/
[root@new-host-8 dahdi]# ls
init.conf modules system.conf
please keep in mind that the system.conf works as zaptel.conf in zaptel
the part of system.conf will be like this:
# And change channel 2 to use the kb1 echo canceller.
#echocanceller=kb1,2
#
fxsks=1
fxsks=2
fxoks=3-4
5.2) edit the chan.dahdi.conf in /etc/asterisk
the part of chan_dahdi.conf should be like this:
;stripmsd=1
;callerid=asreceived
group=0
signalling=fxs_ks
context=demo
channel => 1
channel => 2
signalling=fxo_ks
context=from-internal
channel => 3-4
the chan_dahdi.conf works as zapata.conf, so do not be confused.
5.3) edit extensions.conf
for incoming line: // for example only
================
[demo]
;
; We start with what to do when a call first comes in.
;
exten => s,1,Wait(1) ; Wait a second, just for fun
exten => s,n,Answer ; Answer the line
exten => s,n,Dial(dahdi/3) // zap has been changed to dahdi
exten => s,n,Hangup
==================
for internal:
===================
[from-internal]
exten => 1,1,Dial(dahdi/4|60|m(default)) // zap has been changed to daidi
exten => 1,2,hangup
exten => 2,1,Dial(dahdi/3|60|m(default)) // zap has been changed to dahdi
exten => 2,n,Hangup
======================
6) modprobe dahdi
7) modprobe wctdm
Cool dahdi_cfg -vvvvvvv // note: ztcfg changes dahdi_cfg. more commands are under /usr/sbin
============result of dahdi_cfg=========
[root@new-host-8 ~]# dahdi_cfg -vvvvvvvv
DAHDI Tools Version - 2.0.0

DAHDI Version: 2.0.0
Echo Canceller(s):
Configuration
======================


Channel map:

Channel 01: FXS Kewlstart (Default) (Slaves: 01)
Channel 02: FXS Kewlstart (Default) (Slaves: 02)
Channel 03: FXO Kewlstart (Default) (Slaves: 03)
Channel 04: FXO Kewlstart (Default) (Slaves: 04)


4 channels to configure.



9) start asterisk by asterisk -vvvvvvvvgc
under asterisk console, run: dahdi show channels
===================================
*CLI> dahdi show channels
Chan Extension Context Language MOH Interpret Blocked State
pseudo from-internal default In Service
1 demo default In Service
2 demo default In Service
3 from-internal default In Service
4 from-internal default In Service
10) make a inbound call:
*CLI> -- Starting simple switch on 'DAHDI/1-1'
-- Executing [s@demo:1] Wait("DAHDI/1-1", "1") in new stack
-- Executing [s@demo:2] Answer("DAHDI/1-1", "") in new stack
[Oct 15 21:18:01] WARNING[2908]: chan_dahdi.c:1700 dahdi_enable_ec: Unable to enable echo cancellation on channel 1 (No such device) // here may has problem
-- Executing [s@demo:3] Dial("DAHDI/1-1", "dahdi/3") in new stack
-- Called 3
-- DAHDI/3-1 is ringing
-- DAHDI/3-1 is ringing
==========================
this is only very brief info for dahdi, later, i will add more details for that. if you have any problem, please always refer these links:
voip-info.org
asterisk.org
openvox.com.cn
README file under dahdi-linux
regards!
James.zhu

Her........


My daughter -three years old



my daughter. hmmm, She is three years old.
These pictures took at her birthday.
Happy birthday to you!
Baba and Mama love you.

add a new asterisk URL

i add a new rl for asterisk in China.
http://www.cnasterisk.com