SlideShare a Scribd company logo
Find the Bottleneck
of Your System
Load / Stress Test with JMeter
StarNight
Who am I?
潘建宏 / Jian-Hong Pan (StarNight)
About Me : http://about.me/StarNight
出沒在~
GitHub : starnight
PTT : zack2004
plurk : StarNight
Facebook : StarNight
目前繼續在種花店當個打雜園丁 ~
Outline
● The Bottleneck
● Web / HTTP(S)
○ Request / Response Header and Body
● Load / Stress Test
● Apache JMeter
○ Installation
○ UI Description
○ Test Plan
○ Read Result
○ Parsing and Variables
The Bottleneck
● The operation of a system is the cooperation
between many parts.
○ Nodes(Termial, Server):Clients, Server, DB
○ Connections(Communication)
● The whole system will reach the planned
efficiency, only if each part meets the
planned efficiency criteria.
DB
Server
(Web AP)
Clients
Possible
Bottleneck
Possible Bottleneck
Possible Bottleneck
Possible Bottleneck Possible Bottleneck
Web / HTTP(S)
● It is the protocol between Client and Web
Servers
○ W3C: HTTP Specifications and Drafts
○ IETF: RFC 2616 Hypertext Transfer Protocol / 1.1
■ 4.2 Message Headers, 4.3 Message Body
■ 5.1.1 Method
■ 6.1.1 Status Code and Reason Phrase
● HTTPS: Use SSL certificate to encrypt HTTP
Server
(Web AP)
Clients
HTTP(S) Request
HTTP(S) Response
HTTP Request Header
& Body we can see
Secured HTTP Request
Header & Body
Even though the HTTP is encrypted, you still see the plain text in the browser
● Composite of
○ Request-Line
■ Method sp Request-URI sp HTTP-Version
○ general-header | request-header | entity-header
○ message-body
● Method
○ OPTIONS, GET, HEAD, POST, PUT, DELETE,
TRACE, CONNECT
● Request-URI
○ "*" | absoluteURI | abs_path | authority
● Content-Type
HTTP Request (5)
HTTP Response (6)
● Composite of
○ Status-Line
■ HTTP-Version sp Status-Code sp Reason-Phrase
○ general-header | response-header | entity-header
○ message-body
● Status Code and Reason Phrase
○ 1xx: Informational
○ 2xx: Success
○ 3xx: Redirection
○ 4xx: Client Error
○ 5xx: Server Error
Load / Stress Test
● Load Test
○ Load testing examines the entire environment and
database, while measuring the response time.
● Stress Test
○ Stress testing focuses on identified transactions,
pushing to a level so as to break transactions or
systems.
DB
Server
(Web AP)
Clients
Super Node
HTTP(S) Request
HTTP(S) Response
probe probe
probe
Flow Generator
Apache JMeter
● Java application designed to load test
functional behavior and measure
performance.
It was originally designed for testing Web
Applications but has since expanded to other
test functions.
● http://jmeter.apache.org/
● Apache License Version 2.0
● Getting Started (User’s Manual)
Open Source
is Awesome!
Installation
● Download Page:
○ http://jmeter.apache.org/download_jmeter.cgi
● Requires Java 6 or later
● Excute bin/jmeter.sh or bin/jmeter.bat
● Using JMeter behind a proxy
○ Append the arguments “--proxyHost ProxyServer --
proxyPort ProxyPort” after the ApacheJMeter.jar
command in bin/jmeter.sh or bin/jmeter.bat
UI Description
Test Plan related: Thread, Query Script, Header ...
Workbench to
make Test Plan
How to run the Test Plan
Global User Defined Variables
Start / Stop Test Clear Test Result
Test Plan - Thread Group
Test Plan - Test Script Recorder
Browser
JMeter Proxy
Target
Client
X
There are only HTTP requests and Response
in the World Wide Web.
Open a browser which will go through this proxy
Test Plan - HTTP Request
Test Plan - HTTP Cookie Manager
Cookie - Session
IETF: RFC 6265 / 8.4
Test Plan - HTTP Request Defaults
Variables Default Values
Test Plan: Many other scenarios
● How to use a CSV file with JMeter
○ Many usernames and paswwords for exmaple
● Upload and Download Scenarios with
Apache JMeter
○ Upload files tests
● And so on ...
Test Plan - View Results Tree
Test Plan - Summary Report
Many other listeners ...
Run the Test Plan
Read Result - View Results Tree
Read Result - Summary Report
Parsing
Extract Variables
(.*?)
Variables will be
URL_g1, URL_g2
Place Variables
${URL_g1}
${URL_g2}
Verify Variables
Apache Ant
● 5 Ways To Launch a JMeter
Test without Using the JMeter
GUI
● JMeter Ant Task
● To have a test report in HTML
form
● One may need to add Ant into
the enviroment variable PATH
Use JMeter Ant addon
1. Download Apache Ant and install it
2. Add Ant’s directory into PATH
3. Use the command line:
a. cd Apache JMeters’s extras directory
b. ant -Dtest=Test Plan’s File Name -Dtestpath=Path of
the Test Plan’s File
For example: I put the test.jmx on my desktop
$ cd C:UsersjhpanDesktopapache-jmeter-2.13extras
$ ant -Dtest=test -Dtestpath=C:UsersjhpanDesktop
Find the bottleneck of your system
Thank you ~

