1. 程式人生 > >LoadRunner的Loadgenerator在unix(linux)下的安裝及執行。

LoadRunner的Loadgenerator在unix(linux)下的安裝及執行。

Loadgenerator在unix和linux下的安裝包可以在hp網站下到,我就不贅述了。安裝難度應該不是很大,關鍵是安裝完成後的環境變數設定,以及verify_generator.

安裝完成後,/opt/HP/HP_LoadGenerator/會有一個env.csh。需要把它裡面的環境變數加到.csh或.profile檔案中。
? For C shell users, the startup configuration file is the .cshrc file
? For Bourne and Korn shell users, the startup configuration file is the
.profile file.

我當時是在linux,bash環境下,所以在root目錄找到.bashrc檔案,新增以下幾句話:

export PRODUCT_DIR=/opt/HP/HP_LoadGenerator

export M_LROOT=$PRODUCT_DIR

export LD_LIBRARY_PATH=${M_LROOT}/bin

export PATH=${M_LROOT}/bin:$PATH
需要注消再登入後bash生效。

然後執行/opt/HP/HP_LoadGenerator/bin目錄下的verify_generator

結果提示:[
[email protected]
bin]# ./verify_generator
Environment variable M_LROOT must be set to the product directory
in order for verify_generator to execute.
Please setenv/export (csh/sh) it and run verify_generator again

通過[[email protected] bin]# env |grep PRODUCT_DIR
輸出:exportT_DIR=/opt/HP/HP_LoadGenerator
於是嘗試用切換到csh環境
[
[email protected]
bin]# csh
再次執行verify_generator
提示如下:
[[email protected] bin]# ./verify_generator
===================================================
HP
Vuser Environment Verification Utility
===================================================

Product: HP LoadRunner 9.50
Version: 09.50.0000
Build: 3378
verify_generator can not run as superuser, please login again

切換到普通使用者:
[
[email protected]
bin]# su lxj
bash: /home/lxj/.bashrc: 許可權不夠
bash-3.1$
bash-3.1$
bash-3.1$
bash-3.1$
bash-3.1$
bash-3.1$ csh

再次執行verify_generator

[[email protected] bin]$ ./verify_generator
===================================================
HP
Vuser Environment Verification Utility
===================================================

Product: HP LoadRunner 9.50
Version: 09.50.0000
Build: 3378
localhost.localdomain:

verify_generator...OK
verify_generator...OK
verify_generator...OK
Warning: The file .rhosts does not exist in the home directory of the user.
Verify $M_LROOT ...Failed
_____It was not possible to set the $M_LROOT from
_____the shell dot files. One of several things might be happening:
_____1) $M_LROOT is not set at all in the shell dot files.
_____2) There is some error in the shell dot files which stops their execution
_____ before it sets $M_LROOT.
_____3) There is conditional code in the shell dot files (most likely related to
_____ interactive and non interactive shells) and $M_LROOT is set
_____ only in one of the sections.
_____Aborting virtual user tests on host localhost.localdomain
verify_generator...OK

看到了大家期望的ok.

至於和Controller Connection

有兩種方式:

Checking Controller Connection
By default, the Controller connects remotely to the load generator using rsh
(remote shell). You need to make sure that the load generator can be
remotely accessed by the Controller.
To make sure that the load generator can be remotely accessed by the
Controller:
1 On the load generator machine, go to the .rhosts file, located in the user
home directory.
2 In the .rhosts file, verify that the Controller is included in the list of
machines. If it is not listed, add it to the list.
If the Controller still cannot connect to the load generator, contact your
system administrator.
Note: You can configure the Controller to connect to the load generator not
using rsh. In this case, you need to activate the agent daemon on the load
generator. For more information, see the “Connecting to a UNIX Load
Generator Without Using RSH” below.
Connecting to a UNIX Load Generator Without Using RSH
This section describes how to connect to a UNIX load generator without
using RSH.
To connect to a UNIX load generator without RSH:
1 On the UNIX load generator, run the agent daemon by running the
following command from <load generator installation directory>/bin:
m_daemon_setup -install
This runs a daemon called m_agent_daemon, and if successful you will
receive a message: m_agent_daemon <process ID>.
The agent will now keep running, even if the user is logged off. It will only
stop running using the command explained in step 3 below, or by rebooting
the machine.
Note: If you look at the log file m_agent_daemon[xxx].log in the temp
directory, you may see communication errors, even if the installation
succeeded:
These messages appear because the LoadRunner agent always tries to open
port number 443 (because any agent can be a MI Listener, and the MI
Listener always listens to this port), and in UNIX machines, this port cannot
be opened by any user except for the root user. However, this will not
interfere with using this agent for the load generator.
2 In the Controller, in the Generators > Load Generator Information > UNIX
Environment tab, select the Don’t use RSH option. Connect as usual.
3 To stop the agent daemon, run the following command from the
<LR_root>/bin directory:
m_daemon_setup -remove
This stops the m_agent_daemon, and if successful, you will receive a
message: m_agent_daemon is down.

rsh方式,記得Controller機器需要有rsh客戶端。


ok,介紹到這裡,tks.



轉自:http://liuxijie.cto.csdn.net/Article.aspx?Name=liuxijie&pointid=1683

相關推薦

LoadRunner的Loadgenerator在unix(linux)安裝執行

Loadgenerator在unix和linux下的安裝包可以在hp網站下到,我就不贅述了。安裝難度應該不是很大,關鍵是安裝完成後的環境變數設定,以及verify_generator. 安裝完成後,/opt/HP/HP_LoadGenerator/會有一個env.csh。

linux安裝配置jenkins(war包)

eight 成功 .html 輸入 需要 目錄 bubuko grep test 1、由於Jenkins是基於Java開發的,安裝前確認操作系統已經安裝了jdk和tomcat 如何安裝,請參考WINDOWS/LINUX上部署TOMCAT服務器 2、下載war包: htt

linux 安裝執行kettle 程式

一、建立使用者 groupadd kettle useradd -r -g kettle kettle 二、下載並解壓安裝包 unzip pdi-ce-7.1.0.0-12.zip chown kettle.kettle data-integration -R cd d

知識積累--linux--安裝nodejs--執行window編譯過的專案

前景提要:       在本地windows環境下,做了一個專案,需要使用nodeJs環境,於是乎本地安裝了下nodeJs也配置了環境變數,專案執行著也沒有問題,現要將專案部署到linux的線上環境,在安裝nodeJS和執行npm run build,npm run

Linux安裝&執行Jmeter程式

Jmeter在linux系統中執行需要安裝jdk和Jmeter兩個軟體; 1、安裝JDK 先檢查系統是否有安裝jdk,在linux中執行如下命令:java -version  如果返回版本資訊,說明系統中已經安裝好了jdk,則可跳過安裝jdk,直接安裝Jmeter; 如果返回的是commo

Linux安裝操作SQL資料庫

——————————————————————————————————————— 主機作業系統:Centos 6.7 安裝配置:SQL資料庫郵箱:[email protected]——

Linux安裝簡單使用nmap/zenmap

作用: 檢測網路上的主機 檢測主機上開放的埠 檢測作業系統,硬體地址,以及軟體版本 檢測脆弱性的漏洞(Nmap的指令碼) 1/yum安裝: 命令:yum install nmap 安裝後可執行命令: nmap -h 檢視幫助文件,如有幫助文件則表示安裝成功

ElasticSearch之——linux安裝head外掛

轉載請註明出處:https://blog.csdn.net/l1028386804/article/details/79955325系統環境: vm12 下的centos 7.2當前安裝版本: elasticsearch-2.4.0.tar.gz安裝和學習可參照官方文件: 安

linux安裝配置jenkins

jenkins常用的有兩種安裝方式: 1、直接下載war包jenkins.war,下載地址https://jenkins.io/download 直接下載 1.1、可以把war包直接部署到servlet容器中,如tomcat。 1.2、可以使用命令直接執行wa

Linux安裝使用sqlite3資料庫

資料庫 資料庫(Database)是按照資料結構來組織、儲存和管理資料的倉庫,它產生於距今六十多年前,隨著資訊科技和市場的發展,特別是二十世紀九十年代以後,資料管理不再僅僅是儲存和管理資料,而轉變成使用者所需要的各種資料管理的方式。資料庫有很多種型別,從最簡單

LinuxMysql的安裝執行(詳解)

1、組及使用者建立: sudo groupadd mysql #新增組 sudo useradd -r -g mysql mysql #新增所建立組下的使用者 2、官方下載網址 wget http://downloads.mysql.com/archives/get/file/mysql-5

LinuxVTK、ITK的安裝執行 轉載

Linux下VTK、ITK的安裝及執行  轉載 (2011-08-01 19:42:10) 轉載▼ 標籤: it 1.安裝VTK   (1)在www.cmake.org下載cmake-2.4.6.tar.gz,並安裝好    (2)在www.vtk.org上

win10linux子系統安裝卸載

net .cn rep art blog .net 系統安裝 msd 人員 參考資料: https://linux.cn/article-7209-1.html https://msdn.microsoft.com/en-us/commandline/wsl/refe

linux安裝mysql5.7.17簡單配置

http mkdir exp 重要 ble ges 選擇 bsp 統一 1.mysql5.7.17安裝在/usr/local/mysql目錄裏面,也可以安裝在其他地方 (安裝包最好與Linux系統一樣,eg;64位的就是“mysql-5.7.17-linux-glibc2.

linux安裝protobufcmake編譯

light present mini require fetching AS exp web .gz 一.protobuf 安裝 protobuf版本:2.6.1 下載地址:https://github.com/google/protobuf/archive/v2.6.1.

linux安裝nexus repositoryIntellij Idea集成私有maven

files usm codehaus ima sna rem 依賴 技術分享 active 前段日子公司搞java項目,使用nexus repository搭建了私有maven庫,現在把原來的私有nuget也遷到nexus repository上了,下面介紹下搭建流程:

Linux安裝Sublime Text 3 使用快捷方式

進入 快捷 back pos tex AD ppa linux下 一個 1.添加sublime text3的倉庫 首先按下快捷鍵ctrl+alt+t打開終端; 在終端輸入:sudo add-apt-repository ppa:webupd8team/sublime-tex

Linux安裝python的gmpy2庫遇到無法定位軟件包的解決辦法

mpc python source 遇到 gmp img 定位 date get gmpy2需要gmp.h &mpfr.h &mpc.h 安裝命令: sudo apt-get install livmpfr-dev libmpc-dev 成功之後再輸入安裝

linux安裝libcurl開源庫的一般安裝步驟

tps .com 開啟 怎麽 是個 默認 常用 inux 就是   前言   總有人說:要多看源代碼!那麽源代碼去哪找呢?找到了又該怎麽安裝呢?本票博客不介紹如何使用和學習,只要講獲取和安裝,以後會將curl和libevent的使用和學習。   一、開源庫常用安裝步驟

Linux安裝配置 http ,修改本機中http伺服器主頁,自定義顯示內容

HTTP(Hyper Text Transfer Protocol) 超文字傳輸協議,位於osi模型中的應用層。               安裝:可以使用yum等多種方式安裝,最方便的自然是yum安裝(Redhat需