Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What is the method of monitoring memory and CPU by JMeter

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

This article introduces the relevant knowledge of "what is the method of JMeter monitoring memory and CPU". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

The JMeter tool can be used for performance testing, but it is not very good at monitoring memory and CPU. This article introduces two ways to monitor memory and CPU.

I. JMeterPlugins plug-in

In many cases, we need to check memory and CPU and other information to determine the bottleneck of the system. Jmeter does not have good support for CPU and memory monitoring. Very often, we can only observe it through the system's resource monitor, and it is very inconvenient for us to flash and not record it. Fortunately, google has developed a special monitoring Jmeter plug-in JMeterPlugins, which makes up for the shortcomings of Jmeter. Here is an introduction to this plug-in-JMeterPlugins.

I am currently using JMeterPlugins-Standard-1.2.0 and ServerAgent-2.2.1 versions.

1.JMeterPlugins download

Use of 2.JMeterPlugins configuration

First of all, decompress the downloaded file to get JMeterPlugins-Standard-1.2.0 and ServerAgent-2.2.1.

The first step is to copy the JMeterPlugins-Standard-1.2.0\ lib\ ext\ JMeterPlugins-Standard.jar package to the ext directory under the lib directory of JMeter, and restart Jmeter

At this point, we click add listener, and we can see that there are a lot of files with the beginning of jp@gc-.

The second step, here to monitor the memory we use is: jp@gc-PerfMon Metrics Collectot, in the Windows environment need to double-click to run / serverAgent/startAgent.bat this file, we need to copy the serverAgent directory and the following files to our testing server, and then click Open (I am here is the local machine, directly in the local machine above to open this application system), its default port is 4444.

When everything is ready, click start to get the following figure:

II. JConsole

JConsole is a gadget that comes with JDK. The steps to open this gadget are very simple. If you have already configured the environment in which Jmeter is running, then you don't have to do any other configuration, just click: start-- "run--" enter cmd-- "and then type" jconsole "in the command line interface that appears to pop up a [java Monitoring and Management console].

Here we select the local process, click the sun.tools.jconsole.JConsole line, and then click Connect to see our memory and CPU usage.

This is the end of the content of "how JMeter monitors memory and CPU". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report