Deleted content still displaying in library

From time to time I am finding the server isn’t cleaning up automatically. I have everything set to automatic, the refreshes and update interval is set to 15 min.

But still I will delete things and every once and awhile they’ll still show up in my library but are listed as Unavailable (clearly because the files are deleted) .

I’ve found if I remove the folder(s), save, re add the folder the library will then update correctly but I’m not sure why I have to do that in some instances.

Is there something I am missing. Is there a specific way I should be deleting files to avoid this little issue?

Try optimizing the library
Click on “…” and then Optimize Library

Nope. Still there. When I said the only workaround is removing, save, re-adding I meant the only work around is…

Plex does not like empty source folders. If you need to use source folders that will not contain content at certain times, then you can place a dummy text file in that location. Plex shouldn’t pick it up and add to the library. This should allow you to remove all media from that location and Plex will perform as expected.

Why does content I deleted on my drive still show up?

There are (and were) other files in the folder. Say I have 4 files. I deleted 2. 3 still show in the library (1 unplayable…). Once I manually refresh it’s ok but not before.

Ok, so it’s not the empty folder issue. I don’t use the automatic library update features as I used to store my media on a NAS and got used to doing things manually, and I continue to do so. I wouldn’t think a 15 minute update time is too short, but have you tried increasing it to say, one hour.

I had to clear out the stragglers but next time I get a few I will change the interval and write back.

Finished watching a movie, deleted the file. Still showing up in library. Change update interval to 30 min @ 2:46 pm. Will write back.

Do you have Empty Trash Automatically after every scan ticked within Settings / Server / Library ?

Checked @ 3:27 PM still there.

Update interval of 30min will rescan after 1 hour. I don’t know why but plex doubles the time set.

@sa2000 said:
Do you have Empty Trash Automatically after every scan ticked within Settings / Server / Library ?

Sorry I read the prompt wrong, yes it’s checked, no it does not resolve my issue.

Can you by any chance remove my answer. My fault I know but I don’t want to mislead.

@AgentMax said:
Update interval of 30min will rescan after 1 hour. I don’t know why but plex doubles the time set.

https://forums.plex.tv/discussion/206979/time-for-library-update-is-not-completely-ignored#latest

Been over an hour still there.

I’m realizing that it’s only libraries marked Movies where physically deleted content isn’t getting removed from the library automatically. Any ideas?

I would suggest you get some diagnostic logs from a controlled test session - attaching logs and screenshots.

So Enable Debug Logging on the server and restart the server to get fresh logs created (this is important)
See https://support.plex.tv/hc/en-us/articles/201643703-Reporting-issues-with-Plex-Media-Server
After restart of the server do not do any activity on the server other than the activity below to get the diagnostics for this problem

Get a Screenshot of Library Advanced Settings screen
Get a Screenshot of the movies library showing the movie that you will be deleting
Identify the movie you are deleting
Delete the movie that you wish to use for showing the problem

