Jellyfin Forum
SOLVED: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - Printable Version

+- Jellyfin Forum (https://forum.jellyfin.org)
+-- Forum: Support (https://forum.jellyfin.org/f-support)
+--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting)
+--- Thread: SOLVED: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin (/t-solved-nvidia-driver-install-ubuntu-slows-loading-and-seeking-in-jellyfin)

Pages: 1 2


Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - buzuddha - 2023-10-25

Hi All,

The problem: Loading and seeking through jellyfin interface has become quite slow after nvidia driver install and HW acceleration

Fresh install of ubuntu 23.04 and jellyfin. I attempted to install nvidia drivers initially but nvidia-smi threw an error saying it couldn't connect. This error notwithstanding, I was able to stream videos that looked great with near instant load and seeks with full HD audiotracks. The only issue I ran into was that MPEG2  and VC1 streams wouldn't load on many clients (though not all). Despite that, copying the URL and streaming from VLC always worked fine.  

I figured I needed to fix the HW acceleration issue and this would resolve the MPEG2 transcode, so I set about googling and realized I'd installed nvidia-utils-535-server rather than nvidia-driver-535-server. So I installed the drivers and poof nvidia-smi gave output. Yay. Likewise, I was able to solve the issues with MPEG2/VC1. Now, even a DVD MPEG2 film will take a few seconds to load and seeking can take a few seconds to load (same is true for HEVC/H264). Likewise, I've even unchecked the HEVC HW transcode tick box and the problem persists. Still copying the URL and streaming from VLC gives instant loads and seeks for 4K/DTSHD content.

Log should include - server reboot, jellyfin startup, play MPEG2 via jellyfin, MPEG2 via UL in VLC, 4K HEVC in Jellyfin, 4K HEVC in VLC

Logs are here: 
JF.log
HEVC Transcode Log
MPEG2 Transcode Log

Any help here is greatly appreciated!

Thanks


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - TheDreadPirate - 2023-10-25

What are the specs of your server? There are no errors in your log. You can't compare local playback with VLC to streaming with Jellyfin. Transcoding is pretty intensive and your server has to build up a bit of a buffer before it starts streaming.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - buzuddha - 2023-10-25

Sorry, just to be clear. Using VLC isn't local. I'm opening the media URL in VLC as a stream. So loading and seeking remotely on my laptop from the server using VLC as the client is instantaneous.

The server is:
Ubuntu 23.04
CPU: i5-10400K
MB: B460M A/C
RAM: 16GB
System SSD: Samsung EVO 970 (Gen3)
GPU: ASUS GTX 1650 MINI OC

I've run iperf before and I'm in the 600 MB/s range on wifi and full 1GB/s on ethernet. So I believe the issue doesn't lie in a hardware limitation.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - TheDreadPirate - 2023-10-25

If you are providing the media URL then VLC is handling all the video decoding and jellyfin is just sending the file.

When you play a video in Jellyfin that requires a transcode jellyfin has to start up ffmpeg and build up a buffer before starting playback. Same thing when you skip ahead of where it has transcoded.

To be clear, what you are describing is normal behavior when there is a transcode. It is slower than if it was direct playing.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - buzuddha - 2023-10-25

Gotcha, so I guess I'd just prefer the direct play then. Problem there is that MPEG2 and VC1 doesn't play on ipad/android clients. I've tried to uncheck the box for HW acceleration for HEVC but it still fires up the transcoding.

I'm finding this in the log
PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported for HEVC even after unchecking the transcode box.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - TheDreadPirate - 2023-10-25

Those check boxes are for hardware accelerated DECODING and only apply when there is transcoding. Transcoding only happens when the CLIENT requests a transcode. When the client requests a direct play those check boxes don't matter.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - buzuddha - 2023-10-25

Welp...it does say that right there.

Clarified! Many thanks for your help here!

Any way to get iOS jellyfin to send streams to VLC the way android does? Or otherwise have the jellyfin client send streams to a program that can decode lots of streams?


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - TheDreadPirate - 2023-10-25

Not that I'm aware of. Are you using Jellyfin Mobile for iOS or Swiftfin?


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - buzuddha - 2023-10-25

Dang. JF Mobile. Just gave Swiftfin a look, but no dice. Turn off HW encode on the server side and the MPEG2 doesn't load on the client.


RE: Nvidia driver install (ubuntu) slows loading and seeking in jellyfin - TheDreadPirate - 2023-10-25

You want hardware acceleration on. Your server is probably CPU transcoding and going very slowly because your content is 4K according to the ffmpeg log.

And what do mean "no dice" when using Swiftfin?

For the decoding check boxes. Check everything except AV1.

Check enhanced decoder

Check allow encoding in HEVC. Save.