Using SIPp to do performance test for opensips
Related Site
About SIPp
SIPp
Github code
Doc pdf
Doc pdf for Chinese
Doc Web
Using SIPp to do performance test
蜜果私塾:使用SIPP来进行SIP压力测试(2)
使用sipp对FreeSwitch进行测试(Linux环境,会议模式)
SIPp-惡搞SIP的工具
SIPp & Opensips
SIP Stress Testing -Part 1 (Opensipsctl & OpenSIPS-CP)
SIP Stress Testing -Part 3 (SIPp)
Performance Evaluation Framework for
a SIP-based Telecommunication Call
Handling System
VoIP Cookbook: Transaction Oriented Test using SIPp
VoIP Cookbook: Building your own Telecommunication Infrastructure
Asterisk Stress testing (with Media) Using SIPp
利用SIPp对SIP Proxy进行Register压测用到的文件
Install
- Download source code
- Make clear the way to install
- Update autoconf (no use when running yum update autoconf)
- 查看当前版本 #rpm -qf /usr/bin/autoconf
- 卸载当前版本 #rpm -e –nodeps autoconf-2.63
- 下载新版本 wget http://ftp.gnu.org/gnu/autoconf/autoconf-2.69.tar.gz
- 解压安装
- 查看是否安装成功 #/usr/bin/autoconf -V
- I install it without any special features
- Maybe I will use some features in the future, so I decide to reinstall with full
- There are a lot of dependencies that need to install in advance:
- C++ yum install gcc-c++ libstdc++-devel
- ncurses (already installed)
- OpenSSl (already installed)
- Pcap yum -y install libpcap-devel
- lksctp-tools
- GSL
- But after I intall all above packages, there are still error when I run ./build.sh –full
- Successful when running ./build.sh –with-pcap –with-sctp –with-openssl
- Update autoconf (no use when running yum update autoconf)
Using default uac.xml
Cmd
sipp -sn uac -m <total call numbers> -i <opensips ip> -s <callee number> <opensips ip> -r <call number per second>
Allocate caller number in opensips.cfg file.
Using sipcapture.so
- vi opensips.cfg
loadmodule "sipcapture.so"
modparam("sipcapture", "db_url","mysql://<user>:<pw>@<mysql ip>:<port>/<database name>")
modparam("sipcapture", "table_name", "sip_capture")
modparam("sipcapture", "capture_on", 1)
/* activate HEP capturing */
modparam("sipcapture", "hep_capture_on", 1)
In the specified method that you want to capture packet:
sip_capture();
- Download sipcapture-create.sql from net
- Enter database
- mysql -u root -p
- show databases;
- use databases;
- source ./sipcapture-create.sql;
Solving problems
ERROR:
Field ‘diversion’ doesn’t have a default value
sipcapture:sip_capture_store: failed to insert into databaseSolve:
Add default value to diversion field or disable strict mode in mysql.
- Add default value
- find the variable in the table, double click the default area and choose ‘Custom’
- Disable strict mode
- 配置my.ini(my.cnf),去掉:STRICT_TRANS_TABLES 重新启动mysql服务
- my.ini配置代码
- Restart mysql: service mysql/mysqld restart
# Set the SQL mode to strict
# sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
sql-mode="NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
参考文献
[解决方法]MySQL #1364 – Field “details” doesn’t have a default value
kamailio keep logging ‘diversion’ doesn’t have a default value