51Testing软件测试论坛

 找回密码
 (注-册)加入51Testing

QQ登录

只需一步,快速开始

微信登录,快人一步

查看: 2245|回复: 0
打印 上一主题 下一主题

LoadRunner: Set environment variables for Java Vuser recording

[复制链接]

该用户从未签到

跳转到指定楼层
1#
发表于 2006-10-25 14:08:49 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
Description

      Tips to set the Java environment correctly for recording a Java application in Vugen.


Solution

      The attached document provides details for the necessary tips to set the Java environment correctly for recording a Java application using Vugen.
Use this before trying to record a RMI-Java , Corba-Java or just Java Vuser.

....................................
      TIPS TO ENSURE THAT ENVIRONMENT FOR A JAVA RECORDING IS SETUP CORRECTLY
   ============================================================================

1) Open Vugen and click on File | New | Java Template Vuser. Having opened the empty script, go ahead and run it.

If you see the following error or similar errors, you are probably missing the LoadRunner Java-Addin, do not have the environment variables set correctly or do not have the JDK install itself.

Error -10492 : Exception was raised when calling per-process-init function in extension java_int.dll: System Exceptions 0xc0000005: EXCEPTION_ACCESS_VIOLATION
Error -10598 : Cannot initialize extension java_int.dll.

2) Go to the Settings | Control Panel | System and click on the Environment tab.
  
In the System variables, go to the PATH and add the following
   a) Provide absolute path to 'jdk\bin'
   b) Provide absolute path to 'Loadrunner\bin'
   c) Provide absolute path to 'jdk\jre\bin\classic'       

The above three MUST be in the order specified as above and should be the first 3 values.

(NOTE: If you do not have 'JDK' installed you need to get it from Sun website. A 'JRE' installation alone is NOT sufficient, LoadRunner requires a complete JDK installation.

If there have multiple version of JDK installed, open DOS Prompt and type 'java -version' which will tell you what version of Java you have set.

LoadRunner supports Java 1.1.8 and above.

JDK 1.1.8-> http://java.sun.com/products/jdk/1.1/

JDK 1.2.2-> http://java.sun.com/products/jdk/1.2/

JDK 1.3 --> http://java.sun.com/j2se/1.3/

If you have JDK 1.3, you should be able to run the application from DOS with the -classic flag. If the application works fine, LoadRunner should not have a problem recording it. )

Click on 'Set' and then 'Apply' button.

In the System variables, go to the CLASSPATH and add the following
   d) Provide absolute path to 'Loadrunner\classes'
   e) Provide absolute path to 'Loadrunner\classes\srv'

The above two MUST be in the order specified as above and should be the first 2 values. If you have LoadRunner 6.5 and do not find the 'Loadrunner\classes\srv' folder you need to install the 'JavaAddin.exe'.










The latest build of the java-Addin for LoadRunner can be obtained from the customer support website in the downloads section.
For LoadRunner 7.0 and above, the latest java-Addin is integrated with the product.

   f) You must ensure that the classes being used by your application are included in the CLASSPATH too.

   g) If you have JDK 1.2.x and above you need to provide absolute path to 'jdk\jre\lib\rt.jar'

For JDK 1.1.x you need to have 'jdk\lib\classes.zip' (version 1.1.7 and below are no longer supported.)

This MUST be the LAST value provided after having specified the application classes.

3) Having done this, close Vugen and open Vugen again.

4) Repeat steps 1-3 till you have the empty Java Template script running for you.

5) If inspite of having set all the environment variables and verifying that you have a correct JDK install you still have problems replaying the empty Java Template script or recording your Java application call Mercury Customer support.
分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏
回复

使用道具 举报

本版积分规则

关闭

站长推荐上一条 /1 下一条

小黑屋|手机版|Archiver|51Testing软件测试网 ( 沪ICP备05003035号 关于我们

GMT+8, 2024-5-4 15:05 , Processed in 0.064337 second(s), 23 queries .

Powered by Discuz! X3.2

© 2001-2024 Comsenz Inc.

快速回复 返回顶部 返回列表