上传JMETER到测试服务器,解压到/home/zicheng.sun/jmeter
配置环境变量
vi ~/.bashrc
# .bashrc
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
JAVA_HOME=/data/softwares/jdk-1.7.0-67
PATH=$JAVA_HOME/bin:$PATH
CLASSPATH=:$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/tools.jar
export JMETER=/home/zicheng.sun/jmeter/apache-jmeter-2.13
export CLASSPATH=${JMETER}/lib/ext/ApacheJMeter_core.jar:${JMETER}/lib/jorphan.jar:$JMETER/lib/logkit-2.0.jar:${CLASSPATH}
export PATH=${JMETER}/bin/:${PATH}
export JAVA_HOME
export PATH
export CLASSPATH
esc键,输入:wq
保存后 使配置的环境变量生效 source ~/.bashrc
验证安装成功 jmeter -v
成功后会显示如下信息
Copyright (c) 1998-2015 The Apache Software Foundation
Version 2.13 r1665067
成功后就可以设计测试场景 开始测试了