St-load: Streaming Load Testing Tool – Installation, Configuration, and Usage Guide
This guide introduces St-load, a Linux‑based streaming load testing tool, and provides step‑by‑step instructions for installing, compiling, and using its RTMP, HTTP, and HLS testing features, including command‑line examples and parameter explanations for both push and pull scenarios.
To facilitate pressure testing of streaming media services, we recommend the St-load tool, which supports RTMP push testing (up to 500 concurrent streams per process), RTMP pull testing (up to 5,000 concurrent streams per process), HTTP load testing (repeated downloads of a single file), and HLS parsing and testing (both VOD and live).
Installation
1. Download the St-load source package on a Linux environment: git clone https://github.com/rzrobert/st-load-master.git 2. Compile the source code:
cd st-load-master/ ./configure makeAfter compilation, executable files are generated in the objs directory.
Push Stream Section
1. Prepare the RTMP layer in nginx.conf before pushing streams.
2. Simulate a single‑channel RTMP push:
./sb_rtmp_publish -i /usr/local/ffmpeg/cnlzd.flv -c 1 -r rtmp://127.0.0.1/live/livestream3. Simulate multi‑channel RTMP push (e.g., 10 concurrent streams):
./sb_rtmp_publish -i /usr/local/ffmpeg/cnlzd.flv -c 10 -r rtmp://127.0.0.1/live/livestream_{i}Common parameters:
-i : input stream
-c : number of concurrent instances (default 1)
-r : target URL (equivalent to --url URL)
-s : thread start delay, default 5.00 seconds; 0 means no delay
Note: sb_rtmp_publish only supports .flv video format.
Pull Stream Section
1. RTMP Pull
RTMP (Real Time Messaging Protocol) is used for real‑time audio/video communication between Flash/AIR platforms and streaming servers.
Pull command: ./sb_rtmp_load -c 1 -r rtmp://127.0.0.1:1935/live/livestream 2. HTTP Pull
HTTP is an application‑layer protocol suitable for distributed multimedia systems; it also carries video on demand in HTML5.
Pull command: ./sb_http_load -c 1 -r http://127.0.0.1:8081/live/livestream 3. HLS Pull
HLS (HTTP Live Streaming) is Apple’s adaptive bitrate streaming technology, using an .m3u8 index file and TS media segments.
Segment strategy: typically 10‑second segments, with a sliding window of the latest three segments.
Example .m3u8 file header:
#EXTM3U
#EXT-X-MEDIA-SEQUENCE:7
#EXT-X-TARGETDURATION:15
#EXTINF:15.099Pull command:
./sb_hls_load -c 1 -r http://127.0.0.1:8081/hls/livestream/index.m3u8Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
360 Quality & Efficiency
360 Quality & Efficiency focuses on seamlessly integrating quality and efficiency in R&D, sharing 360’s internal best practices with industry peers to foster collaboration among Chinese enterprises and drive greater efficiency value.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
