转:Loadrunner报错“Too many local variablesAction.c”解决方法

时间:2022-05-29 05:45:47

问题描述,在Action.c里定义数组时如果数组长度过长,如char a[1024*1024]运行时即会报错

问题原因及解决方法如下:

1. VuGen对于局部变量可以分配的最大内存为64K,如果想分配空间大于64K的变量的话,需要通过如下方法:

VuGen has a limitation of 64K for local variables. If you want to declare a variable larger than 64K:

a. 将其定义为全局变量,Declare it globally.

1 char buffer[100000];
2  
3 Actions()
4  
5 {
6  
7 return 0;
8  
9 }

b. 使用malloc()来分配内存,Use malloc() to allocate the memory.

1 Actions()
2  
3 {
4  
5 char *buffer = (char *) malloc(100000);
6  
7 /*Remember to free it when you do not need it*/
8  
9 free(buffer);
10  
11 return 0;
12  
13 }

2. 如果在录制脚本后进行回放时报错,可以按照下面步骤进行配置:

If you have this problem replaying a large database script in LoadRunner 7.8 or above, immediately after recording.

a. Go to Tools -> Regenerate Vusers...

b. Click on 'Options...' to edit the recording options

c. Under General:

1. Script section, enable the option for "Split action section to functions by event".By default, this is not enabled and it has a value of "500". This option is useful for when the action section is rather large

2. Script and select "Maximum number of lines in action file", change the value to 30000 and regenerate again

 

转:Loadrunner报错“Too many local variablesAction.c”解决方法的更多相关文章

  1. Loadrunner报错“Too many local variablesAction.c”解决方法

    问题描述,在Action.c里定义数组时如果数组长度过长,如char a[1024*1024]运行时即会报错: 意思为:太多的局部变量 问题原因及解决方法如下: 1. VuGen对于局部变量可以分配的 ...

  2. 安装PHP过程中,make步骤报错:(集合网络上各种解决方法)

    安装PHP过程中,make步骤报错:(集合网络上各种解决方法) (1)-liconv -o sapi/fpm/php-fpm /usr/bin/ld: cannot find -liconv coll ...

  3. shell报错:-bash: [: ==: 期待一元表达式 解决方法 ([: ==: unary operator expected)

    shell报错:-bash: [: ==: 期待一元表达式 解决方法 ([: ==: unary operator expected) blogdaren 2015-02-26  抢沙发 14916人 ...

  4. linux下svn客户端报错Cannot negotiate authentication mechanism的解决方法

    svn客户端报错Cannot negotiate authentication mechanism的解决方法: 问题出现的原因之一: 因为SVN服务器配置了saslauthd服务用来实现与ldap的对 ...

  5. 关于163发邮件报错535 Error:authentication failed解决方法

    关于发邮件报错535 Error:authentication failed解决方法 调用163邮箱服务器来发送邮件,我们需要开启POP3/SMTP服务,这时163邮件会让我们设置客户端授权码,这个授 ...

  6. zabbix监控报错zabbix server is not running解决方法

    问题描述: 布置好zabbix监控,正常运行.但是重启了虚拟机服务器之后,页面出现如下的报错,而且设置的报信息也是失效的:

  7. python安装locustio报错error: invalid command 'bdist_wheel'的解决方法

    locust--scalable user load testing tool writen in Python(是用python写的.规模化.可扩展的测试性能的工具) 安装locustio需要的环境 ...

  8. Linux服务器init 5启动图形界面,报错Retrigger failed udev events的解决方法

    1.开启linux系统的桌面环境,使用startx未成功,报如下错误: 提示:Retrigger failed udev events [root@ /]# startx xauth: creatin ...

  9. IIS报错:Exception from HRESULT: 0x8007000B解决方法

    报错如下: System.Web.Services.dll 中发生,但未在用户代码中进行处理 其他信息: 服务器无法处理请求. ---> 尝试加载 Oracle 客户端库时引发 BadImage ...

随机推荐

  1. 解决vue与传统jquery插件冲突

    比如基于jquery的select2插件,在vue下单独用有很多问题,其实对于这类插件,可以用vue的自定义指令和组件来包装,解决冲突的问题.引用官方vue1.0和2.0的两个例子,学习一下. 例子1 ...

  2. ember.js里的实用方法

    一款基于jQuery的插件,以下是关于数组的一些方法 var arr = ['Wang', 'Jason', '444128852@qq.com', 'i2cao.xyz', 'ubuntuvim.x ...

  3. FreeBSD打开DTrace支持

    主要翻译自:https://wiki.freebsd.org/DTrace FreeBSD跟Linux发行版一个比较大的差异,就是提倡源码构建.因此这里提到比较多的编译开关设置.自2012年5月后,D ...

  4. kuangbin_ShortPath S (POJ 3169)

    被cow类题目弄得有些炸裂 想了好久好久写了120多行 依然长跪不起发现计算约束条件的时候还是好多麻烦的地方过不去 然后看了看kuangbin的blog 都是泪啊 差分约束的方式做起来只要70多行啊炒 ...

  5. Linux syslog 学习

    最经有在看lighttpd facgi相关的东西.在lighttpd官网上看到如下sample code. #include <stdlib.h> #include <string. ...

  6. easyui源码翻译1&period;32--Layout(布局)

    前言 使用$.fn.layout.defaults重写默认值对象.下载该插件翻译源码 布局容器有5个区域:北.南.东.西和中间.中间区域面板是必须的,边缘的面板都是可选的.每个边缘区域面板都可以通过拖 ...

  7. 使用layer显示弹出框笔记

    $.layer({     area : ['200px','auto'], //控制层宽高.当设置为auto时,意味着采用自适应, 当然,对于宽度,并不推荐这样做.例如:area : ['310px ...

  8. &lbrack;POJ 3764&rsqb; The xor-longest Path

    Description 多组数据 给你一颗树, 然后求一条最长异或路径, 异或路径长度定义为两点间简单路径上所有边权的异或和. Solution 首先 dfs 一遍,求出所有的点到根节点(随便选一个) ...

  9. TensorFlow 运行模型--会话(Session)

    会话模式一: 需要明确调用会话生成函数和关闭函数 # 创建一个会话 sess = tf.Session() # 使用创建好的会话进行运算 sess.run("要运算的对象") # ...

  10. 模式匹配的KMP算法详解

    这种由D.E.Knuth,J.H.Morris和V.R.Pratt同时发现的改进的模式匹配算法简称为KMP算法.大概学过信息学的都知道,是个比较难理解的算法,今天特把它搞个彻彻底底明明白白. 注意到这 ...