Lost a whole load of movies / TV shows this morning

So here’s a side-by-side of a window I happened to still have open from last night (on the left) and a window freshly-opened this morning (on the right):


I spent some time copying DVDs into Plex yesterday, and this morning none of them are there - note the totals (168 vs 105) at the top.

Also weird, even poster images (eg: “Changing Lanes”) have changed back to older versions, it’s as if the database being used is an older one.

I’ve restarted the server, I’ve tried rescanning the library (didn’t work for TV shows, where I’ve lost about 4 “seasons” of Blackadder) but I’m trying it anyway on the Movies. It’s taking a long time and it’s ongoing as I type…

Any hints ? I really don’t want to have to re-digitise the crate of movie DVDs by my desk waiting to go back into the attic…

Something may have caused Plex to remove items from the library, but Plex does not delete media files from the hard drive (unless you configure it to allow deletion, and then only on your explicit action). Have you looked to make sure the files are still there?

Since some posters changed, it makes me think that it did a metadata refresh, and for some reason found different things than before. That may take more expertise than I have, so hopefully someone will jump in.

The files are still there [phew!] , but a rescan doesn’t seem to recapture them (at least, not yet, the library scan is still ongoing).

check your folder/file permissions.

Let it finish and see. If it fails, make sure the permissions are right. This is unlikely to be the problem, I think, or they never would have been found in the first place, but it’s about all I’ve got.
https://support.plex.tv/articles/200288596-linux-permissions-guide/

Its not permissions - I’m pretty good at doing a “chown -R plex:plex *” whenever I add something, just to make sure. And it was fine with them yesterday, it even made optimized versions of the (now missing) TV series:

ls -l optimised/Plex\ Versions/Optimized\ for\ Mobile/Blackadder/
total 16199668
-rw-r--r--. 1 plex plex 833032180 Jul 22 08:01 S01E01.mp4
-rw-r--r--. 1 plex plex 863550120 Jul 22 08:03 S01E02.mp4
-rw-r--r--. 1 plex plex 892601515 Jul 22 08:06 S01E03.mp4
-rw-r--r--. 1 plex plex 845310690 Jul 22 08:08 S01E04.mp4
-rw-r--r--. 1 plex plex 811497947 Jul 22 08:10 S01E05.mp4
-rw-r--r--. 1 plex plex 900706105 Jul 22 08:12 S01E06.mp4
-rw-r--r--. 1 plex plex 603981732 Jul 31 15:48 S02E01.mp4
-rw-r--r--. 1 plex plex 489886802 Jul 31 15:49 S02E02.mp4
-rw-r--r--. 1 plex plex 541587599 Jul 31 15:51 S02E03.mp4
-rw-r--r--. 1 plex plex 587036704 Jul 31 15:54 S02E04.mp4
-rw-r--r--. 1 plex plex 518315151 Jul 31 15:56 S02E05.mp4
-rw-r--r--. 1 plex plex 493439241 Jul 31 15:58 S02E06.mp4
-rw-r--r--. 1 plex plex 466451949 Jul 31 16:07 S03E01.mp4
-rw-r--r--. 1 plex plex 561711409 Jul 31 16:09 S03E02.mp4
-rw-r--r--. 1 plex plex 471702382 Jul 31 16:12 S03E03.mp4
-rw-r--r--. 1 plex plex 470005197 Jul 31 16:13 S03E04.mp4
-rw-r--r--. 1 plex plex 490765345 Jul 31 16:16 S03E05.mp4
-rw-r--r--. 1 plex plex 593780367 Jul 31 16:18 S03E06.mp4
-rw-r--r--. 1 plex plex 411550552 Jul 31 16:42 S04E01.mp4
-rw-r--r--. 1 plex plex 386694391 Jul 31 16:44 S04E02.mp4
-rw-r--r--. 1 plex plex 421524090 Jul 31 16:47 S04E03.mp4
-rw-r--r--. 1 plex plex 389450121 Jul 31 16:49 S04E04.mp4
-rw-r--r--. 1 plex plex 372683474 Jul 31 16:50 S04E05.mp4
-rw-r--r--. 1 plex plex 438048379 Jul 31 16:53 S04E06.mp4
-rw-r--r--. 1 plex plex 815573340 Jul 31 16:56 S05E01.mp4
-rw-r--r--. 1 plex plex 662780728 Jul 31 16:58 S05E02.mp4
-rw-r--r--. 1 plex plex 470925832 Jul 31 16:59 S05E03.mp4
-rw-r--r--. 1 plex plex 783818588 Jul 31 17:01 S05E04.mp4

