从http://ffbinaries.com/downloads下载ffserver到linux系统,
制作server.cfg文件如下
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | RTSPPort 5454 BindAddress 0.0.0.0 RTSPBindAddress 0.0.0.0 MaxHTTPConnections 2000 MaxClients 1000 MaxBandwidth 30000 CustomLog - NoDaemon #NoDefaults <Stream test.mp4> File "/home/sdb/work/stream/test.mp4" Format rtp </Stream> |
命令行运行
1 | ./ffserver -f server.cfg |
这样,任何地方,只要能连接到此linux系统,其IP地址为192.168.1.32,都可以播放
1 | rtsp://192.168.1.32:5454/test.mp4 |