http://blog.csdn.net/sinat_34194127/article/details/50816045

[root@localhost ~]# yum install git unzip patch gcc gcc-c++ make
[root@localhost ~]# git clone https://github.com/winlinvip/st-load.git

[root@localhost st-load]# ./configure
[root@localhost st-load]# make

[root@localhost st-load]# ls objs/
http-parser-2.1 src st_hls_load st_rtmp_load st_rtmp_publish
Makefile st-1.9 st_http_load st_rtmp_load_fast
[root@localhost st-load]#
模拟RTMP用户
./st_rtmp_load -c 1 -r rtmp://127.0.0.1:1935/live/livestream
模拟HLS直播用户
./st_hls_load -c 1 -r http://127.0.0.1:3080/hls/hls.m3u8
模拟HSL点播用户
./st_hls_load -c 10000 -o -r http://127.0.0.1:3080/hls/hls.m3u8
模拟RTMP推流用户
./st_rtmp_publish -i doc/source.200kbps.768×320.flv -c 1 -r rtmp://127.0.0.1:1935/live/livestream
模拟RTMP多路推流用户
./st_rtmp_publish -i doc/source.200kbps.768×320.flv -c 1000 -r rtmp://127.0.0.1:1935/live/livestream_{i}

支持RTMP流播放测试,一个进程支持5k并发
支持RTMP流推流测试,一个进程支持500个并发。
 
build ok, you can:
     ./objs/sb_http_load
     ./objs/sb_hls_load
     ./objs/sb_rtmp_load
     ./objs/sb_rtmp_load_fast
     ./objs/sb_rtmp_publish
 
Examples:
1. start a client
   ./objs/sb_rtmp_load_fast -c 1 -r rtmp://127.0.0.1:1935/live/livestream
2. start 1000 clients
   ./objs/sb_rtmp_load_fast -c 1000 -r rtmp://127.0.0.1:1935/live/livestream
3. start 10000 clients
   ./objs/sb_rtmp_load_fast -c 10000 -r rtmp://127.0.0.1:1935/live/livestream
4. start 100000 clients
   ./objs/sb_rtmp_load_fast -c 100000 -r rtmp://127.0.0.1:1935/live/livestream
 
实例: 
./objs/sb_rtmp_load -c 500 -r rtmp://172.17.14.88:1935/live/BHIP91_172.17.17.185_1
 
./objs/sb_hls_load -c 1 -r http://172.17.14.88:10000/hls/BHIP91_172.17.17.183_1_sd.m3u8
 
Examples:
1. start a client
   ./objs/sb_hls_load -c 1 -r http://127.0.0.1:3080/hls/hls.m3u8
2. start 1000 clients
   ./objs/sb_hls_load -c 1000 -r http://127.0.0.1:3080/hls/hls.m3u8
3. start 10000 clients
   ./objs/sb_hls_load -c 10000 -r http://127.0.0.1:3080/hls/hls.m3u8
4. start 100000 clients
   ./objs/sb_hls_load -c 100000 -r http://127.0.0.1:3080/hls/hls.m3u8
5. start 10000 vod clients
   ./objs/sb_hls_load -c 10000 -o -r http://127.0.0.1:3080/hls/hls.m3u8

