Troubleshooting Emby playback issues on Raspberry Pi 4

Category: Software Forum: Media Centers Started by: TheMovieFanatic

Hi everyone,

I've been using Emby on my Raspberry Pi 4 for a while now without major issues, but recently I've been experiencing frequent stuttering and buffering during playback, especially with 4K HDR content. My network is stable (Gigabit Ethernet), and other devices on the network play the same files perfectly.

Here's what I've tried so far:

  • Restarted the Raspberry Pi and Emby server.
  • Checked Emby server logs - no obvious errors related to playback.
  • Ensured Emby server and Raspberry Pi OS are up to date.
  • Tried different client devices (web browser, Android app) - the issue persists.

Could it be related to transcoding? I've set Emby to "Transcode if needed", but I don't think it should be transcoding 4K HDR content to itself. Any ideas or common solutions I might be missing?

Hello TheMovieFanatic,

That sounds frustrating! Let's try to pinpoint the issue.

Regarding transcoding, you're right, it shouldn't be transcoding 4K HDR to itself if direct play is possible. Can you check the Emby Dashboard during playback of a problematic file? It should show you if it's Direct Play, Direct Stream, or Transcoding. If it *is* transcoding, look at the reason provided.

Some common culprits for stuttering on RPi include:

  • Hardware Acceleration: Ensure your Raspberry Pi has the correct hardware acceleration drivers enabled and configured for Emby. For newer OS versions and Emby, this is often handled automatically, but it's worth double-checking.
  • Power Supply: An inadequate power supply can cause instability, especially under load. Ensure you're using a recommended USB-C power adapter for the Pi 4.
  • SD Card/Storage Speed: While less common for playback issues, if Emby is doing any significant logging or if the OS is heavily reliant on the SD card, a slow card could be a bottleneck.
  • Emby Configuration: Sometimes, specific codec settings or subtitle burning can force transcoding.

Can you provide the output from the Emby Dashboard during playback, as well as your general Emby server configuration regarding transcoding and hardware acceleration?

Thanks JediMaster!

I checked the dashboard during playback of a 4K HDR file, and it says Direct Play. The video bitrate is around 60 Mbps, and the audio is DTS-HD MA. There's no transcoding happening. This is what's confusing me.

Regarding your points:

  • Hardware Acceleration: I believe this is enabled. I'm running Raspberry Pi OS (64-bit) and Emby seems to be utilizing it. I'm not sure how to definitively check the drivers themselves for Emby.
  • Power Supply: I'm using the official Raspberry Pi 15W USB-C power supply.
  • SD Card: It's a reputable SanDisk Extreme Pro 64GB A2 card.
  • Emby Configuration: Hardware acceleration is set to 'Auto'. Max bitrate for local streaming is set to 'Maximum'. No subtitle burning is enabled.

It's almost like the Raspberry Pi's network interface or CPU is struggling to *receive* or *process* the direct stream smoothly, even though it's not transcoding. Could it be a CPU bottleneck with high bitrate direct play, even without transcoding?

Okay, Direct Play is the key here. If it's Direct Play, the Raspberry Pi's CPU is definitely involved in decoding the video and presenting it to the client. While the Pi 4 is capable, very high bitrate 4K HDR content (especially with complex HDR metadata or certain codecs like HEVC 10-bit) can push its limits.

Let's test a couple more things:

  1. Check CPU Usage: While playing a problematic file, SSH into your Raspberry Pi and run htop or top. See if any Emby-related processes (or the main Emby server process) are hitting 100% CPU.
  2. Try a Lower Bitrate File: Play a 4K file with a significantly lower bitrate (e.g., 20-30 Mbps) and see if the issue persists. This will help isolate if it's the bitrate itself.
  3. Network Throughput: Although you mentioned Gigabit, sometimes network driver issues or small packet overhead can cause hiccups. Ensure your Raspberry Pi OS is fully updated, including kernel and firmware. You can try a network speed test directly from the Pi to another machine on the network to confirm.
  4. Emby User Permissions: Less likely for playback, but ensure the Emby user has read permissions for all your media directories.

If the CPU is spiking to 100% during Direct Play, the Pi 4 might be struggling with decoding those specific high-bitrate files. In that case, you might need to consider:

  • Using a more powerful server for the Emby backend.
  • Pre-optimizing your media (e.g., re-encoding to a slightly less demanding codec or bitrate, though this is usually a last resort).
  • Using a dedicated client device that handles decoding better if the Pi is also acting as the server.

Post a Reply