More Related Content

PDF
Node.js 1, 2, 3
PDF
Micro HTTP Server Implemented in C @ COSCUP 2016
PDF
Make Your Own Developement Board @ 2014.4.21 JuluOSDev
PDF
What is new in Go 1.8
PDF
Asynchronous, Event-driven Network Application Development with Netty
PPTX
Building your First gRPC Service
ODP
Building Netty Servers
PDF
Blocks, procs && lambdas
Node.js 1, 2, 3
Micro HTTP Server Implemented in C @ COSCUP 2016
Make Your Own Developement Board @ 2014.4.21 JuluOSDev
What is new in Go 1.8
Asynchronous, Event-driven Network Application Development with Netty
Building your First gRPC Service
Building Netty Servers
Blocks, procs && lambdas

What's hot (20)

PDF
Netty: asynchronous data transfer
PDF
WebTalk - Implementing Web Services with a dedicated Java daemon
PDF
gRPC or Rest, why not both?
PDF
Netty @Apple: Large Scale Deployment/Connectivity
PDF
Loom and concurrency latest
PDF
202107 - Orion introduction - COSCUP
DOC
Packet filtering using jpcap
PDF
Networking and Go: An Epic Journey
PDF
Asynchronous IO in Rust - Enrico Risa - Codemotion Rome 2017
PPT
Easy Steps to implement UDP Server and Client Sockets
PDF
gRPC in Go
PDF
Skydive 31 janv. 2016
KEY
Non blocking io with netty
PPTX
Fm wtm12-v2
PDF
Quick Introduction to Kotlin Coroutine for Android Dev
PDF
Skydive 5/07/2016
PDF
The Simple Scheduler in Embedded System @ OSDC.TW 2014
PDF
Adding replication protocol support for psycopg2
PDF
Load testing in Zonky with Gatling
PDF
Skydive, real-time network analyzer, container integration
Netty: asynchronous data transfer
WebTalk - Implementing Web Services with a dedicated Java daemon
gRPC or Rest, why not both?
Netty @Apple: Large Scale Deployment/Connectivity
Loom and concurrency latest
202107 - Orion introduction - COSCUP
Packet filtering using jpcap
Networking and Go: An Epic Journey
Asynchronous IO in Rust - Enrico Risa - Codemotion Rome 2017
Easy Steps to implement UDP Server and Client Sockets
gRPC in Go
Skydive 31 janv. 2016
Non blocking io with netty
Fm wtm12-v2
Quick Introduction to Kotlin Coroutine for Android Dev
Skydive 5/07/2016
The Simple Scheduler in Embedded System @ OSDC.TW 2014
Adding replication protocol support for psycopg2
Load testing in Zonky with Gatling
Skydive, real-time network analyzer, container integration
Ad

