• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting SOLVED: Cannot scan music library: Could not find file

     
    • 0 Vote(s) - 0 Average

    SOLVED: Cannot scan music library: Could not find file

    Cannot scan music library: Could not find file
    hanaquacks
    Offline

    Junior Member

    Posts: 27
    Threads: 7
    Joined: 2023 Sep
    Reputation: 0
    Country:United States
    #1
    Yesterday, 01:43 PM
    Hello,

    I'm having difficulty since a sort of snafu occurred. Last week I had new media in the music library. I ended up not being a fan of the album in question, so I deleted it (in this case from the Delete Media option). It hung for a while and then appeared to have finished. However, now there was a "ghost" album in the library. The entry still exists, along with all it's metadata, except the album art appears corrupted (visually speaking). Any further attempts to delete the album were met with "There was an error, please be sure you have write access to this folder".

    At the time, I just let it go, until recently when I realized that any new media I added would fail to be scanned. This does not apply to other libraries, new media in say Movies will show up fine. Only in Music will it fail to add new media. Scan will immediately fail, no indication from within the Dashboard that it is scanning the library.

    The logs produce this:


    [2025-11-13 07:55:04.917 -05:00] [ERR] Error processing request: "Could not find file '/var/lib/jellyfin/root/default/Music/poster.jpg'". URL "GET" "/Items/7e64e319657a9516ec78490da03edccb/Images/Primary".
    [2025-11-13 07:55:09.575 -05:00] [WRN] Image not found at "/var/lib/jellyfin/root/default/Music/poster.jpg"
    [2025-11-13 07:55:11.464 -05:00] [WRN] Image not found at "/var/lib/jellyfin/metadata/library/26/26edeeff62d548b11622579bb64eaf86/backdrop.jpg"
    [2025-11-13 07:55:11.464 -05:00] [WRN] Image not found at "/var/lib/jellyfin/metadata/library/26/26edeeff62d548b11622579bb64eaf86/logo.png"
    [2025-11-13 07:55:11.464 -05:00] [WRN] Image not found at "/var/lib/jellyfin/metadata/library/26/26edeeff62d548b11622579bb64eaf86/folder.jpg"

    They are indeed missing. I keep a duplicati backup of the jellyfin folder, but I only keep 3 iterations and unfortunately due to my waiting, all 3 are after the delete media event. There are what appear to be older backups in /var/lib/jellyfin/data, but I'm not sure how to properly implement them as there are files like library.db.bak1, 2, 3, 4. But, then I'd expect to see a library.db, but I only see files like library.db.old or library.db-wal.

    I'm on JF 10.11.0 as current version. All running on an ubuntu server. Jellyfin is not dockerized, runs bare metal.

    I have minor experience with SQL, so I'd be willing to make changes if that was the only recourse, but I am not knowledgeable enough beyond a script-kiddie sort of level, so obviously I'd prefer other options.

    I'd also like to add that I received another error last night.

    [2025-11-12 19:23:37.304 -05:00] [ERR] An exception occurred while executing an 'ExecuteUpdate' operation for context type '"Jellyfin.Database.Implementations.JellyfinDbContext"'."
    ""Microsoft.Data.Sqlite.SqliteException (0x80004005): SQLite Error 19: 'UNIQUE constraint failed: UserData.ItemId, UserData.UserId, UserData.CustomDataKey'.

    Logs: https://pastebin.com/qUYAANTS
    https://pastebin.com/wDmL4Es4
    Go to solution
    hanaquacks
    Offline

    Junior Member

    Posts: 27
    Threads: 7
    Joined: 2023 Sep
    Reputation: 0
    Country:United States
    #2
    Yesterday, 06:32 PM
    I cleared out the image errors and I'm left with the SQL errors. I've tried rebuilding or creating new libraries, but it's always the same error.
    hanaquacks
    Offline

    Junior Member

    Posts: 27
    Threads: 7
    Joined: 2023 Sep
    Reputation: 0
    Country:United States
    #3
    Today, 03:25 AM
    Rather than delete, I'm going to update, I fixed this issue.

    This all started when I deleted this album, can't remember if I deleted from the NAS or from the JF server, but I must have done it poorly.

    At any rate, I started to think, maybe it just needs the files back in there. But, I didn't want to create the album again for real, so I just created the folder in the same path and then using the "ghost" entry in the folder, I carefully recreated all the files with touch aka sudo touch "01 - title.flac" and once done, it scanned properly, then I deleted and all works once more.
    Cyro1
    Offline

    Junior Member

    Posts: 1
    Threads: 0
    Joined: 2025 Nov
    Reputation: 0
    Country:United Kingdom
    #4
    2 hours ago
    (Today, 03:25 AM)hanaquacks Wrote: Rather than delete, I'm going to update, I fixed this issue.

    This all started when I deleted this album, can't remember if I deleted from the NAS or from the JF server, but I must have done it poorly.

    At any rate, I started to think, maybe it just needs the files back in there. But, I didn't want to create the album again for real, so I just created the folder in the same path and then using the "ghost" entry in the folder, I carefully recreated all the files with touch aka sudo touch "01 - title.flac" and once done, it scanned properly, then I deleted and all works once more.

    Hey, just wanted to say thank you so much for updating the post with your solution - I ended up having a virtually identical issue happen to me, I did the same thing you did and it worked. Thank you!
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode