常用脚本(四)5000用户

使用sipp测试5000用户并发对freeswitch服务器的压力,其中需要一个文件配置用户ID如下:

1001 1002 authentication username=1001 password=11111
1003 1004 authentication username=1003 password=11111
...
5999 6000 authentication username=5999 password=11111
1002 1001 authentication username=1002 password=11111
...
5998 5997 authentication username=5998 password=11111
6000 5999 authentication username=6000 password=11111

实现脚本:

#!/bin/bash
echo "SEQUENTIAL" >auto_users.xml
for ((i=1001,j=1002;i<6001,j<6002;i+=2,j+=2))
do
      echo "$i;$j;[authentication username='"$i"' password=11111]" >>auto_users.xml
done

for ((i=1002,j=1001;i<6002,j<6001;i+=2,j+=2))
do
      echo "$i;$j;[authentication username='"$i"' password=11111]" >>auto_users.xml
done
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值