SmiddyJR 2 Posted April 17, 2025 Posted April 17, 2025 I first noticed a decrease in users watching as the dashboard showed no one playing, I could see them authenticating in activity just never watching anything. After testing, I can see multiple users activity is just not being recorded, I setup jellystat to try and get some metrics and several users have apparerntly never logged in or watched anything despite using it frequently. At the same time whenever users do watch something, it doesnt save play sessions so the continue watching is no longer updating and they have to manually mark episodes as watched. This still doesnt make a show appear in continue watching. Today I did some testing done from alternative devices, so affected user from a PC browser where there was no issues. It seems to be specifically for Apple TV and possibly Amazon Fire stick users. Shield TV, Emby Theatre, Web Browser, LG TV, Samsung TV these devices do not seem to having any issues. When checking the logs I can see some 404 GETs on played items, just after the session manager is reporting it is adding sessions. (Below) Working on parsing the logs in PowerShell so I can format into CSV for better filtering, but comparing header information nothing glaringly obvious, thought i did lose a couple of nights wondering why everything was host3 or host9, (I am running behind a traefik reverse proxy, and cloudflare tunnel) but even local IP traffic generates similar logs and that doesnt go through either. I am going to try troubleshooting with debug logs next. But wanted to make a post and see if anyone else has had this before, or are seeing it now. Appreciate any advice on troubleshooting, or possible settings i may have missed that could cause this. Thanks! In the logs the successful session from a web browser is around here 2025-04-17 10:08:51.324 Info Server: http/1.1 POST http://emby_remote_ip/emby/Sessions/Playing/Progress?X-Emby-Client=Emby Web&X-Emby-Device-Name=Google Chrome Windows&X-Emby-Device-Id=2aa5a356-393f-448b-8f03-18511c3219dc&X-Emby-Client-Version=4.8.10.0&X-Emby-Token=x_secret16_x&X-Emby-Language=en-gb&reqformat=json. Source Ip: host3, UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/135.0.0.0 Safari/537.36 A failed session adding from Apple TV occured around here, 2025-04-17 19:12:22.569 Info SessionManager: Adding playSession 02af3661348e4671ac357d158b6d290e to session 4b3e80377729a6781ac26bbf59b6f2c7 2025-04-17 19:12:24.730 Info Server: http/1.1 Response 404 to host3. Time: 0ms. GET http://emby_remote_ip/emby/Users/b636b0bf0e5840438082725af30ffc81/PlayedItems/205969?X-Emby-Client=Emby for Apple TV&X-Emby-Device-Name=Apple TV&X-Emby-Device-Id=C8CB437E-8D2E-483C-85E3-BF53F9951102&X-Emby-Client-Version=1.9.7 (1)&X-Emby-Token=x_secret10_x The only other common error I am seeing is only an assumption, from these switches "-updatepackage emby-server-deb_{version}_amd64.deb" but possibly failed self updates? 2025-04-17 10:32:48.418 Error Server: Error processing request *** Error Report *** Version: 4.8.10.0 Command line: /opt/emby-server/system/EmbyServer.dll -programdata /var/lib/emby -ffdetect /opt/emby-server/bin/ffdetect -ffmpeg /opt/emby-server/bin/ffmpeg -ffprobe /opt/emby-server/bin/ffprobe -restartexitcode 3 -updatepackage emby-server-deb_{version}_amd64.deb Operating system: Linux version 5.15.0-136-generic (buildd@lcy02-amd64-034) (gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #147-Ubun Framework: .NET 6.0.31 OS/Process: x64/x64 Runtime: opt/emby-server/system/System.Private.CoreLib.dll Processor count: 4 Data path: /var/lib/emby Application path: /opt/emby-server/system System.NullReferenceException: System.NullReferenceException: Object reference not set to an instance of an object. at Emby.Api.Images.ImageService.GetImage(ImageRequest request, Int64 itemId, BaseItem item, Boolean isHeadRequest) at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task) at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost httpHost, IServerApplicationHost appHost, IRequest httpReq, IResponse httpRes, IStreamHelper streamHelper, RestPath restPath, String responseContentType, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken) Source: Emby.Api TargetSite: Void MoveNext() Current version Emby Server Version 4.8.10.0embyserver.txt
Solution Luke 42077 Posted April 17, 2025 Solution Posted April 17, 2025 Hi, this is likely due to misconfigured reverse proxy: 2025-04-17 18:50:24.663 Info Server: http/1.1 Response 404 to host3. Time: 0ms. GET http://emby_remote_ip/emby/Sessions/Capabilities/Full?X-Emby-Client=Emby for Apple TV&X-Emby-Device-Name=Apple TV&X-Emby-Device-Id=C8CB437E-8D2E-483C-85E3-BF53F9951102&X-Emby-Client-Version=1.9.7 (1)&X-Emby-Token=x_secret10_x&reqformat=json That request should be a post, not a get. Regardless of what reverse proxy software you are using, I would suggest comparing it's configuration to this:
SmiddyJR 2 Posted April 18, 2025 Author Posted April 18, 2025 Thanks Luke! Is stuck in trace and debug logs, and changed a setting inside Emby which I thought I had already changed. (Secure connection mode, was not set to handled by reverse proxy) It seems to be working now, and im getting users showing on dashboard and data in jellystat, other than trace and debug logs I had not gotten around to tweaking the reverse proxy. I was going to check if I needed to push through x-forwarded-for or something similar. When i look through previous days logs I cannot find any POSTS for this user (PlaybackInfo?UserId=b636b0bf0e5840438082725af30ffc81), unless it was from google chrome. But now they are appearing, and I cannot find any of this since the change (GET http://emby_remote_ip/emby/Sessions/Capabilities/Full?X-Emby-Client=Emby for Apple TV) Ill keep an eye on other users and test with fire TV too, and close this ticket after 24 hours Have a great weekend! 2025-04-18 11:16:45.604 Info Server: http/1.1 POST http://emby_remote_ip/emby/Items/193845/PlaybackInfo?UserId=b636b0bf0e5840438082725af30ffc81&StartTimeTicks=0&IsPlayback=false&AutoOpenLiveStream=false&MaxStreamingBitrate=40000000&X-Emby-Client=Emby for Apple TV&X-Emby-Device-Name=Apple TV&X-Emby-Device-Id=C8CB437E-8D2E-483C-85E3-BF53F9951102&X-Emby-Client-Version=1.9.7 (1)&X-Emby-Token=x_secret10_x&reqformat=json. Source Ip: host3, UserAgent: Emby/1 CFNetwork/3826.400.120 Darwin/24.3.0 172.19.0.1 - - [18/Apr/2025:11:15:21 +0000] "POST /emby/Items/206690/PlaybackInfo?UserId=b636b0bf0e5840438082725af30ffc81&StartTimeTicks=0&IsPlayback=false&AutoOpenLiveStream=false&MaxStreamingBitrate=40000000&X-Emby-Client=Emby+for+Apple+TV&X-Emby-Device-Name=Apple+TV&X-Emby-Device-Id=C8CB437E-8D2E-483C-85E3-BF53F9951102&X-Emby-Client-Version=1.9.7+%281%29&X-Emby-Token=4ddefc2ca45f46bf8572523dbad43ce2&reqformat=json HTTP/1.1" 200 3333 "-" "-" 37 "emby-ext@file" "http://192.168.1.100:32704/" 7ms 1
SmiddyJR 2 Posted April 22, 2025 Author Posted April 22, 2025 Starting to see other users appear now, and one from an Amazon Fire TV. Thanks for the advice! Why would some traffic make it through the proxy without issue, and others just partially?
Luke 42077 Posted April 22, 2025 Posted April 22, 2025 9 hours ago, SmiddyJR said: Starting to see other users appear now, and one from an Amazon Fire TV. Thanks for the advice! Why would some traffic make it through the proxy without issue, and others just partially? That's a good question. Does the reverse proxy have logs to help answer that?
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now