Viewers also liked (18)

PDF
Bind Python and C @ COSCUP 2015
PDF
Build a Micro HTTP Server for Embedded System
PDF
Learn How to Develop Embedded System for ARM @ 2014.12.22 JuluOSDev
PPT
Eliminating the production bottlenecks
PDF
Identifying Software Performance Bottlenecks Using Diagnostic Tools- Impetus ...
PDF
People as Bottlenecks
PDF
Adn11 toc bottleneck game
PPTX
Bottleneck of thinking
PPT
Bruce Damer's talk on the Von Neumann Bottleneck to the Singularity Universit...
PDF
Debug C/C++ Programs More Comfortably @ 2014.12.14 Trace Code Meetup
PDF
The Knowledge Reengineering Bottleneck
PDF
Kodak Bottleneck
PPTX
Pqm bottlenecks
PDF
The Considerations for Internet of Things @ 2017
PPTX
Performance Bottleneck Identification
PDF
Requirements the Last Bottleneck
PPTX
Functional Programming in JavaScript by Luis Atencio
PDF
Growth bottleneck
Bind Python and C @ COSCUP 2015
Build a Micro HTTP Server for Embedded System
Learn How to Develop Embedded System for ARM @ 2014.12.22 JuluOSDev
Eliminating the production bottlenecks
Identifying Software Performance Bottlenecks Using Diagnostic Tools- Impetus ...
People as Bottlenecks
Adn11 toc bottleneck game
Bottleneck of thinking
Bruce Damer's talk on the Von Neumann Bottleneck to the Singularity Universit...
Debug C/C++ Programs More Comfortably @ 2014.12.14 Trace Code Meetup
The Knowledge Reengineering Bottleneck
Kodak Bottleneck
Pqm bottlenecks
The Considerations for Internet of Things @ 2017
Performance Bottleneck Identification
Requirements the Last Bottleneck
Functional Programming in JavaScript by Luis Atencio
Growth bottleneck
Ad

Similar to Find the bottleneck of your system (20)

PDF
PPT
Performance testing jmeter
PPTX
apache_jmeter.pptx
PDF
Performancetestingjmeter 121109061704-phpapp02
PPTX
PPTX
performancetestingjmeter-121109061704-phpapp02
PPTX
performancetestingjmeter-121109061704-phpapp02 (1)
PPTX
Perofrmance testing and apache jmeter
PDF
Introduction to Prometheus and Cortex (WOUG)
PDF
Testing - How Vital and How Easy to use
PDF
Performancetestingjmeter 131210111657-phpapp02
PDF
Integration testing - A&BP CC
PDF
Jmeter Performance Testing
PPT
JMeter & ColdFusion
PPTX
Load Impact
PPT
Performance testing and j meter
PPTX
JMeter Intro
PPTX
J Meter Intro
PPT
JMeter_introduction_Final.ppt for jmeter
PPTX
OpenTelemetry For Architects
Performance testing jmeter
apache_jmeter.pptx
Performancetestingjmeter 121109061704-phpapp02
performancetestingjmeter-121109061704-phpapp02
performancetestingjmeter-121109061704-phpapp02 (1)
Perofrmance testing and apache jmeter
Introduction to Prometheus and Cortex (WOUG)
Testing - How Vital and How Easy to use
Performancetestingjmeter 131210111657-phpapp02
Integration testing - A&BP CC
Jmeter Performance Testing
JMeter & ColdFusion
Load Impact
Performance testing and j meter
JMeter Intro
J Meter Intro
JMeter_introduction_Final.ppt for jmeter
OpenTelemetry For Architects

More from Jian-Hong Pan (13)

PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
D-Bus Usage and Debug Introduction @ COSCUP 2024
PDF
國稅局,我也好想用電腦報稅
PDF
Share the Experience of Using Embedded Development Board
PDF
Package a PyApp as a Flatpak Package: An HTTP Server for Example @ PyCon APAC...
PDF
Launch the First Process in Linux System
PDF
Let's trace Linux Lernel with KGDB @ COSCUP 2021
PDF
A Journey to Boot Linux on Raspberry Pi
PDF
Have a Simple Modbus Server
PDF
Software Packaging for Cross OS Distribution
PDF
Nasa Hackthon 2018 Light Wonder - Go! Polar Bear!
PDF
LoRaWAN class module and subsystem
PDF
Let's Have an IEEE 802.15.4 over LoRa Linux Device Driver for IoT
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
D-Bus Usage and Debug Introduction @ COSCUP 2024
國稅局,我也好想用電腦報稅
Share the Experience of Using Embedded Development Board
Package a PyApp as a Flatpak Package: An HTTP Server for Example @ PyCon APAC...
Launch the First Process in Linux System
Let's trace Linux Lernel with KGDB @ COSCUP 2021
A Journey to Boot Linux on Raspberry Pi
Have a Simple Modbus Server
Software Packaging for Cross OS Distribution
Nasa Hackthon 2018 Light Wonder - Go! Polar Bear!
LoRaWAN class module and subsystem
Let's Have an IEEE 802.15.4 over LoRa Linux Device Driver for IoT

Recently uploaded (20)

PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Encapsulation theory and applications.pdf
PPTX
1. Introduction to Computer Programming.pptx
PDF
A comparative study of natural language inference in Swahili using monolingua...
PDF
gpt5_lecture_notes_comprehensive_20250812015547.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
Tartificialntelligence_presentation.pptx
PDF
Accuracy of neural networks in brain wave diagnosis of schizophrenia
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PPTX
A Presentation on Artificial Intelligence
PDF
Getting Started with Data Integration: FME Form 101
PPTX
Group 1 Presentation -Planning and Decision Making .pptx
PDF
August Patch Tuesday
PPTX
OMC Textile Division Presentation 2021.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PPTX
Machine Learning_overview_presentation.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Assigned Numbers - 2025 - Bluetooth® Document
Diabetes mellitus diagnosis method based random forest with bat algorithm
Encapsulation theory and applications.pdf
1. Introduction to Computer Programming.pptx
A comparative study of natural language inference in Swahili using monolingua...
gpt5_lecture_notes_comprehensive_20250812015547.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
Tartificialntelligence_presentation.pptx
Accuracy of neural networks in brain wave diagnosis of schizophrenia
Per capita expenditure prediction using model stacking based on satellite ima...
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
A Presentation on Artificial Intelligence
Getting Started with Data Integration: FME Form 101
Group 1 Presentation -Planning and Decision Making .pptx
August Patch Tuesday
OMC Textile Division Presentation 2021.pptx
Unlocking AI with Model Context Protocol (MCP)
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Machine Learning_overview_presentation.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Assigned Numbers - 2025 - Bluetooth® Document