Do a Library Update (See https://support.plex.tv/hc/en-us/articles/200289306-Update-or-Refresh-a-Library) which should detect the removal of the movie files/folders
At the end of the library get a screenshot showing the movie not removed and Zip all log files with names starting Plex Media Server and Plex Media Scanner and attach here together with the screenshots
See https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files

Then Select the movie library and click on the cog-wheel (top right side) and in the drop-down, select Empty Trash and confirm the request. See if this make the deleted movies disappear.
Get a screenshot and zip the log files again and attach this set as well

This is happening to me as well. You are not alone. I’ve deleted folders off my computer completely and Plex still displays the tv show even though there is nothing to pull from. Get an error when I click on it. I tried everything above and nothing. I found that if I click on Settings…Server…Library and then click on “allow media deletion” I can then go in and manually delete all the shows that no longer exist. You would think that Plex would do that for you when it refreshes but it stopped doing that after one of the previous Plex updates. Hope this helps. Lets hope others speak up and this problem gets fixed on the next update.

I wanted to update what I just found from reading elsewhere. I fixed my problem. If you have all your movies stored under one folder then make sure your library is only linked to that folder. For example say you have all your movies stored in your computer under a folder called “movies”. Select the home button in Plex at the top and then in the list under “libraries” highlight movies. Click the edit button and then add folders. Make sure all the links associated with your movies are there and nothing else. I had an extra file in there and it was messing it up. Once I deleted the link that shouldn’t have been there everything started updating correctly. This worked for me and I hope it helps for you.

@schaegy To clarify, you had Plex looking at a library location that was non existent and this was preventing the removal of items (in other locations) from the Plex database?

@sa2000 Sorry I’ve been away for awhile but here you go. I’ve also learned that this only affects movies. No matter what or how I delete TV Plex updates the library properly. No matter how I deleted movies from a folder or the folder itself if I do not manually remove it from the library it always says unavailable.






Looking at the server log it is indicating that your library media paths are set at the movie file level rather than a parent folder like D:\Movies
Also you are using download folders as paths - it is best especially when auto updating is enabled - to specify paths that you do not download into. So at end of downloads then you move the files to the proper library paths

The recommended folder structure is given on this support page
https://support.plex.tv/hc/en-us/articles/200381023-Naming-Movie-files
More support pages for movies here
https://support.plex.tv/hc/en-us/sections/200098856-Naming-your-Movie-media-files

I would recommend you adopt the standards shown first and then we investigate any issues that you may encounter

The xml from this request would show the library paths you have specified
http://localhost:32400/library/sections

Switch to the movies library having paths such as
X:\Movies
Z:\Movies

and TV Shows Library
S:\TV Shows
P:\TV Shows

These are just examples
and below these library paths have your media folder structure as per the guidelines
https://support.plex.tv/hc/en-us/categories/200028098-Media-Preparation

I need to see the scanner log after the a deletion - may be the issue is that there are loads of changes because you are defining the downloads folders as media paths and may be some limits are being reached because you have many paths - i am guessing here
The logs show these scan jobs for the Movies and TV Shows libraries

Mar 30, 2016 17:12:16:907 [6928] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 9 
Mar 30, 2016 17:12:34:036 [8040] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 10 
Mar 30, 2016 17:42:16:933 [1180] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 9 
Mar 30, 2016 17:42:38:976 [1460] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 10 
Mar 30, 2016 18:12:16:957 [0584] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 9 
Mar 30, 2016 18:12:38:782 [7376] DEBUG - "C:\Program Files (x86)\Plex\Plex Media Server\Plex Media Scanner.exe" --scan --refresh --section 10 

When was the deletion and we can concentrate on one - so probably this needs a controlled test - but tidy up your folder structures and paths first

The scanner log should have entry like this
DEBUG - Deleting media item xxx for any deleted media - i cannot see any of that

Also your logs show that you are getting crashes - it is better to investigate and eliminate those before looking into issues as crashing processes may lead to indeterminate results

Mar 30, 2016 13:41:21:972 [1804] DEBUG - Crash Reporter: Uploading crash report C:\Users\Cwluc\AppData\Local\Plex Media Server\Crash Reports\processing_5944\35cb1916-d0ca-46b1-82f7-2ca2d7be4c04.dmp

These crash dmp files get purged on restart and so would need to be captured and copied out of folder
C:\Users\Cwluc\AppData\Local\Plex Media Server\Crash Reports\ before restarting the server- together with the logs. dmp files need to be zipped to upload here

I had same problem and sorted it using this thread. My problem was that I had inadvertently mapped my NAS twice some time ago on my MAC and a couple of the movies were copied across to the NAS using the second mapping. I tidied up my machine and removed the additional mapping but I had both directory structures in my library still. When I delete the movie from the NAS the library couldn’t update presumably because it could no longer find the directory that the movies were supposed to be in because they were copied using the one I had since removed. Once I removed the 2nd older from the library it refreshed properly. Would be better if PLEX gave an error message or warning if it can’t find a particular file when refreshing or emptying trash.