[Issue]: encoding.xml gets reset when server is restarted (ffmpeg) #6115

Closed
opened 2026-02-07 03:05:49 +03:00 by OVERLORD · 2 comments
Owner

Originally created by @Bad3r on GitHub (Jul 13, 2024).

Please describe your bug

I want to change the path of ffmpeg by editing /etc/jellyfin/encoding.xml as advised.

The issue is that /etc/jellyfin/encoding.xml gets reset resetting the path every time the service is restarted

image

Reproduction Steps

  1. disable jellyfin service
  2. change ffmpeg path in /etc/jellyfin/encoding.xml
  3. start jellyfin service
  4. ffmpeg path gets reset
❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg    
  <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay>

❯ sudo sed -i 's|  <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay>|  <EncoderAppPathDisplay>/usr/bin/ffmpeg</EncoderAppPathDisplay>|' /etc/jellyfin/encoding.xml


❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg    
  <EncoderAppPathDisplay>/usr/bin/ffmpeg</EncoderAppPathDisplay>

❯ sudo systemctl restart jellyfin.service

❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg
  <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay>

Note

the sed command replaces /usr/lib/jellyfin-ffmpeg/ffmpeg with /usr/bin/ffmpeg

Note

note that it takes ~few seconds for the value to be updated after service restart

Jellyfin Version

10.9.0

if other:

No response

Environment

- OS: Arch linux 
- Linux Kernel: 6.9.9
- Virtualization: NONE
- Clients: Browser
- Browser: NA
- FFmpeg Version: 1.6.0
  - jellyfin-ffmpeg 1:6.0.1p7-5
  - system ffmpeg: ffmpeg-full-git 7.1.r116051.g0b330d8642-1
- Playback Method: Direct Play
- Hardware Acceleration: NVENC
- GPU Model: GTX1060
- Plugins: None/Default
- Reverse Proxy: None
- Base URL: none/localhost
- Networking: host
- Storage: local

Jellyfin logs

