Jump to content

Web player bug.


Bagul

Recommended Posts

Hello,
I have always had a bug. When a user looks at a media there is like a disconnection and it disappears from the dashboard to reappear a few seconds later. I lose all the commands. I can't pause or stop the user's playback and I also receive a notification.

I tried to use the latest stable version and the latest beta but no change.

 

 

play stop.png

embyserver.txt

Edited by Bagul
Link to comment
Share on other sites

Happy2Play

Well the activity log you posted is activity from Telegram Notifications.  As you can see the timestamp/user/client info align.

	Line 403513: 2021-12-20 00:02:16.262 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 441564: 2021-12-20 00:05:33.618 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470552: 2021-12-20 00:15:33.626 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470580: 2021-12-20 00:18:52.848 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470681: 2021-12-20 00:22:13.696 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470709: 2021-12-20 00:25:37.211 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470737: 2021-12-20 00:28:55.110 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 470995: 2021-12-20 00:57:05.232 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 471023: 2021-12-20 01:00:43.608 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 471164: 2021-12-20 01:04:23.492 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 471192: 2021-12-20 01:08:03.930 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 471290: 2021-12-20 01:15:24.631 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS
	Line 471318: 2021-12-20 01:19:03.335 Info HttpClient: POST https://api.telegram.org/bot1468649993:AAFLdoWun2D2-MECBozLH-71FY_iUYi49kU/sendmessage?chat_id=1018066391&text=Guillaume%20B%20vient%20d%27arr%C3%AAter%20la%20lecture%20de%20Succession%20-%20La%20f%C3%AAte%20sur%20Safari%20macOS

 

Link to comment
Share on other sites

Hello,
Thank you for your answers. Yes, on the dashboard the media playback information (photo) appears for a few moments and then disappears, and then returns without the play and stop buttons.

Indeed I receive notifications telegram and discord (webhook) because the server (I think) believes that the playback is finished while not at all.

 

130460121_Capturedcran2021-12-20221637.png.b64df124734acc69904800f7ae706f4c.png

Edited by Bagul
Link to comment
Share on other sites

Happy2Play

Is this the same client or a different one showing in Now Playing?

At the same time, it is a little odd showing the Stable and Beta release versions.

Your log shows you are on 4.7.0.19 beta server.

Link to comment
Share on other sites

So effectively the server is the same one that is currently on a beta version. But as I said I tried with the stable version and I switched to the beta to see if the problem was solved.

The screenshot was taken just before my message. So the client displayed is not the right one while I am indeed in beta but it goes through the web interface which is in beta.

But whether it is the stable version or the beta the problem persists.

 

 

Sorry for my English I try to explain as best I can but it's not my native language.

Edited by Bagul
Link to comment
Share on other sites

Hey,

I switched back to the stable version (4.6.7.0) and the client used for the web version is the 4.6.7.2 client.
But as you can see I still have the same problem with the commands disappearing.

 

 

859448557_Capturedcran2021-12-26222001.png.651c4ffbe90118072c7ff37121ee508b.png

Link to comment
Share on other sites

On 12/30/2021 at 6:42 PM, Bagul said:

I told the user to clear the browser cache and refresh the page.

Did that help?

Link to comment
Share on other sites

Happy2Play

Not sure what the variables are but I do not see this behavior.

image.png.6f0c9a74a428b6c8a910a112e741ca15.png

What is the connection method?

Link to comment
Share on other sites

Bagul

