2 hours ago
hey all,
this morning updated my jellyfin instance using 'apt', pulling the most recent update from the 'https://repo.jellyfin.org/ubuntu jammy' repo. after updating my web interface would no longer work, so I started digging.
here's my system details:
looks like the most recent update broke things in two different ways... the first way was what appears to be a well known old bug, where the newly-installed config(?) references /usr/lib/jellyfin/bin/jellyfin-web (which does not exist) instead of /usr/share/jellyfin/web (which does exist).
after creating a symlink to redirect to the real directory (sudo ln -s /usr/share/jellyfin/web /usr/lib/jellyfin/bin/jellyfin-web), the server at least tried to start, but now it is failing because apparently a migration process is trying to do something and crashing...?
(I know, I know. I don't even really like Coldplay.)
the jellyfin user does have read access to that directory and to that specific .M3U file (I even tested to be sure), but it does not have write access which made me a little suspicious; I don't see any reason for a mediaserver to have unsupervised write access to the media files. I'm willing to hear reasoning though.
testing by removing that file completely from the media collection makes no difference; the server still crashes with the same message, despite (or because of?) the fact that there's no file there anymore. seems like the sort of thing that should fail gracefully instead of throwing a system exception.
thoughts?
this morning updated my jellyfin instance using 'apt', pulling the most recent update from the 'https://repo.jellyfin.org/ubuntu jammy' repo. after updating my web interface would no longer work, so I started digging.
here's my system details:
Code:
Distributor ID: Ubuntu
Description: Ubuntu 24.04.1 LTS
Release: 24.04
Codename: noble
Linux xwing 6.8.0-44-generic #44-Ubuntu SMP PREEMPT_DYNAMIC Tue Aug 13 13:35:26 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Package: jellyfin
Version: 10.10.2+ubu2204
looks like the most recent update broke things in two different ways... the first way was what appears to be a well known old bug, where the newly-installed config(?) references /usr/lib/jellyfin/bin/jellyfin-web (which does not exist) instead of /usr/share/jellyfin/web (which does exist).
after creating a symlink to redirect to the real directory (sudo ln -s /usr/share/jellyfin/web /usr/lib/jellyfin/bin/jellyfin-web), the server at least tried to start, but now it is failing because apparently a migration process is trying to do something and crashing...?
Code:
[2024-11-17 10:32:04.020 +13:00] [INF] Loaded plugin: "TMDb" "10.10.2.0"
[2024-11-17 10:32:04.021 +13:00] [INF] Loaded plugin: "Studio Images" "10.10.2.0"
[2024-11-17 10:32:04.022 +13:00] [INF] Loaded plugin: "OMDb" "10.10.2.0"
[2024-11-17 10:32:04.062 +13:00] [INF] Loaded plugin: "MusicBrainz" "10.10.2.0"
[2024-11-17 10:32:04.063 +13:00] [INF] Loaded plugin: "AudioDB" "10.10.2.0"
[2024-11-17 10:32:04.118 +13:00] [INF] Applying migration '"RemoveDuplicatePlaylistChildren"'
[2024-11-17 10:32:04.558 +13:00] [ERR] Could not apply migration '"RemoveDuplicatePlaylistChildren"'
System.UnauthorizedAccessException: Access to the path '/media/MEDIA/Audio/INCOMING/Coldplay - Essentials (2024) [FLAC] 88/Coldplay - Essentials.m3u' is denied.
---> System.IO.IOException: Permission denied
--- End of inner exception stack trace ---
at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirError)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, UnixFileMode openPermissions, Int64& fileLength, UnixFileMode& filePermissions, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at System.IO.File.OpenHandle(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.File.WriteToFile(String path, FileMode mode, String contents, Encoding encoding)
at Emby.Server.Implementations.Playlists.PlaylistManager.SavePlaylistFile(Playlist item)
at Jellyfin.Server.Migrations.Routines.RemoveDuplicatePlaylistChildren.Perform()
at Jellyfin.Server.Migrations.MigrationRunner.PerformMigrations(IMigrationRoutine[] migrations, MigrationOptions migrationOptions, Action`1 saveConfiguration, ILogger logger)
[2024-11-17 10:32:04.563 +13:00] [FTL] Error while starting server
System.UnauthorizedAccessException: Access to the path '/media/MEDIA/Audio/INCOMING/Coldplay - Essentials (2024) [FLAC] 88/Coldplay - Essentials.m3u' is denied.
---> System.IO.IOException: Permission denied
--- End of inner exception stack trace ---
at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirError)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, UnixFileMode openPermissions, Int64& fileLength, UnixFileMode& filePermissions, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at System.IO.File.OpenHandle(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.File.WriteToFile(String path, FileMode mode, String contents, Encoding encoding)
at Emby.Server.Implementations.Playlists.PlaylistManager.SavePlaylistFile(Playlist item)
at Jellyfin.Server.Migrations.Routines.RemoveDuplicatePlaylistChildren.Perform()
at Jellyfin.Server.Migrations.MigrationRunner.PerformMigrations(IMigrationRoutine[] migrations, MigrationOptions migrationOptions, Action`1 saveConfiguration, ILogger logger)
at Jellyfin.Server.Migrations.MigrationRunner.Run(CoreAppHost host, ILoggerFactory loggerFactory)
at Jellyfin.Server.Program.StartServer(IServerApplicationPaths appPaths, StartupOptions options, IConfiguration startupConfig)
[2024-11-17 10:32:04.563 +13:00] [INF] Running query planner optimizations in the database... This might take a while
[2024-11-17 10:32:04.586 +13:00] [INF] Disposing "CoreAppHost"
[2024-11-17 10:32:04.586 +13:00] [INF] Disposing "MusicBrainzArtistProvider"
[2024-11-17 10:32:04.586 +13:00] [INF] Disposing "MusicBrainzAlbumProvider"
[2024-11-17 10:32:04.587 +13:00] [INF] Disposing "PluginManager"
(I know, I know. I don't even really like Coldplay.)
the jellyfin user does have read access to that directory and to that specific .M3U file (I even tested to be sure), but it does not have write access which made me a little suspicious; I don't see any reason for a mediaserver to have unsupervised write access to the media files. I'm willing to hear reasoning though.
testing by removing that file completely from the media collection makes no difference; the server still crashes with the same message, despite (or because of?) the fact that there's no file there anymore. seems like the sort of thing that should fail gracefully instead of throwing a system exception.
thoughts?