ip欺骗

上一篇 / 下一篇  2007-10-24 15:15:41 / 个人分类:测试工具

摘自###人空间
Loadrunner学习笔记之ip欺骗
ip欺骗设置:
1.在总控机上使用loadrunner->tools-> ip wizard工具设置虚拟ip,其中server ip指要监控的服务器的ip,添加ip时选择A、B或C类ip,设置开始ip和要添加的虚拟ip 的个数,并选中verify the new ip addresses are not already use,已检查添加的ip是否与局域网中的其 它ip冲突
2.重启机器
3.在controller的scenario中勾选enable ip spoofer,启用虚拟ip
3.在controller的tools中选中expert mode,在options->general中设置multiple ip address mode与run-time settings中的multithreading设置保持一致
4.在load generators中选择localhost
查看脚本执行过程中是否使用了设置的虚拟ip,可以如下设置:
在脚本中添加代码:
char *ip = lr_get_vuser_ip();
if (ip)
     lr_output_message("The IP address is %s", ip);
else
     lr_output_message("IP spoofing disabled");
在脚本运行过程中查看controller的output,view->show output,选择all messages,查看输出的ip是否为设置的虚拟ip

我想进行ip欺骗,模拟多个客户端连接发送数据包到服务器,可是打开ip wizard发现错误提示:"the ip wizard does not support dhcp-enabled network cards.your network card is either dhcp-enabled or configured with invalid settings"

原来公司用的是动态ip,ip wizard不能识别动态网段。



TAG: 测试工具

 

评分:0

我来说两句

Open Toolbar