To be precise. My server is on a linux. My users access it through a reverse proxy made with swag (https://hub.docker.com/r/linuxserver/swag) on port 443. My clients have no problem to play videos. The commands disappear, that is to say that they are present for about 2 minutes and then my server tells me that the user has stopped the playback (when it is not true). After 10 seconds the summary of the playback reappears (the information on the dashboard) and the play/pause stop commands have disappeared.

Link to comment
Share on other sites

On 1/3/2022 at 10:22 AM, Bagul said:

Today, I make a video.

 

3min43 -> The information disappears

 

 

 

 

 

 

it's the same on web

image.png.d77433a6e1f8c4bdd9949fb328716369.png

I would take a look at your reverse proxy settings. Their websocket connection is probably being closed by the reverse proxy. When that connection closes, there's no way to send remote control commands and that's why the buttons go away.

Link to comment
Share on other sites

Bagul

Yeah i think it's the reverse proxy i have try with NginxProxyManager and Swag and it's the same.

Emby config

server {
    listen 80;
    listen 443 ssl;
    listen [::]:443 ssl;

    server_name emby.*;

    include /config/nginx/ssl.conf;

    client_max_body_size 0;

    location / {
        include /config/nginx/proxy.conf;
        include /config/nginx/resolver.conf;
        set $upstream_app emby;
        set $upstream_port 8096;
        set $upstream_proto http;
        proxy_pass $upstream_proto://192.168.1.100:$upstream_port;

        proxy_set_header Range $http_range;
        proxy_set_header If-Range $http_if_range;
    }
}

My proxy settings

# Proxy Connection Settings
proxy_buffers 32 4k;
proxy_connect_timeout 240;
proxy_headers_hash_bucket_size 128;
proxy_headers_hash_max_size 1024;
proxy_http_version 1.1;
proxy_read_timeout 240;
proxy_redirect  http://  $scheme://;
proxy_send_timeout 240;

# Proxy Cache and Cookie Settings
proxy_cache_bypass $cookie_session;
#proxy_cookie_path / "/; Secure"; # enable at your own risk, may break certain apps
proxy_no_cache $cookie_session;

# Proxy Header Settings
proxy_set_header Connection $connection_upgrade;
proxy_set_header Early-Data $ssl_early_data;
proxy_set_header Host $host;
proxy_set_header Proxy "";
proxy_set_header Upgrade $http_upgrade;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Forwarded-Ssl on;
proxy_set_header X-Real-IP $remote_addr;

and my nginx conf

# Set number of worker processes automatically based on number of CPU cores.
include /config/nginx/worker_processes.conf;

# Enables the use of JIT for regular expressions to speed-up their processing.
pcre_jit on;

# Configures default error logger.
error_log /config/log/nginx/error.log;

# Includes files with directives to load dynamic modules.
include /etc/nginx/modules/*.conf;

events {
    # The maximum number of simultaneous connections that can be opened by
    # a worker process.
    worker_connections 1024;
    # multi_accept on;
}

http {
    # Includes mapping of file name extensions to MIME types of responses
    # and defines the default type.
    include /etc/nginx/mime.types;
    default_type application/octet-stream;

    # Name servers used to resolve names of upstream servers into addresses.
    # It's also needed when using tcpsocket and udpsocket in Lua modules.
    #resolver 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001;
    include /config/nginx/resolver.conf;

    # Don't tell nginx version to the clients. Default is 'on'.
    server_tokens off;

    # Specifies the maximum accepted body size of a client request, as
    # indicated by the request header Content-Length. If the stated content
    # length is greater than this size, then the client receives the HTTP
    # error code 413. Set to 0 to disable. Default is '1m'.
    client_max_body_size 0;

    # Sendfile copies data between one FD and other from within the kernel,
    # which is more efficient than read() + write(). Default is off.
    sendfile on;

    # Causes nginx to attempt to send its HTTP response head in one packet,
    # instead of using partial frames. Default is 'off'.
    tcp_nopush on;

    # Helper variable for proxying websockets.
    map $http_upgrade $connection_upgrade {
        default upgrade;
        '' close;
    }

    # Sets the path, format, and configuration for a buffered log write.
    access_log /config/log/nginx/access.log;

    # Includes virtual hosts configs.
    #include /etc/nginx/http.d/*.conf;

    # WARNING: Don't use this directory for virtual hosts anymore.
    # This include will be moved to the root context in Alpine 3.14.
    #include /etc/nginx/conf.d/*.conf;


    ##
    # Basic Settings
    ##

    client_body_buffer_size 128k;
    keepalive_timeout 65;
    large_client_header_buffers 4 16k;
    send_timeout 5m;
    tcp_nodelay on;
    types_hash_max_size 2048;
    variables_hash_max_size 2048;
    # server_names_hash_bucket_size 64;
    # server_name_in_redirect off;

    ##
    # Gzip Settings
    ##

    gzip on;
    gzip_disable "msie6";
    # gzip_vary on;
    # gzip_proxied any;
    # gzip_comp_level 6;
    # gzip_buffers 16 8k;
    # gzip_http_version 1.1;
    # gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;

    ##
    # nginx-naxsi config
    ##
    # Uncomment it if you installed nginx-naxsi
    ##

    #include /etc/nginx/naxsi_core.rules;

    ##
    # nginx-passenger config
    ##
    # Uncomment it if you installed nginx-passenger
    ##

    #passenger_root /usr;
    #passenger_ruby /usr/bin/ruby;

    ##
    # Virtual Host Configs
    ##
    include /config/nginx/site-confs/*;
    #Removed lua. Do not remove this comment
}

#mail {
#    # See sample authentication script at:
#    # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
#
#    # auth_http localhost/auth.php;
#    # pop3_capabilities "TOP" "USER";
#    # imap_capabilities "IMAP4rev1" "UIDPLUS";
#
#    server {
#        listen     localhost:110;
#        protocol   pop3;
#        proxy      on;
#    }
#
#    server {
#        listen     localhost:143;
#        protocol   imap;
#        proxy      on;
#    }
#}

daemon off;
pid /run/nginx.pid;

I haven't tried putting my ssl certificate directly into the Emby configuration yet to see if the problem persists. But I would like to keep my reverse proxy.

Link to comment
Share on other sites

Bagul

Ok if i change value for this options

proxy_connect_timeout 240;
proxy_read_timeout 240;
proxy_send_timeout 240;

to

proxy_connect_timeout 1d;
proxy_read_timeout 1d;
proxy_send_timeout 1d;

I feel like the problem is no longer there. But won't that cause a safety problem? 

I need to try a value by value to find the exact option that is the problem.

Link to comment
Share on other sites

Bagul

Hello,
I have already compared. The proxy_send_timeout and proxy_read_timeout options are not specified and according to the nginx documentation the default values are 60 seconds.
I will try to remove the options to leave the default one but otherwise the rest is the same.

Link to comment
Share on other sites

Bagul

But for example, at the moment a user is no longer watching a movie. But the server sends notifications telling me that he has stopped playing every 2 minutes.
The specified client is 4.6.7.0 so it is the right version. And this only happens with the web player. Android, IOS applications don't do that.

The translation of the message: "Guillaume B just stopped reading ..."

 

image.png.a65a9b88f6b6d140ad5a2d1c0779101c.png

Link to comment
Share on other sites

The way the server reacts to the web socket connection being closed can be improved, yes, but preventing that altogether is still your best bet.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...