使用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
5453

被折叠的 条评论
为什么被折叠?