Find the bottleneck of your system

  • 1. Find the Bottleneck of Your System Load / Stress Test with JMeter StarNight
  • 2. Who am I? 潘建宏 / Jian-Hong Pan (StarNight) About Me : http://about.me/StarNight 出沒在~ GitHub : starnight PTT : zack2004 plurk : StarNight Facebook : StarNight 目前繼續在種花店當個打雜園丁 ~
  • 3. Outline ● The Bottleneck ● Web / HTTP(S) ○ Request / Response Header and Body ● Load / Stress Test ● Apache JMeter ○ Installation ○ UI Description ○ Test Plan ○ Read Result ○ Parsing and Variables
  • 4. The Bottleneck ● The operation of a system is the cooperation between many parts. ○ Nodes(Termial, Server):Clients, Server, DB ○ Connections(Communication) ● The whole system will reach the planned efficiency, only if each part meets the planned efficiency criteria. DB Server (Web AP) Clients Possible Bottleneck Possible Bottleneck Possible Bottleneck Possible Bottleneck Possible Bottleneck
  • 5. Web / HTTP(S) ● It is the protocol between Client and Web Servers ○ W3C: HTTP Specifications and Drafts ○ IETF: RFC 2616 Hypertext Transfer Protocol / 1.1 ■ 4.2 Message Headers, 4.3 Message Body ■ 5.1.1 Method ■ 6.1.1 Status Code and Reason Phrase ● HTTPS: Use SSL certificate to encrypt HTTP Server (Web AP) Clients HTTP(S) Request HTTP(S) Response
  • 6. HTTP Request Header & Body we can see Secured HTTP Request Header & Body
  • 7. Even though the HTTP is encrypted, you still see the plain text in the browser
  • 8. ● Composite of ○ Request-Line ■ Method sp Request-URI sp HTTP-Version ○ general-header | request-header | entity-header ○ message-body ● Method ○ OPTIONS, GET, HEAD, POST, PUT, DELETE, TRACE, CONNECT ● Request-URI ○ "*" | absoluteURI | abs_path | authority ● Content-Type HTTP Request (5)
  • 9. HTTP Response (6) ● Composite of ○ Status-Line ■ HTTP-Version sp Status-Code sp Reason-Phrase ○ general-header | response-header | entity-header ○ message-body ● Status Code and Reason Phrase ○ 1xx: Informational ○ 2xx: Success ○ 3xx: Redirection ○ 4xx: Client Error ○ 5xx: Server Error
  • 10. Load / Stress Test ● Load Test ○ Load testing examines the entire environment and database, while measuring the response time. ● Stress Test ○ Stress testing focuses on identified transactions, pushing to a level so as to break transactions or systems. DB Server (Web AP) Clients Super Node HTTP(S) Request HTTP(S) Response probe probe probe Flow Generator
  • 11. Apache JMeter ● Java application designed to load test functional behavior and measure performance. It was originally designed for testing Web Applications but has since expanded to other test functions. ● http://jmeter.apache.org/ ● Apache License Version 2.0 ● Getting Started (User’s Manual) Open Source is Awesome!
  • 12. Installation ● Download Page: ○ http://jmeter.apache.org/download_jmeter.cgi ● Requires Java 6 or later ● Excute bin/jmeter.sh or bin/jmeter.bat ● Using JMeter behind a proxy ○ Append the arguments “--proxyHost ProxyServer -- proxyPort ProxyPort” after the ApacheJMeter.jar command in bin/jmeter.sh or bin/jmeter.bat
  • 13. UI Description Test Plan related: Thread, Query Script, Header ... Workbench to make Test Plan How to run the Test Plan Global User Defined Variables Start / Stop Test Clear Test Result
  • 14. Test Plan - Thread Group
  • 15. Test Plan - Test Script Recorder Browser JMeter Proxy Target Client X There are only HTTP requests and Response in the World Wide Web.
  • 16. Open a browser which will go through this proxy
  • 17. Test Plan - HTTP Request
  • 18. Test Plan - HTTP Cookie Manager Cookie - Session IETF: RFC 6265 / 8.4
  • 19. Test Plan - HTTP Request Defaults Variables Default Values
  • 20. Test Plan: Many other scenarios ● How to use a CSV file with JMeter ○ Many usernames and paswwords for exmaple ● Upload and Download Scenarios with Apache JMeter ○ Upload files tests ● And so on ...
  • 21. Test Plan - View Results Tree
  • 22. Test Plan - Summary Report
  • 24. Run the Test Plan
  • 25. Read Result - View Results Tree
  • 26. Read Result - Summary Report
  • 31. Apache Ant ● 5 Ways To Launch a JMeter Test without Using the JMeter GUI ● JMeter Ant Task ● To have a test report in HTML form ● One may need to add Ant into the enviroment variable PATH
  • 32. Use JMeter Ant addon 1. Download Apache Ant and install it 2. Add Ant’s directory into PATH 3. Use the command line: a. cd Apache JMeters’s extras directory b. ant -Dtest=Test Plan’s File Name -Dtestpath=Path of the Test Plan’s File For example: I put the test.jmx on my desktop $ cd C:UsersjhpanDesktopapache-jmeter-2.13extras $ ant -Dtest=test -Dtestpath=C:UsersjhpanDesktop

Editor's Notes

  • #19: Session: IETF 6265 8.4. Session Identifiers