PMS library does not automatically update on QNAP

When I put new media into folders on my NAS, PMS does not recognise that the folders have altered. I need to manually update the library each time.

Yes, I have all the correct boxes ticked. The problem has existed for months now. I keep thinking it might resolve with an update.

Please can anyone help.

Same on my TVS-873 :-1:

Can I have some more info?

Version of PMS? USB media? Main array?

Do you have more than 8192 directories? (There is a kernel default maximum of directories it can monitor which is easy to update)

I haven’t bothered looking into it but i find on my QNAP that the movies, music and other folders update but my TV Shows directory doesn’t.
I have to manually refresh.

If it updates when you manually do it, then 99.9% certain you have > 8192 directories being monitored.

The solution (which increases to 16384):

echo fs.inotify.max_user_watches=16384 >> /etc/sysctl.conf sysctl -p

The best value to one found by doing a direct count, e.g.

find /share/CACHEDEV2_DATA/movies /share/CACHEDEV2_DATA/tv -type d -print | wc -l

The value printed is the total number of directories found under those two top-level directories.

@ChuckPa. In what interface are you giving the “find” command? I tried this in terminal and just got “No such file or directory”

…I did alter the path for my QNAP:
find /share/CACHEDEV1_DATA/media/film /share/CACHEDEV1_DATA/media/TV -type d -print | wc -l

at the ssh command line.

[~] # hostname
wien
[~] # 
[~] # uname -a
Linux wien 4.2.8 #1 SMP Tue Jul 10 09:40:35 CST 2018 x86_64 GNU/Linux
[~] # which find
/usr/bin/find
[~] # find /share/CACHEDEV2_DATA/movies* -type d -print | wc -l 
801
[~] #

cheers!

(turns out “Cheers!” is not enough to post, so this is extra text to compensate)

hey @ChuckPa, i’m having a similar issue where new media added to my QNAP doesn’t always autodetect, my plex server is running on a windows 2012 r2 server tho, is there an equivalent limitation and settings change that i might try?

There is no automatic detection over the network. Networking protocols were developed before the iNotify capability existed in Linux.

1 Like

Hi, @ChuckPa. I’m having a similar problem with QNAP NAS though my server is also running on the QNAP. The main HD movie library works fine but I have 2 directories on the same QNAP that are defined as part of the main HD Movie library. The original HD Movie directory automatically updates but the secondary directory HD Video ISO does not. I have full permissions on the QNAP user I use to run the PMS. Both directories are under the same main Plex Media directory. I’ve checked all of the appropriate options.

Any idea why one directory would automatically update the library when I add a file but eh other requires a manual update?

If they are .iso files, PMS will never recognize them as media.

If you have an ISO share, by definition it will never update because the share is encapsulated in a fixed-length read-only ISO file. All QTS does for you is mount the ISO file as a share so you can read it.

Am I misunderstanding you in any way?