I am using radarr to download movies and upgrade them to better quality if available and trigger a library scan after download
I use the quality tag in the filenames, so that means a movie like:
The Movie (2019)/the.movie.2019.1080p-webdl.mkv
will be upgraded to bluray with a new filename:
The Movie (2019)/the.movie.2019.1080p-bluray.mkv
the problem with plex is, that sometimes it will delete the movie from the plex library and re-add it as new to the recently added with a new item id
how can I prevent this?
what is really weird is, that it is not happening all the time, sometimes the id stays the same and plex updates the filename just fine
shouldn’t this be the default behavior, like if it’s a multi version movie? https://support.plex.tv/articles/200381043-multi-version-movies/
(although it differs from the official plex naming convention)
I’ve tried it with and without the automatic trash cleanup and it stays the same
the “Empty trash automatically after every scan” was disabled and
the file: “The Movie (2019)/the.movie.2019.1080p-webdl.mkv”
was upgraded with a new filename: “The Movie (2019)/the.movie.2019.1080p-bluray.mkv”
this is ‘normal’ behavior when auto trash cleanup is disabled, you have to manually ‘empty trash’.
I believe radarr deletes the original file before it moves the new one.
when auto empty trash is enabled, it depends on how quickly your server/plex process the deletion then addition, sometimes plex see the deletion and clear it before the whole new file gets put in place and scanned.
yes, that’s the normal behaviour and I am not complaining about the trash feature
but what is not normal (imho) is that I get a new library item with the exact same movie
yes radarr deletes the file prior to the move
but it triggers the plex library scan after the move
and plex is set to never automatically search any library
so the scan will definitely not happen before the new file is in the destination folder
I checked that
so even with auto empty trash enabled this should not happen imho
and I even get a new movie item if I add a second version of a movie manually to the same folder where the current file resides and I have to manually merge them
I changed the file path manually, with the following information: the media_parts table is where the media_item_id and the path to the the actual file is stored.
the media_item_id is linked in the media_items table with the metadata_items id which is the movie item you see in the dashboard
the only other thing I can think of is that you changed the metadata provider for those titles.
For example, if the movie was originally scanned with ‘plex movie’ but is now configured for ‘the movie db’, then the new movie will be detected as new with a new database id.
the really ironic part for me, is would PREFER the behavior of seeing upgraded content in recently added.
Or at least I wish there was a ‘recently modified’ hub.
that is a very good hint indeed, I did change the provider once
that could explain a lot
I will test that
yes but, actually no
it would be fine if the ID would stay the same
but with a new ID it just f*cks up all the other services like tautulli, tracktarr, ombi, …
and for a lot of movies I have a bluray or web version with a 2.0 stereo german audio track
and I’ve set radarr to upgrade to 5.1 or 7.1 if available
but I don’t care to see that as newly added, cause, in reality, it is not
and someone might have already watched it and now it would be set to unwatched
yes, already thought about that and instead of triggering a scan within radarr, have a post proc. script to recover the file from trash, trigger a scan, remove the file, rescan
but that just feels so dirty^^ and there is no warranty that it would work, because:
unfortunately, that would not work
I already tried that manually
I’ve added another version of the same movie to the existing folder and got a new item in my library and I merged them afterwards
but that might also be related to the provider change (? don’t know, I will test that again)
I originally added the library with plex movie as metadata agent and changed to themoviedb somewhere along the road
I just tested it again and fixed the match on the new movie with the plex movie agent and boom, it combined them and kept the old ID
looks like this could even fix the upgrade issue and might also explain why it sometimes works (I guess for movies which where already added with themoviedb agent)
I will test that again but it looks very promising
re- I would expect refresh all metadata to work, but I would still shutdown plex, make a backup copy of both the database and the metadata folders (metadata can take a while to copy, zillions of small files/folders).
ok, I was just asking because I already did that when I moved the server from FreeNAS to Ubuntu
I only moved the DB and refreshed all metadata
so either there was an issue or I need to configure something I’m not aware of or it does not work
yep it worked
the metadata agent was the troublemaker
I changed the librarys agent back to plex movie and it swapped the file and kept the ID
even with auto trash removal activated
awesome
finally… this was giving me headache already^^