[2024-07-13 16:48:21.720 +03:00] [INF] Jellyfin version: "10.9.7"
[2024-07-13 16:48:21.743 +03:00] [INF] Environment Variables: ["[JELLYFIN_LOG_DIR, /var/log/jellyfin]", "[JELLYFIN_CACHE_DIR, /var/cache/jellyfin]", "[JELLYFIN_ARGS, $JELLYFIN_WEB_OPT $JELLYFIN_FFMPEG_OPT $JELLYFIN_SERVICE_OPT $JELLYFIN_NOWEBAPP_OPT $JELLFIN_ADDITIONAL_OPTS --datadir $JELLYFIN_DATA_DIR --configdir $JELLYFIN_CONFIG_DIR --logdir $JELLYFIN_LOG_DIR --cachedir $JELLYFIN_CACHE_DIR]", "[JELLYFIN_WEB_OPT, --webdir=/usr/share/jellyfin/web]", "[JELLYFIN_USER, jellyfin]", "[JELLYFIN_CONFIG_DIR, /etc/jellyfin]", "[JELLYFIN_DATA_DIR, /var/lib/jellyfin]", "[JELLYFIN_FFMPEG_OPT, --ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg]", "[JELLYFIN_ADDITIONAL_OPTS, ]"]
[2024-07-13 16:48:21.744 +03:00] [INF] Arguments: ["/usr/lib/jellyfin/jellyfin.dll", "--webdir=/usr/share/jellyfin/web", "--ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg"]
[2024-07-13 16:48:21.745 +03:00] [INF] Operating system: "Arch Linux"
[2024-07-13 16:48:21.745 +03:00] [INF] Architecture: X64
[2024-07-13 16:48:21.745 +03:00] [INF] 64-Bit Process: True
[2024-07-13 16:48:21.745 +03:00] [INF] User Interactive: True
[2024-07-13 16:48:21.745 +03:00] [INF] Processor count: 12
[2024-07-13 16:48:21.745 +03:00] [INF] Program data path: "/var/lib/jellyfin"
[2024-07-13 16:48:21.745 +03:00] [INF] Log directory path: "/var/log/jellyfin"
[2024-07-13 16:48:21.745 +03:00] [INF] Config directory path: "/etc/jellyfin"
[2024-07-13 16:48:21.745 +03:00] [INF] Cache path: "/var/cache/jellyfin"
[2024-07-13 16:48:21.745 +03:00] [INF] Web resources path: "/usr/share/jellyfin/web"
[2024-07-13 16:48:21.745 +03:00] [INF] Application directory: "/usr/lib/jellyfin/"
[2024-07-13 16:48:21.753 +03:00] [INF] Marking following migrations as applied because this is a fresh install: ["CreateNetworkConfiguration", "MigrateMusicBrainzTimeout", "MigrateNetworkConfiguration"]
[2024-07-13 16:48:21.812 +03:00] [INF] Setting cache path: "/var/cache/jellyfin"
[2024-07-13 16:48:21.840 +03:00] [INF] Loading assemblies
[2024-07-13 16:48:21.877 +03:00] [INF] Defined LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"]
[2024-07-13 16:48:21.877 +03:00] [INF] Defined LAN exclusions: []
[2024-07-13 16:48:21.877 +03:00] [INF] Used LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"]
[2024-07-13 16:48:21.878 +03:00] [INF] Filtered interface addresses: ["127.0.0.1", "192.168.8.139", "172.16.238.1", "192.168.52.1"]
[2024-07-13 16:48:21.878 +03:00] [INF] Bind Addresses ["0.0.0.0"]
[2024-07-13 16:48:21.878 +03:00] [INF] Remote IP filter is "Allowlist"
[2024-07-13 16:48:21.879 +03:00] [INF] Filtered subnets: []
...
[2024-07-13 16:48:24.162 +03:00] [INF] Found ffmpeg version "6.0.1"
[2024-07-13 16:48:24.199 +03:00] [INF] Available "decoders": ["libdav1d", "av1", "av1_cuvid", "av1_qsv", "h264", "h264_qsv", "h264_cuvid", "hevc", "hevc_qsv", "hevc_cuvid", "mpeg2video", "mpeg2_qsv", "mpeg2_cuvid", "mpeg4", "mpeg4_cuvid", "msmpeg4", "vc1_qsv", "vc1_cuvid", "vp8", "libvpx", "vp8_cuvid", "vp8_qsv", "vp9", "libvpx-vp9", "vp9_cuvid", "vp9_qsv", "aac", "ac3", "dca", "flac", "mp3", "truehd"]
[2024-07-13 16:48:24.219 +03:00] [INF] Available "encoders": ["av1_nvenc", "av1_qsv", "av1_amf", "av1_vaapi", "libx264", "h264_amf", "h264_nvenc", "h264_qsv", "h264_v4l2m2m", "h264_vaapi", "libx265", "hevc_amf", "hevc_nvenc", "hevc_qsv", "hevc_vaapi", "mjpeg_qsv", "mjpeg_vaapi", "mpeg4", "msmpeg4", "libvpx", "libvpx-vp9", "aac", "ac3", "alac", "dca", "flac", "libmp3lame", "libopus", "truehd", "libvorbis", "srt"]
[2024-07-13 16:48:24.239 +03:00] [INF] Available filters: ["deinterlace_qsv", "deinterlace_vaapi", "hwupload_cuda", "hwupload_vaapi", "libplacebo", "overlay_opencl", "overlay_qsv", "overlay_vaapi", "overlay_vulkan", "overlay_cuda", "procamp_vaapi", "scale_cuda", "scale_opencl", "scale_qsv", "scale_vaapi", "scale_vulkan", "tonemap_cuda", "tonemap_opencl", "tonemap_vaapi", "vpp_qsv", "yadif_cuda", "zscale", "alphasrc"]
[2024-07-13 16:48:24.366 +03:00] [INF] Available hwaccel types: ["vdpau", "cuda", "vaapi", "qsv", "drm", "opencl", "vulkan"]
[2024-07-13 16:48:24.469 +03:00] [INF] FFmpeg: "/usr/lib/jellyfin-ffmpeg/ffmpeg"
[2024-07-13 16:48:24.469 +03:00] [INF] ServerId: "e70988f8858042ccb7d9e8afbb7cf08e"
[2024-07-13 16:48:24.469 +03:00] [INF] Core startup complete
[2024-07-13 16:48:24.469 +03:00] [INF] Startup complete 0:00:02.8630776
[2024-07-13 16:48:27.141 +03:00] [INF] "Clean up collections and playlists" Completed after 0 minute(s) and 0 seconds
[2024-07-13 16:48:29.349 +03:00] [INF] "Update Plugins" Completed after 0 minute(s) and 2 seconds
[2024-07-13 16:49:18.742 +03:00] [INF] Saving system configuration
[2024-07-13 16:49:18.743 +03:00] [INF] Setting cache path: "/var/cache/jellyfin"
[2024-07-13 16:49:18.744 +03:00] [INF] Stopping NAT discovery
[2024-07-13 16:49:18.768 +03:00] [WRN] No users, creating one with username "jellyfin"
[2024-07-13 16:51:35.890 +03:00] [INF] Saving system configuration
[2024-07-13 16:51:35.890 +03:00] [INF] Setting cache path: "/var/cache/jellyfin"
[2024-07-13 16:51:50.480 +03:00] [INF] Defined LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"]
[2024-07-13 16:51:50.480 +03:00] [INF] Defined LAN exclusions: []
[2024-07-13 16:51:50.480 +03:00] [INF] Used LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"]
[2024-07-13 16:51:50.480 +03:00] [INF] Filtered interface addresses: ["127.0.0.1", "192.168.8.139", "172.16.238.1", "192.168.52.1"]
[2024-07-13 16:51:50.480 +03:00] [INF] Bind Addresses ["0.0.0.0"]
[2024-07-13 16:51:50.480 +03:00] [INF] Remote IP filter is "Allowlist"
[2024-07-13 16:51:50.480 +03:00] [INF] Filtered subnets: []
[2024-07-13 16:51:51.772 +03:00] [INF] Saving system configuration
[2024-07-13 16:51:51.773 +03:00] [INF] Setting cache path: "/var/cache/jellyfin"
[2024-07-13 16:51:51.774 +03:00] [INF] Stopping NAT discovery
[2024-07-13 16:51:51.775 +03:00] [INF] Validating media library
[2024-07-13 16:51:52.026 +03:00] [WRN] Library folder "/var/lib/jellyfin/data/playlists" is inaccessible or empty, skipping
[2024-07-13 16:51:52.145 +03:00] [WRN] Library folder "/var/lib/jellyfin/data/playlists" is inaccessible or empty, skipping
...

