ossrs / srs

SRS is a simple, high-efficiency, real-time media server supporting RTMP, WebRTC, HLS, HTTP-FLV, HTTP-TS, SRT, MPEG-DASH, and GB28181.
https://ossrs.io
MIT License
25.86k stars 5.39k forks source link

WebRTC: OBS streaming successful, RTMP playback successful, RTC playback failed #2159

Closed JavckyGuo closed 3 years ago

JavckyGuo commented 3 years ago

Description Using OBS for streaming, playing with SRS WebRTC fails, but playing with RTMP is normal.

1. SRS Version: 4.0.62

  1. SRS log is as follows: [2021-01-20 08:06:42.672][Trace][1482][059ou12x] devices, intranet eth0 172.17.0.3 [2021-01-20 08:06:42.672][Warn][1482][059ou12x][0] stats network use index=0, ip=172.17.0.3, ifname=eth0 [2021-01-20 08:06:42.672][Warn][1482][059ou12x][0] stats disk not configed, disk iops disabled. [2021-01-20 08:06:42.672][Trace][1482][059ou12x] write log to console [2021-01-20 08:06:42.672][Trace][1482][059ou12x] features, rch:on, dash:on, hls:on, hds:off, srt:off, hc:on, ha:on, hs:on, hp:on, dvr:on, trans:on, inge:on, stat:on, sc:on [2021-01-20 08:06:42.672][Trace][1482][059ou12x] SRS on amd64 x86_64, conf:conf/rtc_live.conf, limit:1000, writev:1024, encoding:little-endian, HZ:100 [2021-01-20 08:06:42.672][Trace][1482][059ou12x] mw sleep:350ms. mr enabled:on, default:0, sleep:350ms [2021-01-20 08:06:42.672][Trace][1482][059ou12x] gc:on, pq:30000ms, cscc:[0,16), csa:on, tn:on(may hurts performance), ss:auto(guess by merged write) [2021-01-20 08:06:42.672][Trace][1482][059ou12x] system default latency(ms): mw(0-350) + mr(0-350) + play-queue(0-30000)[2021-01-20 08:06:42.672][Warn][1482][059ou12x][0] SRS/4.0.62 is not stable [2021-01-20 08:06:42.679][Trace][1482][059ou12x] st_init success, use epoll [2021-01-20 08:06:42.732][Trace][1482][059ou12x] fingerprint=2D:2B:13:B0:89:63:36:00:4B:0E:13:1A:BB:2C:6C:48:61:2E:84:5D:CE:73:7A:18:34:CF:8A:30:F3:FC:2E:B7 [2021-01-20 08:06:42.732][Trace][1482][059ou12x] RTC server init ok [2021-01-20 08:06:42.732][Trace][1482][059ou12x] rtc listen at udp://0.0.0.0:8000, fd=4 [2021-01-20 08:06:42.732][Trace][1482][059ou12x] http flv live stream, vhost=defaultVhost, mount=[vhost]/[app]/[stream].flv [2021-01-20 08:06:42.732][Trace][1482][059ou12x] http: root mount to ./objs/nginx/html [2021-01-20 08:06:42.732][Trace][1482][059ou12x] server main cid=059ou12x, pid=1482, ppid=24, asprocess=0 [2021-01-20 08:06:42.735][Trace][1482][059ou12x] write pid=1482 to ./objs/srs.pid success! [2021-01-20 08:06:42.735][Trace][1482][059ou12x] RTMP listen at tcp://0.0.0.0:1935, fd=8 [2021-01-20 08:06:42.735][Trace][1482][059ou12x] HTTP-API listen at tcp://0.0.0.0:1985, fd=9 [2021-01-20 08:06:42.735][Trace][1482][059ou12x] HTTP-Server listen at tcp://0.0.0.0:8080, fd=10 [2021-01-20 08:06:42.735][Trace][1482][059ou12x] signal installed, reload=1, reopen=10, fast_quit=15, grace_quit=3 [2021-01-20 08:06:42.735][Trace][1482][059ou12x] http: api mount /console to ./objs/nginx/html/console [2021-01-20 08:06:42.735][Warn][1482][059ou12x][22] enable auto reload for docker [2021-01-20 08:06:42.736][Trace][1482][059ou12x] auto reload watching fd=11, watch=1, file=conf [2021-01-20 08:06:42.736][Trace][1482][182khb61] UDP #4 LISTEN at 0.0.0.0:8000, SO_SNDBUF(default=212992, expect=10485760, actual=425984, r0=0), SO_RCVBUF(default=212992, expect=10485760, actual=425984, r0=0) [2021-01-20 08:06:42.736][Trace][1482][9kr1d1d5] RTC: connection manager run, conns=0 [2021-01-20 08:06:42.736][Trace][1482][7w144mk1] TCP: connection manager run, conns=0 [2021-01-20 08:06:59.750][Trace][1482][s8913817] RTMP client ip=172.17.0.1:53014, fd=12 [2021-01-20 08:06:59.754][Trace][1482][s8913817] simple handshake success. [2021-01-20 08:06:59.754][Trace][1482][s8913817] connect app, tcUrl=rtmp://1.1.100.243/live, pageUrl=, swfUrl=rtmp://1.1.100.243/live, schema=rtmp, vhost=1.1.100.243, port=1935, app=live, args=null [2021-01-20 08:06:59.754][Trace][1482][s8913817] protocol in.buffer=0, in.ack=0, out.ack=0, in.chunk=4096, out.chunk=128[2021-01-20 08:06:59.806][Trace][1482][s8913817] client identified, type=fmle-publish, vhost=1.1.100.243, app=live, stream=1001, param=, duration=0ms [2021-01-20 08:06:59.806][Trace][1482][s8913817] connected stream, tcUrl=rtmp://1.1.100.243/live, pageUrl=, swfUrl=rtmp://1.1.100.243/live, schema=rtmp, vhost=defaultVhost, port=1935, app=live, stream=1001, param=, args=null [2021-01-20 08:06:59.806][Trace][1482][s8913817] new source, stream_url=/live/1001 [2021-01-20 08:06:59.806][Trace][1482][s8913817] new source, stream_url=/live/1001 [2021-01-20 08:06:59.806][Trace][1482][s8913817] source url=/live/1001, ip=172.17.0.1, cache=0, is_edge=0, source_id=/ [2021-01-20 08:06:59.856][Trace][1482][s8913817] ignore disabled exec for vhost=defaultVhost [2021-01-20 08:06:59.856][Trace][1482][s8913817] http: mount flv stream for sid=/live/1001, mount=/live/1001.flv [2021-01-20 08:06:59.885][Trace][1482][s8913817] RTC bridge from RTMP, discard_aac=0, discard_bframe=1, merge_nalus=0 [2021-01-20 08:06:59.885][Trace][1482][s8913817] set fd=12 TCP_NODELAY 0=>1 [2021-01-20 08:06:59.885][Trace][1482][s8913817] start publish mr=0/350, p1stpt=20000, pnt=5000, tcp_nodelay=1 [2021-01-20 08:06:59.906][Trace][1482][s8913817] got metadata, width=1280, height=720, vcodec=7, acodec=10 [2021-01-20 08:07:00.210][Trace][1482][s8913817] 7B audio sh, codec(10, profile=LC, 2channels, 0kbps, 48000HZ), flv(16bits, 2channels, 44100HZ) [2021-01-20 08:07:00.210][Trace][1482][s8913817] 60B video sh, codec(7, profile=High, level=3.1, 1280x720, 0kbps, 0.0fps, 0.0s) [2021-01-20 08:07:07.346][Trace][1482][s8913817] cleanup when unpublish [2021-01-20 08:07:07.346][Trace][1482][s8913817] cleanup when unpublish, created=1, deliver=1 [libopus @ 0x1fd7de0] 1 frames left in the queue on closing [2021-01-20 08:07:07.347][Trace][1482][s8913817] TCP: before dispose resource(RtmpConn)(0x1f6a3b0), con , zombies=0, ign=0, inz=0, ind=0 [2021-01-20 08:07:07.347][Warn][1482][s8913817][104] client disconnect peer. ret=1007 [2021-01-20 08:07:07.347][Trace][1482][7w144mk1] TCP: clear zombies=1 resources, conns=1, removing=0, unsubs=0 [2021-01-20 08:07:07.347][Trace][1482][s8913817] TCP: disposing #0 resource(RtmpConn)(0x1f6a3b0), conns=1, disposing=1, zombies=0 [2021-01-20 08:07:12.361][Trace][1482][w25g1357] RTMP client ip=172.17.0.1:53018, fd=12 [2021-01-20 08:07:12.364][Trace][1482][w25g1357] simple handshake success. [2021-01-20 08:07:12.364][Trace][1482][w25g1357] connect app, tcUrl=rtmp://1.1.100.243/live, pageUrl=, swfUrl=rtmp://1.1.100.243/live, schema=rtmp, vhost=1.1.100.243, port=1935, app=live, args=null [2021-01-20 08:07:12.364][Trace][1482][w25g1357] protocol in.buffer=0, in.ack=0, out.ack=0, in.chunk=4096, out.chunk=128[2021-01-20 08:07:12.416][Trace][1482][w25g1357] client identified, type=fmle-publish, vhost=1.1.100.243, app=live, stream=1001, param=, duration=0ms [2021-01-20 08:07:12.416][Trace][1482][w25g1357] connected stream, tcUrl=rtmp://1.1.100.243/live, pageUrl=, swfUrl=rtmp://1.1.100.243/live, schema=rtmp, vhost=defaultVhost, port=1935, app=live, stream=1001, param=, args=null [2021-01-20 08:07:12.416][Trace][1482][w25g1357] source url=/live/1001, ip=172.17.0.1, cache=0, is_edge=0, source_id=/s8913817 [2021-01-20 08:07:12.465][Trace][1482][w25g1357] ignore disabled exec for vhost=defaultVhost [2021-01-20 08:07:12.466][Trace][1482][w25g1357] RTC bridge from RTMP, discard_aac=0, discard_bframe=1, merge_nalus=0 [2021-01-20 08:07:12.466][Trace][1482][w25g1357] set fd=12 TCP_NODELAY 0=>1 [2021-01-20 08:07:12.466][Trace][1482][w25g1357] start publish mr=0/350, p1stpt=20000, pnt=5000, tcp_nodelay=1 [2021-01-20 08:07:12.469][Trace][1482][w25g1357] got metadata, width=1280, height=720, vcodec=7, acodec=10 [2021-01-20 08:07:12.757][Trace][1482][w25g1357] 7B audio sh, codec(10, profile=LC, 2channels, 0kbps, 48000HZ), flv(16bits, 2channels, 44100HZ) [2021-01-20 08:07:12.757][Trace][1482][w25g1357] 60B video sh, codec(7, profile=High, level=3.1, 1280x720, 0kbps, 0.0fps, 0.0s) [2021-01-20 08:07:37.466][Trace][1482][w25g1357] <- CPB time=20001677, okbps=1,0,0, ikbps=2427,0,0, mr=0/350, p1stpt=20000, pnt=5000 [2021-01-20 08:07:42.636][Trace][1482][994u3b2f] HTTP #0 172.17.0.1:58308 OPTIONS http://1.1.100.243:1985/rtc/v1/play/, content-length=-1 [2021-01-20 08:07:42.639][Trace][1482][994u3b2f] HTTP #1 172.17.0.1:58308 POST http://1.1.100.243:1985/rtc/v1/play/, content-length=5305 [2021-01-20 08:07:42.639][Trace][1482][994u3b2f] RTC play webrtc://1.1.100.243/live/1001, api=http://1.1.100.243:1985/rtc/v1/play/, clientip=, app=live, stream=1001, offer=4885B, eip=, srtp=, dtls= [2021-01-20 08:07:42.640][Trace][1482][994u3b2f] RTC player nack=1 [2021-01-20 08:07:42.640][Trace][1482][994u3b2f] RTC connection player gcc=0 [2021-01-20 08:07:42.640][Trace][1482][994u3b2f] RTC: Init tracks {track: video-264742e9, is_active: 0=>1},{track: audio-y4a5o219, is_active: 0=>1}, ok [2021-01-20 08:07:42.640][Trace][1482][994u3b2f] Best matched ip=172.17.0.3, ifname=eth0 [2021-01-20 08:07:42.640][Trace][1482][994u3b2f] RTC: Use candidates 172.17.0.3 [2021-01-20 08:07:42.640][Warn][1482][994u3b2f][11][DTLS_HANG] DTLS: Hang, done=0, version=-1, arq=0 [2021-01-20 08:07:42.645][Trace][1482][994u3b2f] RTC init session, user=y154r036:egJ0, url=/live/1001, encrypt=1/1, DTLS(role=passive, version=auto), timeout=30000ms [2021-01-20 08:07:42.645][Trace][1482][994u3b2f] RTC username=y154r036:egJ0, dtls=1, srtp=1, offer=4885B, answer=1242B [2021-01-20 08:07:42.645][Trace][1482][994u3b2f] RTC remote offer: v=0\r\no=- 4512342802439534562 2 IN IP4 127.0.0.1\r\ns=-\r\nt=0 0\r\na=group:BUNDLE 0 1\r\na=msid-semantic: WMS\r\nm=audio 9 UDP/TLS/RTP/SAVPF 111 103 104 9 0 8 106 105 13 110 112 113 126\r\nc=IN IP4 0.0.0.0\r\na=rtcp:9 IN IP4 0.0.0.0\r\na=ice-ufrag:egJ0\r\na=ice-pwd:MQlohkomdy0s69pb454qT+/1\r\na=ice-options:trickle\r\na=fingerprint:sha-256 FF:7A:BE:4A:52:E0:FF:56:DF:18:ED:B2:E3:CF:FF:30:60:45:E3:70:91:95:02:CC:2E:23:C3:E9:E9:FD:83:6C\r\na=setup:actpass\r\na=mid:0\r\na=extmap:1 urn:ietf:params:rtp-hdrext:ssrc-audio-level\r\na=extmap:2 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time\r\na=extmap:3 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01\r\na=extmap:4 urn:ietf:params:rtp-hdrext:sdes:mid\r\na=extmap:5 urn:ietf:params:rtp-hdrext:sdes:rtp-stream-id\r\na=extmap:6 urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id\r\na=recvonly\r\na=rtcp-mux\r\na=rtpmap:111 opus/48000/2\r\na=rtcp-fb:111 transport-cc\r\na=fmtp:111 minptime=10;useinbandfec=1\r\na=rtpmap:103 ISAC/16000\r\na=rtpmap:104 ISAC/32000\r\na=rtpmap:9 G722/8000\r\na=rtpmap:0 PCMU/8000\r\na=rtpmap:8 PCMA/8000\r\na=rtpmap:106 CN/32000\r\na=rtpmap:105 CN/16000\r\na=rtpmap:13 CN/8000\r\na=rtpmap:110 telephone-event/48000\r\na=rtpmap:112 telephone-event/32000\r\na=rtpmap:113 telephone-event/16000\r\na=rtpmap:126 telephone-event/8000\r\nm=video 9 UDP/TLS/RTP/SAVPF 96 97 98 99 100 101 122 102 121 127 120 125 107 108 109 124 119 123 118 114 115 116\r\nc=IN IP4 0.0.0.0\r\na=rtcp:9 IN IP4 0.0.0.0\r\na=ice-ufrag:egJ0\r\na=ice-pwd:MQlohkomdy0s69pb454qT+/1\r\na=ice-options:trickle\r\na=fingerprint:sha-256 FF:7A:BE:4A:52:E0:FF:56:DF:18:ED:B2:E3:CF:FF:30:60:45:E3:70:91:95:02:CC:2E:23:C3:E9:E9:FD:83:6C\r\na=setup:actpass\r\na=mid:1\r\na=extmap:14 urn:ietf:params:rtp-hdrext:toffset\r\na=extmap:2 http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time\r\na=extmap:13 urn:3gpp:video-orientation\r\na=extmap:3 http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01\r\na=extmap:12 http://www.webrtc.org/experiments/rtp-hdrext/playout-delay\r\na=extmap:11 http://www.webrtc.org/experiments/rtp-hdrext/video-content-type\r\na=extmap:7 http://www.webrtc.org/experiments/rtp-hdrext/video-timing\r\na=extmap:8 http://www.webrtc.org/experiments/rtp-hdrext/color-space\r\na=extmap:4 urn:ietf:params:rtp-hdrext:sdes:mid\r\na=extmap:5 urn:ietf:params:rtp-hdrext:sdes:rtp-stream-id\r\na=extmap:6 urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id\r\na=recvonly\r\na=rtcp-mux\r\na=rtcp-rsize\r\na=rtpmap:96 VP8/90000\r\na=rtcp-fb:96 goog-remb\r\na=rtcp-fb:96 transport-cc\r\na=rtcp-fb:96 ccm fir\r\na=rtcp-fb:96 nack\r\na=rtcp-fb:96 nack pli\r\na=rtpmap:97 rtx/90000\r\na=fmtp:97 apt=96\r\na=rtpmap:98 VP9/90000\r\na=rtcp-fb:98 goog-remb\r\na=rtcp-fb:98 transport-cc\r\na=rtcp-fb:98 ccm fir\r\na=rtcp-fb:98 nack\r\na=rtcp-fb:98 nack pli\r\na=fmtp:98 profile-id=0\r\na=rtpmap:99 rtx/90000\r\na=fmtp:99 apt=98\r\na=rtpmap:100 VP9/90000\r\na=rtcp-fb:100 goog-remb\r\na=rtcp-fb:100 transport-cc\r\na=rtcp-fb:100 ccm fir\r\na=rtcp-fb:100 nack\r\na=rtcp-fb:100 nack pli\r\na=fmtp:100 profile-id=2\r\na=rtpmap:101 rtx/90000\r\na=fmtp:101 apt=100\r\na=rtpmap:122 VP9/90000\r\na=rtcp-fb:122 goog-remb\r\na=rtcp-fb:122 transport-cc\r\na=rtcp-fb:122 ccm fir\r\na=rtcp-fb:122 nack\r\na=rtcp-fb:122 nack pli\r\na=fmtp:122 profile-id=1\r\na=rtpmap:102 H264/90000\r\na=rtcp-fb:102 goog-remb\r\na=rtcp-fb:102 transport-cc\r\na=rtcp-fb:102 ccm fir\r\na=rtcp-fb:102 nack\r\na=rtcp-fb:102 nack pli\r\na=fmtp:102 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42001f\r\na=rtpmap:121 rtx/90000\r\na=fmtp:121 apt=102\r\na=rtpmap:127 H264/90000\r\na=rtcp-fb:127 goog-remb\r\na=rtcp-fb:127 transport-cc\r\na=rtcp-fb:127 ccm fir\r\na=rtcp-fb:127 nack\r\na=rtcp-fb:127 nack pli\r\na=fmtp:127 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=42001f\r\na=rtpmap:120 rtx/90000\r\na=fmtp:120 apt=127\r\na=rtpmap:125 H264/90000\r\na=rtcp-fb:125 goog-remb\r\na=rtcp-fb:125 transport-cc\r\na=rtcp-fb:125 ccm fir\r\na=rtcp-fb:125 nack\r\na=rtcp-fb:125 nack pli\r\na=fmtp:125 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f\r\na=rtpmap:107 rtx/90000\r\na=fmtp:107 apt=125\r\na=rtpmap:108 H264/90000\r\na=rtcp-fb:108 goog-remb\r\na=rtcp-fb:108 transport-cc\r\na=rtcp-fb:108 ccm fir\r\na=rtcp-fb:108 nack\r\na=rtcp-fb:108 nack pli\r\na=fmtp:108 level-asymmetry-allowed=1;packetization-mode=0;profile-level-id=42e01f\r\na=rtpmap:109 rtx/90000\r\na=fmtp:109 apt=108\r\na=rtpmap:124 H264/90000\r\na=rtcp-fb:124 goog-remb\r\na=rtcp-fb:124 transport-cc\r\na=rtcp-fb:124 ccm fir\r\na=rtcp-fb:124 nack\r\na=rtcp-fb:124 nack pli\r\na=fmtp:124 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=4d001f\r\na=rtpmap:119 rtx/90000\r\na=fmtp:119 apt=124\r\na=rtpmap:123 H264/90000\r\na=rtcp-fb:123 goog-remb\r\na=rtcp-fb:123 transport-cc\r\na=rtcp-fb:123 ccm fir\r\na=rtcp-fb:123 nack\r\na=rtcp-fb:123 nack pli\r\na=fmtp:123 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=64001f\r\na=rtpmap:118 rtx/90000\r\na=fmtp:118 apt=123\r\na=rtpmap:114 red/90000\r\na=rtpmap:115 rtx/90000\r\na=fmtp:115 apt=114\r\na=rtpmap:116 ulpfec/90000\r\n [2021-01-20 08:07:42.645][Trace][1482][994u3b2f] RTC local answer: v=0\r\no=SRS/4.0.62(Leo) 34595280 2 IN IP4 0.0.0.0\r\ns=SRSPlaySession\r\nt=0 0\r\na=ice-lite\r\na=group:BUNDLE 0 1\r\na=msid-semantic: WMS live/1001\r\nm=audio 9 UDP/TLS/RTP/SAVPF 111\r\nc=IN IP4 0.0.0.0\r\na=ice-ufrag:y154r036\r\na=ice-pwd:2n5q005ff09y52d4uj3y80734h71205y\r\na=fingerprint:sha-256 2D:2B:13:B0:89:63:36:00:4B:0E:13:1A:BB:2C:6C:48:61:2E:84:5D:CE:73:7A:18:34:CF:8A:30:F3:FC:2E:B7\r\na=setup:passive\r\na=mid:0\r\na=sendonly\r\na=rtcp-mux\r\na=rtcp-rsize\r\na=rtpmap:111 opus/48000/2\r\na=ssrc:14969687 cname:92p24532z4446l38\r\na=ssrc:14969687 label:audio-y4a5o219\r\na=candidate:0 1 udp 2130706431 172.17.0.3 8000 typ host generation 0\r\nm=video 9 UDP/TLS/RTP/SAVPF 125\r\nc=IN IP4 0.0.0.0\r\na=ice-ufrag:y154r036\r\na=ice-pwd:2n5q005ff09y52d4uj3y80734h71205y\r\na=fingerprint:sha-256 2D:2B:13:B0:89:63:36:00:4B:0E:13:1A:BB:2C:6C:48:61:2E:84:5D:CE:73:7A:18:34:CF:8A:30:F3:FC:2E:B7\r\na=setup:passive\r\na=mid:1\r\na=sendonly\r\na=rtcp-mux\r\na=rtcp-rsize\r\na=rtpmap:125 H264/90000\r\na=fmtp:125 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f\r\na=ssrc:14969688 cname:92p24532z4446l38\r\na=ssrc:14969688 label:video-264742e9\r\na=candidate:0 1 udp 2130706431 172.17.0.3 8000 typ host generation 0\r\n [2021-01-20 08:07:42.707][Trace][1482][994u3b2f] TCP: before dispose resource(HttpConn)(0x1f73db0), conns=2, zombies=0, ign=0, inz=0, ind=0 [2021-01-20 08:07:42.707][Warn][1482][994u3b2f][104] client disconnect peer. ret=1007 [2021-01-20 08:07:42.707][Trace][1482][7w144mk1] TCP: clear zombies=1 resources, conns=2, removing=0, unsubs=0 [2021-01-20 08:07:42.707][Trace][1482][994u3b2f] TCP: disposing #0 resource(HttpConn)(0x1f73db0), conns=2, disposing=1, zombies=0 [2021-01-20 08:07:42.779][Trace][1482][059ou12x] RTC: Server conns=1, cpu=2.33%, rss=10MB [2021-01-20 08:07:47.466][Trace][1482][w25g1357] <- CPB time=30002641, okbps=0,1,0, ikbps=2455,2391,0, mr=0/350, p1stpt=20000, pnt=5000 [2021-01-20 08:07:47.780][Trace][1482][059ou12x] RTC: Server conns=1, cpu=1.67%, rss=10MB [2021-01-20 08:07:52.780][Trace][1482][059ou12x] RTC: Server conns=1, cpu=2.00%, rss=10MB [2021-01-20 08:07:57.466][Trace][1482][w25g1357] <- CPB time=40003422, okbps=0,1,0, ikbps=2464,2391,0, mr=0/350, p1stpt=20000, pnt=5000 [2021-01-20 08:07:57.781][Trace][1482][059ou12x] RTC: Server conns=1, cpu=2.00%, rss=10MB

1. SRS Configuration: Using the default rtc_live.conf configuration.

Replay

How to replay bug?

Steps to reproduce the bug

  1. xxxxxx
  2. xxxxxx
  3. xxxxxx

Expect

Able to play using WebRTC normally

TRANS_BY_GPT3

winlinvip commented 3 years ago

To be reproduced.

TRANS_BY_GPT3

x-batman commented 3 years ago

It may be caused by NAT network. I also encountered the same issue here. tcpdump captured packets and found that the WebRTC player was trying to connect to the server's internal IP.

TRANS_BY_GPT3

x-batman commented 3 years ago

rtc_server { enabled on; listen 8000; candidate $CANDIDATE; # Under NAT network, replace this $CANDIDATE with your external IP }

TRANS_BY_GPT3

winlinvip commented 3 years ago

@x-batman 👍

startjava commented 3 years ago

@JavckyGuo Has the problem been resolved? I am also facing the same issue. I downloaded version 4 today, and the rtmp in nat works fine, but rtc doesn't work. I also configured the candidate, but it didn't work. @winlinvip

TRANS_BY_GPT3