Only S01E0x of Blackadder is displaying in the “Television” category now…

check your logs for any lines that say database file corrupt or malformed.

There’s … a lot … of logs :slight_smile:

There’s a 5.2 MB log at 7:57 am this morning, which (obviously) has a lot of stuff in it, but doing a search for ‘Database’ doesn’t show up much of interest, it’s optimizing the database a lot, and most of it is due to DVR/Live TV stuff which I’m not even using yet…

There’s a later log which has some odd things in it:

Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Performing a scan with 'Plex Series Scanner' (language: en virtual: 0).
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG -   * Scanning /raid/plex/television
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG -     * Scanning directory /raid/plex/television (parent: no)
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/Octonauts"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/Blackadder"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/Red_Dwarf"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/The_Dresden_Files"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/.grab"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/Firefly"
Aug 01, 2019 12:09:32.425 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/ûlYÂ≤ôd$::ôÛÚ,œÖªÃ∂ÂèlAµ‚$ë≠XRÈ–;ª
 kD>Rúa„‡ã{{è¢C…#I…ÁÄ{‘
4ç8Ò3\qJc"
Aug 01, 2019 12:09:32.426 [0x7f5c467d3780] DEBUG - Skipping over directory '', as nothing has changed; removing 0 media items from map.
Aug 01, 2019 12:09:32.427 [0x7f5c467d3780] DEBUG -     * Scanning directory /raid/plex/television/ûlYÂ≤ôd$::ôÛÚ,œÖªÃ∂ÂèlAµ‚$ë≠XRÈ–;ª
 kD>Rúa„‡ã{{è¢C…#I…ÁÄ{‘
4ç8Ò3\qJc (parent: yes)
Aug 01, 2019 12:09:32.427 [0x7f5c467d3780] DEBUG - Adding file for scanner: "/raid/plex/television/ûlYÂ≤ôd$::ôÛÚ,œÖªÃ∂ÂèlAµ‚$ë≠XRÈ–;ª
 kD>Rúa„‡ã{{è¢C…#I…ÁÄ{‘
4ç8Ò3\qJc/Ω죜"
Aug 01, 2019 12:09:32.427 [0x7f5c467d3780] DEBUG - Skipping over directory 'ûlYÂ≤ôd$::ôÛÚ,œÖªÃ∂ÂèlAµ‚$ë≠XRÈ–;ª
 kD>Rúa„‡ã{{è¢C…#I…ÁÄ{‘
4ç8Ò3\qJc', as nothing has changed; removing 0 media items from map.
Aug 01, 2019 12:09:32.427 [0x7f5c467d3780] DEBUG -     * Scanning directory /raid/plex/television/Firefly (parent: yes)
Aug 01, 2019 12:09:32.427 [0x7f5c3562f700] DEBUG - HTTP requesting GET http://127.0.0.1:32400/:/metadata/updateProgressMessage?message=Scanning%20%9ElY%11%E5%B2%99d%1A$%3A%03%02%02%04%3A%99%18%F3%04%F2%2C%1A%CF%85%BB%CC%B6%E5%8FlA%0E%B5%1C%E2$%91%ADXR%E9%D0;%BB%0A%20%1Fk%1C%1ED%3ER%9C%07%E3%E0%1F%8B%7B%7B%8F%A2C%0B%C9%23I%C9%E7%80%7B%17%D4%17%0D4%8D8%F13%5CqJc
Aug 01, 2019 12:09:32.427 [0x7f5c467d3780] DEBUG - Adding subdirectory for scanner: "/raid/plex/television/Firefly/Season 01"
Aug 01, 2019 12:09:32.428 [0x7f5c467d3780] DEBUG - Skipping over directory 'Firefly', as nothing has changed; removing 0 media items from map.
Aug 01, 2019 12:09:32.428 [0x7f5c467d3780] DEBUG -     * Scanning directory /raid/plex/television/Firefly/Season 01 (parent: yes)

I don’t know what the .grab directory is (I certainly didn’t make it) and I’ve no idea what the weirdly-named directory is - it’s not there now. I’m assuming that’s some sort of machine-generated directory…

Right now, all I see is:

[root@lyonesse television]# pwd
/raid/plex/television
[root@lyonesse television]# ls -la
total 0
drwxrwxr-x.  8 plex plex 139 Jul 28 17:14 .
drwxr-xr-x.  5 root root  71 Jul 29 06:57 ..
drwxrwxr-x.  7 plex plex 115 Jul 31 16:43 Blackadder
drwxrwxr-x.  3 plex plex  31 Jul 25 19:03 Firefly
drwxr-xr-x.  2 plex plex  10 Jul 24 23:03 .grab
drwxrwxr-x.  3 plex plex  31 Jul 15 20:28 Octonauts
drwxrwxr-x. 10 plex plex 178 Jul 22 07:07 Red_Dwarf
drwxrwxr-x.  3 plex plex  31 Jul 22 17:11 The_Dresden_Files

[edit]
Ok, the library scan has finished, and there’s no improvement. Still missing the shows in both ‘television’ and ‘movies’. Logs attached:
Plex Media Server Logs_2019-08-01_12-54-10.zip (2.6 MB)

the .grab folder is used by the dvr to keep the temp files created during the dvr recording and commerical processing (when enabled).

after the video is done recording and post-processed plex then move it into the final destination folder.

if you haven’t set up an tuner or dvr/recordings then that grab folder would seem odd.

what seems really strange to me is the corrupted looking folder, which might either be file system corruption or memory corruption or some other weird corruption.

I would restart your server and rescan the library while monitoring the logs.

you can monitor logs real time @ Plex > settings > console

post edit- I believe also the .grab folder is used for the ‘optimize’ function, which appears you did use already.

I do actually have a DVR set up, I’m just not using it yet. I’ve been focussing on getting the DVDs and Blu-Rays loaded up. I thought I’d finished that, yesterday…

The fact that the filesystem isn’t showing the weird directory makes me think it might be a bug (loop terminating 1 after the number of entries, perhaps) in the plex scanner rather than anything else.

The machine is a new build (Zen 3, 64GB RAM) with a clean install of Centos 7, as of a month or so ago, and I did extensive tests on the Areca RAID array before trusting it :slight_smile: I’d be surprised (though of course, not ruling it out) if it were the hardware.

I’ve already restarted the server, but I’ll give your suggestion a go. It’ll be interesting to see if plex still sees a weird folder name in there, when /bin/ls doesn’t…

To all reading here:

I am seeing this as well. I’m working with engineering right now.

I have recreated the loss of Television series data and am diagosing now.

PS: I will move the DVR related to its own thread if needed.

Ah good :slight_smile: In that case, I’ll wait on that :slight_smile:

Ok, I’m not sure what just happened, but everything has just come back.

I had just made some changes to the network controls (marking 192.168.1.0/24,10.0.0.0/8 as LAN, and not needing auth) but changing those back to what they were originally didn’t make any difference - I can still see all my shows and DVRs again. Not even sure this is relevant, but mentioning for completeness.

In any event, everything is back, including the poster-images :smile:

I think Plex continues to gather metadata and images from online, even after the UI says the scan is done. It’s a little annoying, but it may be why things didn’t look right immediately after the scan finished.

PMS does continue to download the metadata / posters after scanning is complete.
During scanning, it built up the list to download as it performed the matching. Once matched, each item needing data, is added to the list. PMS, in a separate task, works its way through that list until done. This can be seen in your logs where it says "… bringing local… " and “extensive tag writes because something has changed”.

Ok, but would you expect to see movies/shows not be there in this case ?

For me, at least, in at least some cases the missing shows/movies were using posters that I’d uploaded to the server (The Bourne category, “Changing Lanes” etc.), or selected as different from the default (in the case of Blackadder) for consistency between series. In all these cases, there was simply nothing being shown in the web interface. It wasn’t limited to the ones I’d customized either, sometimes the default poster was fine, and some of those shows were missing too - you can see the effect by contrasting the two images in the first post.

All’s well that ends well, though :slight_smile:

EDIT

This is where I fall on my sword.

I wasn’t looking at the right stuff.

I am VERY sorry to have confused.

[quote=“ChuckPA, post:17, topic:440529”]
Who uses the Use the metadata provider for matching movies and TV shows option at the bottom of the Library section? It should be enabled by default.
[/quote]

can you elaborate, I cannot find nor do I remember ever seeing this option or phrase ?

Thought it was just me. I can’t find it either. I was putting it on the horrible redesign of the web client.

Here’s my library config:

Maybe I’m not “sufficiently advanced” for that option :slight_smile: