Server Version#: 1.19.2.2673 (and many prior versions)
Player Version#: all (or n/a)
Several months ago I bought a couple larger drives and rearranged the folders for my Movies library to consolidate the movies on the new drives. This required me to remove the old Movies library and create a new one (due to some other annoying Plex issues.)
I thought all was well, but I have started noticing that some of the movies in the library’s folders are not listed. I tried moving the movie file out of the folder, restarting PMS, scanning the movies library and then adding the movie file back to the library folder after the scan completed. Then run a new scan and the movie is still ignored.
I downloaded and searched the logs for the movie file name and it is not there. Not at all. I would at least expect a validly named media file that could not be added to be logged as that seems to be of rather significant interest. But it appears that Plex simply cannot see the file “M:\Movies-X\X-Men (2000).mp4” for no apparent reason.
FWIW, VLC will play the file just fine, so I know it is present and valid. It is just invisible to Plex.
I think doing a repair on my database might be necessary, but the instructions include a frighteningly specific code number that sounds like it may be version-specific (i.e. where version='20180501000000') and I do not want to blindly run something that might not match my current version of the software – I’ve been bit by following non-updated instructions before. With no explanation of what the magic number means, I cannot trust that it is valid for every possible version of PMS, can I?
PS: To the web site designers/maintainers: The formatting for the page sucks. I made the window a full 3840 pixels wide in the hope that I could see the sqlite3 commands without the damn scroll bars, but instead of the content getting wider, the stupid EMPTY MARGINS got extremely wide instead (using the current Chrome Version 81.0.4044.113 (Official Build) (64-bit)). Excessively wide margins are NEVER necessary, please ask your web folks consider allowing the USEFUL CONTENT to fill the browser window instead!
Yes, you can. It has to do with a particular index table, which is incompatible with the currently available SQLite command line tools. So it has to be removed before a repair is possible.
It is getting recreated automatically, once the Plex server is started with the repaired database for the first time.
Consider the possibility that the file is indeed seen by Plex, but got mismatched as a different version of an existing movie. This could be caused by embedded meta tags in the mp4 file for instance.
Make sure that your files either contain no metadata or only 100% correct ones. (Or lower the line ‘Local Media Assets’ in Agents settings.)
Sometimes, the folder name can be an issue as well. If you added simply the drive letter X: to the movie library (instead of X:\Movies-X), Plex is by default considering the folder’s name Movies-X as a hint for matching the file(s) inside. Which then in this case can skew the heuristics significantly.
OK, assume the file is seen by Plex and matched with an existing movie. It that a valid reason for Plex to have logged absolutely nothing about the movie in any log file? The log files in my applications exist to record precisely that sort of information and I have trouble believe Plex has a special exception for this case.
Also, if the movie is being mismatched and merged with another movie, how would I find that, since the file name is not being logged?
Finally, this is just one example of an unknown number of movies that no longer appear within Plex, but are still on the file system. I stopped looking after finding several because I wanted to find a solution to the problem before wasting my time manually searching for everything.
Is ‘debug’ logging activated on the server?
Scanning only one library as opposed to all libraries makes it easier to find relevant stuff. Your best bet are the Plex Media Scanner.log files. They should at least contain a line that says something like: “Nothing has changed in M:\Movies-X, skipping folder”.
Your best bet would be to use ExportTools and then filter this for the file name(s) in question.
If the file names are present, you can assume that the file is seen by Plex but was mismatched.
If the file names are not present, they might indeed have been ignored, caused by either their file names, their access permissions or by some forgotten .plexignore file.
I checked the agents settings and they were as you suggest they should be.
So I tried removing the file, scanning the library, and then restoring the file. This time I caught something re-appearing: The name named (“X-Men (2000).mp4” with only the title metadata set to “X-Men”) was matched to “Men of Honor (2000)”
When I tried ‘Fix Match’ I found that the correct (EXACT) title/year item was shown as a 25% match in the list of results! And here’s what it showed it as searching for:
Ever so slightly different behavior after plex dance:
Instead of initially showing the file name (X-Men) while it searched for a match, the movie first appeared this time as Men of Honor.
Also, FWIW, I checked EVERY server panel (with Advanced shown) and found no Empty Trash function. But I did find a checkbox labeled ‘Empty trash automatically after every scan’ and it is checked.
This really, really appears to be something from the match agent side, side it says that “Men of Honor” is a 90% match to “X-Men” while “X-Men” is only a 24% match. However you slice it, that is just plain wrong and I don’t think that info is generated on the PMS side of the match/search, is it?
I exited from PMS (though this was not mentioned in the cache clearing instructions I thought it would be a good idea), then renamed the Plex Media Server\Plug-in Support\Caches folder, then created a new, empty Caches folder, then restarted PMS.
When PMS was running again, I moved X-Men out of the folder and scanned library files, I cleaned bundles, I moved the file back into the folder and scanned the library again.
Looks like you’re not doing the dance right so it’s just reusing old info.
Apr 24, 2020 15:58:26.788 [13512] DEBUG - Looking for path match for [M:\Movies-X\X-Men (2000).mp4]
Apr 24, 2020 15:58:26.792 [13512] DEBUG - Path matched, we’re reusing media item 451571
Huh. Not directly related to your issue but:
Apr 24, 2020 15:58:15.947 [13512] DEBUG - Scanning Movies using en(Plex Movie Scanner) with 2552 current media items and 27 section locations in the database…
Is your library pointing pointing to the 27 folder your have individually. You should create a “Movies” folder in the root, move your alphabet folders to it, then point your library to the “Movies” folder.
Well, I followed every possible step in the Plex Dance as it was listed. As I said earlier, there is no way I can find to “Empty Trash” (though I remember seeing that in the past) and there is a setting called Empty trash automatically after every scan that is checked.
If I did something wrong, then it must have been omitted from the dance steps at the link Otto provided.
And yes, my library was original scattered over more than a dozen folders on six different drives before I reorganized into one drive with a folder for the first letter (or digit) of the movie titles. Nothing I have seen says that I can have sub-folders within a library, except when they are the same title as the movie they contain. You are telling me that is incorrect and I can have at least one extra level of ‘generic’ folders with multiple different movies per folder within the library folder? Just so I can learn this better, could you provide a link to where that is documented – maybe it has changed since I learned about it a couple years ago or else it wasn’t clear to me back then.
I managed to find the Empty Trash command. I was looking at the PMS level (like the Clean Bundles command) but the trash is emptied at the Library level instead.
Regardless, the movie still re-appears as Men of Honor.
Also, since I have the PMS set to empty trash after every scan, shouldn’t that be the same as manually emptying the trash after the scan completes? If not, what is the difference and why do the functions have the same name (‘Empty Trash’)?
Yes, those should do the same thing. I’m not sure where the problem is but something is telling PMS that the entry still exists. After moving the file out and doing a scan, did you check that “men of honor” was removed from the library?
[MovieFan.Plex] While the scan was running (after moving the file out) I had the movie library open in the Plex Web Client, sorted with the most recently added at the top. Men of Honor was the very first movie in the list and does not show multiple copies. During the scan, it disappears and some time after that the scan finally completes (based on the activity icon in the upper right.)
To the best of my limited knowledge, that means that the one and only instance of Men of Honor had been removed from the library.
[Otto] No. This is the only copy of the file I have.
Out of curiosity, if it was a renamed copy (for example, as “X-Men (2000) - spare copy.mp4”) why would that be a reason for it to match a totally different movie title? Remembering that the meta-data within the file would still be exactly the same in the copy.
[To all] At this point, I’m just wondering if there is any way to find all of the other movies that have been mismatched in this way without looking at the 'Get Info" for every individual movie to see if the movie’s file name resembles the matched title. Is it possible to do some sort of sqlite3 query to get the title, year, and file name to a text or CSV file? Then I could use other tools to search for mismatches much more quickly and easily.