流媒体压力测试rtmp&hls(含推流和拉流)的更多相关文章

  1. ffmpeg处理rtmp/文件/rtsp的推流和拉流

    ffmpeg处理rtmp/文件/rtsp的推流和拉流   本demo演示了利用ffmpeg从服务器拉流或本地文件读取流,更改流url或文件类型名称发送回服务器或存到本地的作用. 由于本程序只写了3个小 ...

  2. java封装FFmpeg命令,支持原生ffmpeg全部命令,实现FFmpeg多进程处理与多线程输出控制(开启、关闭、查询),rtsp/rtmp推流、拉流

    前言: 之前已经对FFmpeg命令进行了封装http://blog.csdn.net/eguid_1/article/details/51787646,但是当时没有考虑到扩展性,所以总体设计不是太好, ...

  3. 推流和拉流的概念以及RTMP和HLS协议

    推流为将直播内容推送至服务器的过程:拉流为服务器已有直播内容,用指定地址进行拉取的过程. rtmp rtmp是Real Time Messaging Protocol(实时消息传输协议)的首字母缩写. ...

  4. Centos7 搭建Nginx+rtmp+hls直播推流服务器

    1 准备工具 使用yum安装git [root~]# yum -y install git 下载nginx-rtmp-module,官方github地址 // 通过git clone 的方式下载到服务 ...

  5. Mac上搭建直播服务器Nginx+rtmp,实现手机推流、拉流

    转载自http://www.cnblogs.com/jys509/p/5649066.html 简介 nginx是非常优秀的开源服务器,用它来做hls或者rtmp流媒体服务器是非常不错的选择,本人在网 ...

  6. 开源流媒体服务器SRS学习笔记(1) - 安装、推流、拉流

    SRS(Simple RTMP Server)  是国人写的一款非常优秀的开源流媒体服务器软件,可用于直播/录播/视频客服等多种场景,其定位是运营级的互联网直播服务器集群. 一.安装 官网提供了3种安 ...

  7. iOS开发之利用IJKPlayer+nginx+rtmp搭建直播的推流和拉流

    最近项目中想实现直播的功能,所以研究了一段时间的直播功能,当然也是在别人的基础上不断的学习实现的,所以记录一下,希望对大家有所帮助. 直播拉流功能: 这里使用了开源的IJKPlayer第三框架,ijk ...

  8. 基于阿里云直播实现视频推流(ffmpeg)/拉流(Django2.0)以及在线视频直播播放(支持http/https)功能

    原文转载自「刘悦的技术博客」https://v3u.cn/a_id_146 由于5g网络的光速推广,视频业务又被推上了风口浪尖,在2019年初我们还在谈论照片,短视频等关键字,而进入2020年,我们津 ...

  9. 三、Windows下用FFmpeg+nginx+rtmp搭建直播环境 实现推流、拉流

    一.环境 1.开发环境:windows 2.开发工具:FFmpeg.nginx.nginx-rmtp-module (链接:https://pan.baidu.com/s/119d2GeMzddas_ ...

随机推荐

  1. mysql以zip安装,解决the service already exists

    mysql以zip安装, mysqld -install 报错:​The service already exists ​ 原因是之前安装了以后卸载了,服务没删掉. 解决方法:​ sc query m ...

  2. gedit embeded terminal 设置字体 颜色

    /usr/lib/gedit/plugins/terminal.py # -*- coding: utf8 -*- # terminal.py - Embeded VTE terminal for g ...

  3. sql 中取整,四舍五入取整,向下取整,向上取整。

    SELECT round(52.45, 0) AS round4, round(52.54, 0) AS round5, round(52.45, 1) AS round41, round(52.54 ...

  4. Ajax实战(原生)

    /** 之前一直在学习ajax,也拿jQuery写了很多,感觉还是写原生的对基础的理论理解的深刻.特此书写. * 得到ajax对象 */ function getajaxHttp() { var xm ...

  5. excel导入数据库实例(含源码 超级详细适合新手)

    (案例的源码在我的百度网盘里,需要的朋友可以加我微信分享,gqljxg1514) 所有文件一览: 运行结果图: 1,首先创建实体类Student.java package com.b510.excel ...

  6. TensorFlow 算术运算符

    TensorFlow 算术运算符 TensorFlow 提供了几种操作,您可以使用它们将基本算术运算符添加到图形中. tf.add tf.subtract tf.multiply tf.scalar_ ...

  7. tp5 base64 图片上传

    /** * 保存图片 */ public function uploads($value='') { // $file = base64_decode(request()->file('imag ...

  8. 剑指Offer 23. 二叉搜索树的后序遍历序列 (二叉搜索树)

    题目描述 输入一个整数数组,判断该数组是不是某二叉搜索树的后序遍历的结果.如果是则输出Yes,否则输出No.假设输入的数组的任意两个数字都互不相同. 题目地址 https://www.nowcoder ...

  9. 剑指Offer 28. 数组中出现次数超过一半的数字 (数组)

    题目描述 数组中有一个数字出现的次数超过数组长度的一半,请找出这个数字.例如输入一个长度为9的数组{1,2,3,2,2,2,5,4,2}.由于数字2在数组中出现了5次,超过数组长度的一半,因此输出2. ...

  10. laravel 常用命令

    1.创建控制器 php artisan make:controller ArticleController // 带 restful 风格 php artisan make:controller Ar ...