--- id: 0054887d-3516-452d-b3d1-eb5fef1a5c2a type: solution title: "Jellyfin FFmpeg exit code 187 - GPU access lost" tags: [jellyfin, gpu, nvidia, transcoding, ffmpeg, homelab, monitoring] importance: 0.8 confidence: 0.8 created: "2026-01-29T04:07:55.301701+00:00" updated: "2026-01-29T04:07:55.301701+00:00" --- Jellyfin transcoding fails with FFmpeg exit code 187 when container loses GPU access. Symptoms: playback fails immediately, nvidia-smi inside container returns 'Failed to initialize NVML: Unknown Error'. Fix: restart container with 'docker restart jellyfin'. Root cause: GPU binding becomes stale after driver updates, Docker restarts, or runtime issues. Solution: Created jellyfin_gpu_monitor.py that runs every 5 minutes on ubuntu-manticore, detects GPU loss, sends Discord alert, and auto-restarts container.