当前位置:网站首页>性能工具 -- jmeter 环境准备
性能工具 -- jmeter 环境准备
2022-07-19 17:39:00 【zyanwei2018】
Java环境变量配置
#! /bin/bash
JAVA_HOME='/usr/java/jdk1.8.0_60'
# /etc/profile
# ~/.bash_profile
echo "" >> /etc/profile
echo "export JAVA_HOME=$JAVA_HOME" >> /etc/profile
echo "export PATH=\$PATH:\$JAVA_HOME/bin" >> /etc/profile
echo "export CLASSPATH=.:\$JAVA_HOME/lib/dt.jar:\$JAVA_HOME/lib/tools.jar" >> /etc/profile
source /etc/profile
echo `java -version`
Jmeter环境变量配置
#! /bin/bash
echo "" >> /etc/profile
JMETER_HOME='/root/lt/apache-jmeter-5.4.3'
echo "export JMETER_HOME=$JMETER_HOME" >> /etc/profile
echo "export PATH=\$PATH:\$JMETER_HOME/bin" >> /etc/profile
source /etc/profile
echo `jmeter -v`
slave节点jmeter工具和脚本上传准备
#! /bin/bash
export jm_zip="apache-jmeter-5.4.3.zip"
export jm_pkg="apache-jmeter-5.4.3"
echo '1. 判断~/lt目录是否存在 ,并进入 '
if [ -d "~/lt/" ];then
cd ~/lt/
else
mkdir -p ~/lt && cd ~/lt
fi
echo '==============================================='
echo '2. 将 jmeter工具和参数化数据放到~/lt目录下 '
if [ -f "/tmp/${jm_zip}" ];then
mv /tmp/${jm_zip} ./${jm_zip}
echo "将jmeter压缩包移动到~/lt目录下"
else
echo "/tmp/${jm_zip}文件不存在"
fi
if [ -f /tmp/test*.txt ];then
mv /tmp/test*.txt ./test1.txt
echo "将参数化数据移动到~/lt目录下"
else
echo "/tmp/test*.txt文件不存在"
fi
echo '==============================================='
echo '3. 安 装 upzip解 压 工 具 '
if ! [ -x "$(command -v unzip)" ]; then
echo 'password' | sudo -S yum install -y unzip
else
echo '已安装'
fi
echo '==============================================='
echo '4. 解 压 jmeter zip文 件 '
if [ ! -d "~/lt/${jm_pkg}" ];then
echo '开始解压 '
unzip ~/lt/${jm_zip}
else
echo '文件已解压 '
fi
echo '==============================================='
echo '5. 修 改 jmeter.properties配 置 '
sed -i '/#server.rmi.ssl.disable=false/a\server.rmi.ssl.disable=true' ~/lt/${jm_pkg}/bin/jmeter.properties
echo '==============================================='
echo '6. 将压测数据移动到bin目录下 '
if [ -f test1.txt ];then
mv test1.txt ~/lt/${jm_pkg}/bin/test1.txt
else
echo ""
fi
echo '==============================================='
echo '7. 请使用命令启动服务'
echo '==============================================='
echo `sh ~/lt/apache-jmeter-5.4.3/bin/jmeter-server`
echo '==============================================='
边栏推荐
猜你喜欢
牛血清白蛋白/羟基磷灰石(BSA/HA)复合纳米颗粒/龙葵碱人血清蛋白纳米粒的研究
C2B模式下优惠券架构演进
数据治理新动态:欧盟发布数据治理研究报告,对国内有何影响
我遇见了我 | 虚拟数字人养成,FaceGood 虚拟数字人开源技术研讨会
[open source] magicdata Ramc: 180 hour Chinese conversational voice data set officially released
Wechat applet development uses onreachbottom to realize page bottom loading and paging
The difference between BL and LDR jump program
使用 Abp.Zero 搭建第三方登录模块(三):网页端开发
Magichub重口音对话语音识别挑战赛报名开始
Prepare for the interview and stick to the second sentence of "100 days and 100 questions · basic chapter" - basic data types and operators!
随机推荐
FileBeat6.4 快速上手
Elk cluster architecture optimization
[arrays and common operations of arrays]
Commonly used operations on tensor shape in pytorch
网易游戏 Flink SQL 平台化实践
关于GCC编译常用命令
window常用API
通过屏幕交互绘制贝塞尔曲线
Magic Data上榜互联网周刊2022数字经济100强
pytorch中常用对张量shape的操作
ICASSP 2022 Women Session Only in Shenzhen
IO flow sub total
The use of DML in graphical interface tools
MagicData-RAMC数据集测评 | 西北工业大学冠军队分享
The first batch of | magic data and other 10 enterprises promote the product evaluation of the data annotation platform of the Chinese Academy of communications
Mysql常用语句知识点
百度、阿里、腾讯,谁最先倒下?
【数组及数组的常用操作】
DML中delete和truncate的区别
The difference between BL and LDR jump program