antimof / UxPlay

AirPlay Unix mirroring server
GNU General Public License v3.0
1.4k stars 190 forks source link

GStreamer error: Failed to upload buffer #161

Open imbennie opened 6 months ago

imbennie commented 6 months ago

Enviroment:

The uxPlay mirror server can be seen normally on the iPad. But every time the connection starts, it will be interrupted immediately. (ipad will display button "Stop Mirroring" and then disconnect immediately)

Is there any information I need to know to solve this problem?

Running log:

ubuntu# uxplay   
using system MAC address 54:e1:ad:4c:66:ee
Initialized server socket(s)
Accepted IPv4 client on socket 34
Local: 192.168.101.4
Remote: 192.168.101.50
Open connections: 1
Client identified as User-Agent: AirPlay/675.4.1
Accepted IPv4 client on socket 36
Local: 192.168.101.4
Remote: 192.168.101.50
Open connections: 2
raop_rtp_mirror starting mirroring
**GStreamer error: Failed to upload buffer**
Re-launching server...
Removing connection for socket 34
Destroying connection
Open connections: 1
Removing connection for socket 36
Destroying connection
Open connections: 0
Initialized server socket(s)
debug logs detail ubuntu# uxplay -d supported audio format 1: AAC-ELD 44100/2 supported audio format 2: ALAC 44100/16/2 supported audio format 3: AAC-LC 44100/2 supported audio format 4: PCM 44100/16/2 S16LE Initialized GStreamer video renderer using system MAC address 54:e1:ad:4c:66:ee Initialized server socket(s) Accepted IPv4 client on socket 34 Local: 192.168.101.4 Remote: 192.168.101.50 Open connections: 1 httpd receiving on socket 34 conn_request GET /info RTSP/1.0 X-Apple-ProtocolVersion: 1 Content-Length: 70 Content-Type: application/x-apple-binary-plist CSeq: 0 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 qualifier txtAirPlay Handling request GET with URL /info RTSP/1.0 200 OK CSeq: 0 Server: AirTunes/220.68 Content-Type: application/x-apple-binary-plist Content-Length: 1064 txtAirPlay GmRldmljZWlkPTU0OmUxOmFkOjRjOjY2OmVlE2ZlYXR1cmVzPTB4NUE3RkZFRTYJZmxh Z3M9MHg0EG1vZGVsPUFwcGxlVFYzLDJDcGs9YjA3NzI3ZDZmNmNkNmUwOGI1OGVkZTUy NWVjM2NkZWFhMjUyYWQ5ZjY4M2ZlYjIxMmVmOGEyMDUyNDY1NTRlNydwaT0yZTM4ODAw Ni0xM2JhLTQwNDEtOWE2Ny0yNWRkNGE0M2Q1MzYOc3JjdmVycz0yMjAuNjgEdnY9Mg== features 130367356919 name UxPlay@ubuntu audioFormats type 100 audioInputFormats 67108860 audioOutputFormats 67108860 type 101 audioInputFormats 67108860 audioOutputFormats 67108860 pi 2e388006-13ba-4041-9a67-25dd4a43d536 vv 2 statusFlags 68 keepAliveLowPower 1 sourceVersion 220.68 pk sHcn1vbNbgi1jt5SXsPN6qJSrZ9oP+shLviiBSRlVOc= keepAliveSendStatsAsBody 1 deviceID 54:e1:ad:4c:66:ee audioLatencies outputLatencyMicros type 100 audioType default inputLatencyMicros outputLatencyMicros type 101 audioType default inputLatencyMicros model AppleTV3,2 macAddress 54:e1:ad:4c:66:ee displays uuid e0ff8a27-6738-3d56-8a16-cc53aacee925 widthPhysical heightPhysical width 1920 height 1080 widthPixels 1920 heightPixels 1080 rotation refreshRate 60 maxFPS 30 overscanned features 14 httpd receiving on socket 34 conn_request POST /pair-setup RTSP/1.0 Content-Length: 32 Content-Type: application/octet-stream CSeq: 1 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 a1 f4 cc c0 c3 c8 ef 06 8e fd 76 7b aa a5 79 cf 7b 4a de 5e 12 85 dc 57 55 c4 ce 0b e3 19 41 67 Handling request POST with URL /pair-setup RTSP/1.0 200 OK CSeq: 1 Server: AirTunes/220.68 Content-Type: application/octet-stream Content-Length: 32 95 37 a1 56 05 6d 38 5a 66 44 4e 0a 24 26 b4 4b f3 4b b7 7d 76 8e 06 85 d4 60 8b 9d 2d 35 4d 1f httpd receiving on socket 34 conn_request POST /pair-verify RTSP/1.0 X-Apple-PD: 1 X-Apple-AbsoluteTime: 732812709 Content-Length: 68 Content-Type: application/octet-stream CSeq: 2 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 01 00 00 00 19 37 e7 16 39 c0 87 9b da 4c a4 ff 0e 73 8e 6c b0 1c 59 bf f5 04 39 85 9f 0c 48 ed 30 10 ff 2a a1 f4 cc c0 c3 c8 ef 06 8e fd 76 7b aa a5 79 cf 7b 4a de 5e 12 85 dc 57 55 c4 ce 0b e3 19 41 67 Handling request POST with URL /pair-verify RTSP/1.0 200 OK CSeq: 2 Server: AirTunes/220.68 Content-Type: application/octet-stream Content-Length: 96 01 0a 1e ff 1d 66 f5 ab bf 6b e7 59 96 66 7e 56 59 f5 28 38 aa c8 a2 63 c8 f7 61 05 54 ce 9e 54 1a c5 4b fc 47 81 31 22 7a 5a 1f fc b5 7b d3 5b b1 50 cf 60 e2 ed 83 9b a6 f8 97 00 e0 a3 c1 46 3a 2d b5 20 f8 9c 39 c2 39 e3 62 31 15 8b 3d 01 34 90 62 d1 50 06 a5 ac f0 ef 65 6a 1b 4d 45 3c httpd receiving on socket 34 conn_request POST /pair-verify RTSP/1.0 X-Apple-PD: 1 X-Apple-AbsoluteTime: 732812709 Content-Length: 68 Content-Type: application/octet-stream CSeq: 3 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 00 00 00 00 6d ca 56 82 5e 56 ba 29 ce 9b 22 3d d9 df 3c 79 5d 49 cf bc 55 e1 63 d6 bd 09 4a 38 a5 47 1d a8 0b 10 61 d5 54 58 84 51 84 45 a6 44 c5 07 da 65 ec 8d a0 c8 a4 94 f7 85 54 30 3e 20 12 c5 03 9d Handling request POST with URL /pair-verify 2nd pair-verify step: checking signature pair-verify: signature is verified RTSP/1.0 200 OK CSeq: 3 Server: AirTunes/220.68 Content-Type: application/octet-stream httpd receiving on socket 34 conn_request POST /fp-setup RTSP/1.0 X-Apple-ET: 32 Content-Length: 16 Content-Type: application/octet-stream CSeq: 4 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 46 50 4c 59 03 01 01 00 00 00 00 04 02 00 01 bb Handling request POST with URL /fp-setup RTSP/1.0 200 OK CSeq: 4 Server: AirTunes/220.68 Content-Type: application/octet-stream Content-Length: 142 46 50 4c 59 03 01 02 00 00 00 00 82 02 01 cf 32 a2 57 14 b2 52 4f 8a a0 ad 7a f1 64 e3 7b cf 44 24 e2 00 04 7e fc 0a d6 7a fc d9 5d ed 1c 27 30 bb 59 1b 96 2e d6 3a 9c 4d ed 88 ba 8f c7 8d e6 4d 91 cc fd 5c 7b 56 da 88 e3 1f 5c ce af c7 43 19 95 a0 16 65 a5 4e 19 39 d2 5b 94 db 64 b9 e4 5d 8d 06 3e 1e 6a f0 7e 96 56 16 2b 0e fa 40 42 75 ea 5a 44 d9 59 1c 72 56 b9 fb e6 51 38 98 b8 02 27 72 19 88 57 16 50 94 2a d9 46 68 8a httpd receiving on socket 34 conn_request POST /fp-setup RTSP/1.0 X-Apple-ET: 32 Content-Length: 164 Content-Type: application/octet-stream CSeq: 5 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 46 50 4c 59 03 01 03 00 00 00 00 98 01 8f 1a 9c 43 49 45 ca 63 24 ae 18 56 d5 41 7f 19 1b 8a 7c c2 b1 6a 66 2d 3c 8d 36 14 38 53 d8 93 32 25 a2 74 c6 ff bc 0d dd 22 01 95 05 97 20 06 d5 4c 68 5a 41 f6 e6 e1 7b 6f b8 dd c7 58 90 ae e4 8c aa 07 ce 61 07 26 ed 09 11 45 54 ed c7 38 c4 4e 48 24 af f7 9f bc 33 9a 20 c5 d7 af 64 97 04 b3 58 d7 28 18 e5 8c 8e 29 80 39 23 a0 8e 74 3f e0 ac 4e 6e 7c ac 92 27 b9 12 86 b5 76 aa 06 08 83 f7 9f a7 94 e6 e2 86 bc af c6 21 09 48 44 31 51 a4 ef 59 63 73 Handling request POST with URL /fp-setup RTSP/1.0 200 OK CSeq: 5 Server: AirTunes/220.68 Content-Type: application/octet-stream Content-Length: 32 46 50 4c 59 03 01 04 00 00 00 00 14 9f a7 94 e6 e2 86 bc af c6 21 09 48 44 31 51 a4 ef 59 63 73 httpd receiving on socket 34 conn_request SETUP rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 Content-Length: 707 Content-Type: application/x-apple-binary-plist CSeq: 6 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 et 32 statsCollectionEnabled eiv TdLEp77pWf3AlartqghCFw== sessionUUID CFEB994F-64C6-44B1-80DB-F73B72B3AE09 timingProtocol NTP diagnosticsAndUsage osName iPhone OS osBuildVersion 20D67 sourceVersion 675.4.1 timingPort 49806 isScreenMirroringSession osVersion 16.3.1 ekey RlBMWQECAQAAAAA8AAAAAHB9wCFFGnC9ZAV9NCJCvpEAAAAQYc2rTTCdJP1r9lOL0+G/ atmiUajWnkJnKzsqQYP3jKja7PqT sessionCorrelationUUID B72277EB-6EDF-4F7D-98B2-AEBAF34F5A23 internalBuild deviceID 34:A8:EB:6D:E5:EB model iPad11,1 name Bennie‘s iPad mini 5 macAddress 6A:D5:68:06:F6:53 Handling request SETUP with URL rtsp://192.168.101.4/14982237151650268337 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 Transport: null SETUP 1 eiv_len = 16 16 byte aesiv (needed for AES-CBC audio decryption iv): 4d d2 c4 a7 be e9 59 fd c0 95 aa ed aa 08 42 17 ekey_len = 72 ekey: 46 50 4c 59 01 02 01 00 00 00 00 3c 00 00 00 00 70 7d c0 21 45 1a 70 bd 64 05 7d 34 22 42 be 91 00 00 00 10 61 cd ab 4d 30 9d 24 fd 6b f6 53 8b d3 e1 bf 6a d9 a2 51 a8 d6 9e 42 67 2b 3b 2a 41 83 f7 8c a8 da ec fa 93 fairplay_decrypt ret = 0 16 byte aeskey (fairplay-decrypted from ekey): 21 2e 51 e5 e2 b8 02 40 8b 45 3b eb b9 59 a9 42 32 byte shared ecdh_secret: 67 61 66 6b 96 98 0b 8f 9f 85 68 03 b1 89 bb e5 1a 9e 89 c1 1f bd 2b ac 39 6d 63 52 d9 35 c1 77 Client identified as User-Agent: AirPlay/675.4.1 16 byte aeskey after sha-256 hash with ecdh_secret: 25 c8 6c b4 74 86 56 e4 e1 a5 d1 79 41 85 5c 45 timing_rport = 49806 raop_ntp parse remote ip = 192.168.101.50 raop_ntp starting time raop_ntp local timing port socket 35 port UDP 55020 raop_rtp parse remote ip = 192.168.101.50 raop_rtp_mirror parse remote ip = 192.168.101.50 eport = 44789, tport = 55020 raop_ntp send_len = 32 RTSP/1.0 200 OK CSeq: 6 Server: AirTunes/220.68 Content-Type: application/x-apple-binary-plist Content-Length: 77 timingPort 55020 eventPort 44789 raop_ntp receive time type_t packetlen = 32 raop_ntp sync correction = -1711117023922538 Accepted IPv4 client on socket 36 Local: 192.168.101.4 Remote: 192.168.101.50 Open connections: 2 httpd receiving on socket 34 conn_request GET /info RTSP/1.0 X-Apple-ProtocolVersion: 1 CSeq: 7 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 Handling request GET with URL /info RTSP/1.0 200 OK CSeq: 7 Server: AirTunes/220.68 Content-Type: application/x-apple-binary-plist Content-Length: 1064 txtAirPlay GmRldmljZWlkPTU0OmUxOmFkOjRjOjY2OmVlE2ZlYXR1cmVzPTB4NUE3RkZFRTYJZmxh Z3M9MHg0EG1vZGVsPUFwcGxlVFYzLDJDcGs9YjA3NzI3ZDZmNmNkNmUwOGI1OGVkZTUy NWVjM2NkZWFhMjUyYWQ5ZjY4M2ZlYjIxMmVmOGEyMDUyNDY1NTRlNydwaT0yZTM4ODAw Ni0xM2JhLTQwNDEtOWE2Ny0yNWRkNGE0M2Q1MzYOc3JjdmVycz0yMjAuNjgEdnY9Mg== features 130367356919 name UxPlay@ubuntu audioFormats type 100 audioInputFormats 67108860 audioOutputFormats 67108860 type 101 audioInputFormats 67108860 audioOutputFormats 67108860 pi 2e388006-13ba-4041-9a67-25dd4a43d536 vv 2 statusFlags 68 keepAliveLowPower 1 sourceVersion 220.68 pk sHcn1vbNbgi1jt5SXsPN6qJSrZ9oP+shLviiBSRlVOc= keepAliveSendStatsAsBody 1 deviceID 54:e1:ad:4c:66:ee audioLatencies outputLatencyMicros type 100 audioType default inputLatencyMicros outputLatencyMicros type 101 audioType default inputLatencyMicros model AppleTV3,2 macAddress 54:e1:ad:4c:66:ee displays uuid e0ff8a27-6738-3d56-8a16-cc53aacee925 widthPhysical heightPhysical width 1920 height 1080 widthPixels 1920 heightPixels 1080 rotation refreshRate 60 maxFPS 30 overscanned features 14 httpd receiving on socket 34 conn_request GET_PARAMETER rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 Content-Length: 8 Content-Type: text/parameters CSeq: 8 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 volume Handling request GET_PARAMETER with URL rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 200 OK CSeq: 8 Server: AirTunes/220.68 Content-Type: text/parameters Content-Length: 13 volume: 0.0 httpd receiving on socket 34 conn_request RECORD rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 CSeq: 9 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 Handling request RECORD with URL rtsp://192.168.101.4/14982237151650268337 raop_handler_record RTSP/1.0 200 OK CSeq: 9 Server: AirTunes/220.68 Audio-Latency: 11025 Audio-Jack-Status: connected; type=analog httpd receiving on socket 34 conn_request SET_PARAMETER rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 Content-Length: 20 Content-Type: text/parameters CSeq: 10 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 volume: -20.000000 Handling request SET_PARAMETER with URL rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 200 OK CSeq: 10 Server: AirTunes/220.68 httpd receiving on socket 34 conn_request SETUP rtsp://192.168.101.4/14982237151650268337 RTSP/1.0 Content-Length: 204 Content-Type: application/x-apple-binary-plist CSeq: 11 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 User-Agent: AirPlay/675.4.1 streams timestampInfo name SubSu name BePxT name AfPxT name BefEn name EmEnc latencyMs 100 type 110 streamConnectionID -5089426868939243270 Handling request SETUP with URL rtsp://192.168.101.4/14982237151650268337 DACP-ID: 185A9352032B6A1B Active-Remote: 2384520101 Transport: null type = 110 streamConnectionID (needed for AES-CTR video decryption key and iv): 13357317204770308346 raop_rtp_mirror starting mirroring raop_rtp_mirror local data port socket 37 port TCP 39229 Mirroring initialized successfully RTSP/1.0 200 OK CSeq: 11 Server: AirTunes/220.68 Content-Type: application/x-apple-binary-plist Content-Length: 85 streams dataPort 39229 type 110 raop_rtp_mirror accepting client begin video stream wxh = 1440x1080; source 1440x1080 raop_rtp_mirror width_source = 1440.000000 height_source = 1080.000000 width = 1440.000000 height = 1080.000000 raop_rtp_mirror sps size = 18 raop_rtp_mirror pps size = 4 raop_rtp_mirror video ntp = 1711119910289081, now = 1711119910223123, latency = -65958 raop_rtp_mirror video ntp = 1711119910339077, now = 1711119910236528, latency = -102549 raop_rtp_mirror video ntp = 1711119910372408, now = 1711119910270914, latency = -101494 raop_rtp_mirror video ntp = 1711119910405738, now = 1711119910303229, latency = -102509 raop_rtp_mirror video ntp = 1711119910439069, now = 1711119910347314, latency = -91755 raop_rtp_mirror video ntp = 1711119910472400, now = 1711119910372164, latency = -100236 raop_rtp_mirror video ntp = 1711119910505730, now = 1711119910417391, latency = -88339 raop_rtp_mirror video ntp = 1711119910539061, now = 1711119910447841, latency = -91220 raop_rtp_mirror video ntp = 1711119910572392, now = 1711119910479429, latency = -92963 GStreamer error: Failed to upload buffer Re-launching server... raop_rtp_mirror video ntp = 1711119910605722, now = 1711119910510692, latency = -95030 raop_rtp_mirror video ntp = 1711119910639053, now = 1711119910612274, latency = -26779 raop_rtp_mirror video ntp = 1711119910672384, now = 1711119910612510, latency = -59874 raop_rtp_mirror video ntp = 1711119910705714, now = 1711119910612538, latency = -93176 raop_rtp_mirror video ntp = 1711119910739045, now = 1711119910644978, latency = -94067 raop_rtp_mirror video ntp = 1711119910772376, now = 1711119910673045, latency = -99331 raop_rtp_mirror video ntp = 1711119910805706, now = 1711119910709750, latency = -95956 raop_rtp_mirror video ntp = 1711119910839037, now = 1711119910742892, latency = -96145 raop_rtp_mirror video ntp = 1711119910872368, now = 1711119910778819, latency = -93549 raop_rtp_mirror video ntp = 1711119910905698, now = 1711119910811498, latency = -94200 raop_rtp_mirror video ntp = 1711119910939029, now = 1711119910843679, latency = -95350 raop_rtp_mirror video ntp = 1711119910972360, now = 1711119910875064, latency = -97296 raop_rtp_mirror video ntp = 1711119911005690, now = 1711119910911452, latency = -94238 raop_rtp_mirror video ntp = 1711119911039021, now = 1711119910943786, latency = -95235 raop_rtp_mirror video ntp = 1711119911072352, now = 1711119910970786, latency = -101566 raop_rtp_mirror video ntp = 1711119911105682, now = 1711119911001154, latency = -104528 Removing connection for socket 34 Destroying connection Open connections: 1 raop_ntp stopping time thread raop_ntp exiting thread raop_ntp stopped time thread raop_rtp_mirror video ntp = 1711119911139013, now = 1711119911139054, latency = 41 raop_rtp_mirror exiting TCP thread Removing connection for socket 36 Destroying connection Open connections: 0 Exiting HTTP thread Initialized GStreamer video renderer Initialized server socket(s)
fduncanh commented 5 months ago

see #159

maybe try latest uxplay from there.

export GST_DEBUG=2 (or 4) to see what is going wrong in gstreamer