FFmpeg logs

No response

Please attach any browser or client logs here

No response

Please attach any screenshots here

image

Code of Conduct

  • I agree to follow this project's Code of Conduct
Originally created by @Bad3r on GitHub (Jul 13, 2024). ### Please describe your bug I want to change the path of ffmpeg by editing `/etc/jellyfin/encoding.xml` as [advised](https://jellyfin.org/posts/jellyfin-security-and-you/). The issue is that `/etc/jellyfin/encoding.xml` gets reset resetting the path every time the service is restarted ![image](https://github.com/user-attachments/assets/092820e9-f2a7-45e7-89b6-09846e53f6c0) ### Reproduction Steps 1. disable jellyfin service 2. change ffmpeg path in `/etc/jellyfin/encoding.xml` 3. start jellyfin service 4. ffmpeg path gets reset ```sh ❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay> ❯ sudo sed -i 's| <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay>| <EncoderAppPathDisplay>/usr/bin/ffmpeg</EncoderAppPathDisplay>|' /etc/jellyfin/encoding.xml ❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg <EncoderAppPathDisplay>/usr/bin/ffmpeg</EncoderAppPathDisplay> ❯ sudo systemctl restart jellyfin.service ❯ cat /etc/jellyfin/encoding.xml | \grep --color=auto ffmpeg <EncoderAppPathDisplay>/usr/lib/jellyfin-ffmpeg/ffmpeg</EncoderAppPathDisplay> ``` > [!NOTE] > the `sed` command replaces `/usr/lib/jellyfin-ffmpeg/ffmpeg` with `/usr/bin/ffmpeg` > [!NOTE] > note that it takes ~few seconds for the value to be updated after service restart ### Jellyfin Version 10.9.0 ### if other: _No response_ ### Environment ```markdown - OS: Arch linux - Linux Kernel: 6.9.9 - Virtualization: NONE - Clients: Browser - Browser: NA - FFmpeg Version: 1.6.0 - jellyfin-ffmpeg 1:6.0.1p7-5 - system ffmpeg: ffmpeg-full-git 7.1.r116051.g0b330d8642-1 - Playback Method: Direct Play - Hardware Acceleration: NVENC - GPU Model: GTX1060 - Plugins: None/Default - Reverse Proxy: None - Base URL: none/localhost - Networking: host - Storage: local ``` ### Jellyfin logs ```shell [2024-07-13 16:48:21.720 +03:00] [INF] Jellyfin version: "10.9.7" [2024-07-13 16:48:21.743 +03:00] [INF] Environment Variables: ["[JELLYFIN_LOG_DIR, /var/log/jellyfin]", "[JELLYFIN_CACHE_DIR, /var/cache/jellyfin]", "[JELLYFIN_ARGS, $JELLYFIN_WEB_OPT $JELLYFIN_FFMPEG_OPT $JELLYFIN_SERVICE_OPT $JELLYFIN_NOWEBAPP_OPT $JELLFIN_ADDITIONAL_OPTS --datadir $JELLYFIN_DATA_DIR --configdir $JELLYFIN_CONFIG_DIR --logdir $JELLYFIN_LOG_DIR --cachedir $JELLYFIN_CACHE_DIR]", "[JELLYFIN_WEB_OPT, --webdir=/usr/share/jellyfin/web]", "[JELLYFIN_USER, jellyfin]", "[JELLYFIN_CONFIG_DIR, /etc/jellyfin]", "[JELLYFIN_DATA_DIR, /var/lib/jellyfin]", "[JELLYFIN_FFMPEG_OPT, --ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg]", "[JELLYFIN_ADDITIONAL_OPTS, ]"] [2024-07-13 16:48:21.744 +03:00] [INF] Arguments: ["/usr/lib/jellyfin/jellyfin.dll", "--webdir=/usr/share/jellyfin/web", "--ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg"] [2024-07-13 16:48:21.745 +03:00] [INF] Operating system: "Arch Linux" [2024-07-13 16:48:21.745 +03:00] [INF] Architecture: X64 [2024-07-13 16:48:21.745 +03:00] [INF] 64-Bit Process: True [2024-07-13 16:48:21.745 +03:00] [INF] User Interactive: True [2024-07-13 16:48:21.745 +03:00] [INF] Processor count: 12 [2024-07-13 16:48:21.745 +03:00] [INF] Program data path: "/var/lib/jellyfin" [2024-07-13 16:48:21.745 +03:00] [INF] Log directory path: "/var/log/jellyfin" [2024-07-13 16:48:21.745 +03:00] [INF] Config directory path: "/etc/jellyfin" [2024-07-13 16:48:21.745 +03:00] [INF] Cache path: "/var/cache/jellyfin" [2024-07-13 16:48:21.745 +03:00] [INF] Web resources path: "/usr/share/jellyfin/web" [2024-07-13 16:48:21.745 +03:00] [INF] Application directory: "/usr/lib/jellyfin/" [2024-07-13 16:48:21.753 +03:00] [INF] Marking following migrations as applied because this is a fresh install: ["CreateNetworkConfiguration", "MigrateMusicBrainzTimeout", "MigrateNetworkConfiguration"] [2024-07-13 16:48:21.812 +03:00] [INF] Setting cache path: "/var/cache/jellyfin" [2024-07-13 16:48:21.840 +03:00] [INF] Loading assemblies [2024-07-13 16:48:21.877 +03:00] [INF] Defined LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"] [2024-07-13 16:48:21.877 +03:00] [INF] Defined LAN exclusions: [] [2024-07-13 16:48:21.877 +03:00] [INF] Used LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"] [2024-07-13 16:48:21.878 +03:00] [INF] Filtered interface addresses: ["127.0.0.1", "192.168.8.139", "172.16.238.1", "192.168.52.1"] [2024-07-13 16:48:21.878 +03:00] [INF] Bind Addresses ["0.0.0.0"] [2024-07-13 16:48:21.878 +03:00] [INF] Remote IP filter is "Allowlist" [2024-07-13 16:48:21.879 +03:00] [INF] Filtered subnets: [] ... [2024-07-13 16:48:24.162 +03:00] [INF] Found ffmpeg version "6.0.1" [2024-07-13 16:48:24.199 +03:00] [INF] Available "decoders": ["libdav1d", "av1", "av1_cuvid", "av1_qsv", "h264", "h264_qsv", "h264_cuvid", "hevc", "hevc_qsv", "hevc_cuvid", "mpeg2video", "mpeg2_qsv", "mpeg2_cuvid", "mpeg4", "mpeg4_cuvid", "msmpeg4", "vc1_qsv", "vc1_cuvid", "vp8", "libvpx", "vp8_cuvid", "vp8_qsv", "vp9", "libvpx-vp9", "vp9_cuvid", "vp9_qsv", "aac", "ac3", "dca", "flac", "mp3", "truehd"] [2024-07-13 16:48:24.219 +03:00] [INF] Available "encoders": ["av1_nvenc", "av1_qsv", "av1_amf", "av1_vaapi", "libx264", "h264_amf", "h264_nvenc", "h264_qsv", "h264_v4l2m2m", "h264_vaapi", "libx265", "hevc_amf", "hevc_nvenc", "hevc_qsv", "hevc_vaapi", "mjpeg_qsv", "mjpeg_vaapi", "mpeg4", "msmpeg4", "libvpx", "libvpx-vp9", "aac", "ac3", "alac", "dca", "flac", "libmp3lame", "libopus", "truehd", "libvorbis", "srt"] [2024-07-13 16:48:24.239 +03:00] [INF] Available filters: ["deinterlace_qsv", "deinterlace_vaapi", "hwupload_cuda", "hwupload_vaapi", "libplacebo", "overlay_opencl", "overlay_qsv", "overlay_vaapi", "overlay_vulkan", "overlay_cuda", "procamp_vaapi", "scale_cuda", "scale_opencl", "scale_qsv", "scale_vaapi", "scale_vulkan", "tonemap_cuda", "tonemap_opencl", "tonemap_vaapi", "vpp_qsv", "yadif_cuda", "zscale", "alphasrc"] [2024-07-13 16:48:24.366 +03:00] [INF] Available hwaccel types: ["vdpau", "cuda", "vaapi", "qsv", "drm", "opencl", "vulkan"] [2024-07-13 16:48:24.469 +03:00] [INF] FFmpeg: "/usr/lib/jellyfin-ffmpeg/ffmpeg" [2024-07-13 16:48:24.469 +03:00] [INF] ServerId: "e70988f8858042ccb7d9e8afbb7cf08e" [2024-07-13 16:48:24.469 +03:00] [INF] Core startup complete [2024-07-13 16:48:24.469 +03:00] [INF] Startup complete 0:00:02.8630776 [2024-07-13 16:48:27.141 +03:00] [INF] "Clean up collections and playlists" Completed after 0 minute(s) and 0 seconds [2024-07-13 16:48:29.349 +03:00] [INF] "Update Plugins" Completed after 0 minute(s) and 2 seconds [2024-07-13 16:49:18.742 +03:00] [INF] Saving system configuration [2024-07-13 16:49:18.743 +03:00] [INF] Setting cache path: "/var/cache/jellyfin" [2024-07-13 16:49:18.744 +03:00] [INF] Stopping NAT discovery [2024-07-13 16:49:18.768 +03:00] [WRN] No users, creating one with username "jellyfin" [2024-07-13 16:51:35.890 +03:00] [INF] Saving system configuration [2024-07-13 16:51:35.890 +03:00] [INF] Setting cache path: "/var/cache/jellyfin" [2024-07-13 16:51:50.480 +03:00] [INF] Defined LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"] [2024-07-13 16:51:50.480 +03:00] [INF] Defined LAN exclusions: [] [2024-07-13 16:51:50.480 +03:00] [INF] Used LAN subnets: ["127.0.0.1/8", "10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16"] [2024-07-13 16:51:50.480 +03:00] [INF] Filtered interface addresses: ["127.0.0.1", "192.168.8.139", "172.16.238.1", "192.168.52.1"] [2024-07-13 16:51:50.480 +03:00] [INF] Bind Addresses ["0.0.0.0"] [2024-07-13 16:51:50.480 +03:00] [INF] Remote IP filter is "Allowlist" [2024-07-13 16:51:50.480 +03:00] [INF] Filtered subnets: [] [2024-07-13 16:51:51.772 +03:00] [INF] Saving system configuration [2024-07-13 16:51:51.773 +03:00] [INF] Setting cache path: "/var/cache/jellyfin" [2024-07-13 16:51:51.774 +03:00] [INF] Stopping NAT discovery [2024-07-13 16:51:51.775 +03:00] [INF] Validating media library [2024-07-13 16:51:52.026 +03:00] [WRN] Library folder "/var/lib/jellyfin/data/playlists" is inaccessible or empty, skipping [2024-07-13 16:51:52.145 +03:00] [WRN] Library folder "/var/lib/jellyfin/data/playlists" is inaccessible or empty, skipping ... ``` ### FFmpeg logs _No response_ ### Please attach any browser or client logs here _No response_ ### Please attach any screenshots here ![image](https://github.com/user-attachments/assets/092820e9-f2a7-45e7-89b6-09846e53f6c0) ### Code of Conduct - [X] I agree to follow this project's Code of Conduct
OVERLORD added the invalid label 2026-02-07 03:05:49 +03:00
Author
Owner

@jellyfin-bot commented on GitHub (Jul 13, 2024):

Hi, it seems like your issue report has the following item(s) that need to be addressed:

  • You have not filled in the environment completely.

This is an automated message, currently under testing. Please file an issue here if you encounter any problems.

@jellyfin-bot commented on GitHub (Jul 13, 2024): Hi, it seems like your issue report has the following item(s) that need to be addressed: - You have not filled in the environment completely. This is an automated message, currently under testing. Please file an issue [here](https://github.com/jellyfin/jellyfin-triage-scripts/issues) if you encounter any problems.
Author
Owner

@felix920506 commented on GitHub (Jul 13, 2024):

Ffmpeg path should be set using the CLI option not encoding.xml

@felix920506 commented on GitHub (Jul 13, 2024): Ffmpeg path should be set using the CLI option not encoding.xml
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/jellyfin#6115