Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to playback (streaming) videos #693

Open
rmufr opened this issue Oct 16, 2018 · 8 comments
Open

Unable to playback (streaming) videos #693

rmufr opened this issue Oct 16, 2018 · 8 comments
Assignees

Comments

@rmufr
Copy link

rmufr commented Oct 16, 2018

I found the cause of the issue and filed an issue report in sabre-io/http. But it doesn't seem to have much echo since then: root cause issue in sabre-io/http

Expected behaviour

Finger tap on the video item that is not in local cache, it opens the player and the video playback starts almost immediately

Actual behaviour

Finger tap on the video item that is not in local cache, it opens the player, but show black screen, the playback never starts.

Steps to reproduce

Nextcloud server runs on a 32bit OS, then within the NC iOS app, finger tap on any video item that is not in local cache.
Note that this issue also breaks video playback of the webUI within the iOS device browser (tested with Safari and Chrome iOS)

iOS version

12.0.1

App version

2.22.4.0

Server configuration

Operating system:
Raspbian Stretch, up to date, running on a RPI3
Linux 4.14.71-v7+ #1145 SMP Fri Sep 21 15:38:35 BST 2018 armv7l GNU/Linux
Web server:
nginx/1.14.0
Database:
MariaDB 10.1.23
PHP version:
7.0.30
Nextcloud version: (see Nextcloud admin page)
14.0.3

@Knot3n
Copy link

Knot3n commented Oct 16, 2018

Can you give us some logs from PHP / Nginx / Nextcloud

@rmufr
Copy link
Author

rmufr commented Oct 16, 2018

Hi,
I observed that in iOS app or in iOS Safari, a video playback starts always with the client requesting the first 2 bytes of the video file. Here's the Nginx log (done with NC13 but it's the same with NC14) of this request:

80.12.xx.xx - - [20/Mar/2018:13:20:41 +0100] “GET /remote.php/webdav/Nextcloud.mp4 HTTP/2.0” resp status=206, body_bytes_sent=65535 “-” “Mozilla/5.0 (iPhone; CPU iPhone OS 11_2_6 like Mac OS X) AppleWebKit/604.5.6 (KHTML, like Gecko) Version/11.0 Mobile/15D100 Safari/604.1” “-” “myserver.dtdns.net” sn=“myserver.dtdns.net” rt=0.249 ua=“unix:/run/php/php7.0-fpm.sock” us=“206” ut=“0.197” upstream_response_length=“462877” cs=- Req.Content-Range=“bytes=0-1” Resp.range=bytes 0-1/462413 Accept-ranges=bytes stype=video/mp4

As I highlight in this log, the client requests bytes 0-1, the server replies partial content ok (206), with the response range header "bytes 0-1/462413". But the body_bytes_sent=65536, which is inconsistent (it should be =2).
In fact, the server send the whole stream instead of the first 2 bytes, and the iOS client closes the connexion.

@Knot3n
Copy link

Knot3n commented Oct 16, 2018

Strange, I cant reproduce that failure.

Can you show me the vhost for this instance?

@rmufr
Copy link
Author

rmufr commented Oct 16, 2018

Note that, it only occurs with the NC server running on a 32bit OS

@rmufr
Copy link
Author

rmufr commented Oct 16, 2018

Here's my nginx vhost. Basically it's the default nginx conf from Nextcloud 14 documentation.
nginx_vhost.txt

@Knot3n
Copy link

Knot3n commented Oct 16, 2018

Uhm, did you test a fresh install ?

When yes, maybe the 32bit is the problem but i hope or think not.

@rmufr
Copy link
Author

rmufr commented Oct 16, 2018

It is, indeed.
As I mentioned in my first post, I found the cause of the issue in sabre-io code, and filed an issue for that.
Here's the link : issue on sabre. But they don't seem to care too much at the moment.
I also proposed a quickfix here, cancelling the 32Bit OS test that causes the issue.

@wiegell
Copy link

wiegell commented Jun 21, 2021

I have had a similar problem, where the combination of Letsencrypt, Nginx, HTTP/2 and iOS for some reason screws up 206 range requests, but not regular 200 requests. All my problems have been solved by disabling HTTP/2 in nginx.
It's not HTTP/2 alone that is the problem though, since it can work perfectly with Charles debugging proxy (which uses HTTP/2). Very strange...

@marinofaggiana marinofaggiana self-assigned this Mar 7, 2022
marinofaggiana added a commit that referenced this issue Mar 8, 2022
Signed-off-by: marinofaggiana <ios@nextcloud.com>
This was referenced Mar 8, 2022
marinofaggiana added a commit that referenced this issue Mar 24, 2022
Signed-off-by: marinofaggiana <ios@nextcloud.com>
marinofaggiana added a commit that referenced this issue Mar 25, 2022
Signed-off-by: marinofaggiana <ios@nextcloud.com>
marinofaggiana added a commit that referenced this issue Mar 25, 2022
Signed-off-by: marinofaggiana <ios@nextcloud.com>
marinofaggiana added a commit that referenced this issue Apr 8, 2022
Signed-off-by: marinofaggiana <ios@nextcloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants