MacGyver27 17 Posted March 14 Share Posted March 14 Hello, One of my library stopped doing automatic scan upon media insertion.. it used to work for many months without problem. I have checked the library config and is configured to scan the library when it detects media addition. This library contains 6,002 Files in 127 Folders, could that be an issue? Once it reached certain limit it wont perform automatic scan? Troubleshooting steps: bouncing this settings upgrading Emby server checked logs, didnt find anything special Not sure if clearing metadata would be of any help so didn't trigger it yet.. once I did that it was generating them couple days for that many files.. Thanks. Thanks Docker version 25.0.4, build 1a576c5 Linux caradhras 6.1.0-17-amd64 Emby Server Version 4.8.3.0 Docker image: lscr.io/linuxserver/emby:latest Link to comment Share on other sites More sharing options...
adminExitium 173 Posted March 14 Share Posted March 14 Check the value of inotify.max_user_watches and increase it if necessary: https://gist.github.com/ntamvl/7c41acee650d376863fd940b99da836f 1 Link to comment Share on other sites More sharing options...
Happy2Play 8296 Posted March 14 Share Posted March 14 Providing a server log would potentially provide use with the cause but if you have inotify errors in your log on your library it will require the change above. Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 14 Share Posted March 14 Hi, yes, let's look at a specific example: How to Report a Problem Thanks. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 15 Author Share Posted March 15 (edited) Thanks for replying. Here are the logs from the moment when media were inserted until triggering the manual scan. Appreciate emby_logs.txt or via here: https://pbin.aronmgv.com/IMCWh8xJqpwLeqkPyjzxR Edited March 15 by MacGyver27 couldnt edit first post Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 15 Share Posted March 15 And what example are we focusing on here? Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 15 Author Share Posted March 15 Ahh sorry. Anything in `@ADV` folder. I renamed the files to be `XXXXXXXXXXXXXXXXXXXX.mp4` or `XXXXXXXXXXXXXXXXXXXX.mkv`. Thanks Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 15 Share Posted March 15 It looks like the realtime monitor did pick something up: 2024-03-14 02:27:31.597 Info LibraryMonitor: Movies.HD (/srv/media/Movies.HD) will be refreshed. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 15 Author Share Posted March 15 In the first post I say the problematic library is `@Downloads` with the path `/srv/media/.downloads`. Thanks Link to comment Share on other sites More sharing options...
Happy2Play 8296 Posted March 15 Share Posted March 15 I will guess it is being ignored as folders that start with periods are problematic. As your log is not showing the folder being monitored at all. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 16 Author Share Posted March 16 But it used to work for like a year without problem.. in linux folders with . is nothing special. Will try to create library from scratch and report back. Thanks Link to comment Share on other sites More sharing options...
Happy2Play 8296 Posted March 16 Share Posted March 16 7 minutes ago, MacGyver27 said: But it used to work for like a year without problem.. in linux folders with . is nothing special. Will try to create library from scratch and report back. Thanks True but other platforms like Mac it becomes a major issue and even Synology so coding is applied to all platforms is my understanding. But could be wrong as I am just guessing from previous topics. So if you have a folder that does not have a preceding period do you have the same issue? Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 16 Share Posted March 16 Ah yes, that could be the problem. Please let us know if using a different name resolves it for you. Thanks. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 16 Author Share Posted March 16 So I tested various libraries and it stopped doing real time monitoring for all of them.. even for the one you mentioned above Movies.HD (Info LibraryMonitor: Movies.HD (/srv/media/Movies.HD) will be refreshed). I was moving a home made video file and renaming it every time between libraries of different content type (movies/mixed/videos). Neither time it was automatically recognized - I waited about 2-3 minutes every time.. Once I clicked to scan withing a second it was recognized.. Thanks! Link to comment Share on other sites More sharing options...
Happy2Play 8296 Posted March 16 Share Posted March 16 (edited) Per your log no libraries are being monitored and there was just the one mention of Movies.HD. How many libraries do you have? Do they all begin with periods? Have you tried toggling RTM off and On on each library? But this is something specific to your setup/environment. Example from my log. Spoiler 2024-03-14 22:47:55.215 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\AppData\Roaming\Emby-Server\programdata\data\livetv\recordings for item 43 2024-03-14 22:47:55.216 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\AppData\Roaming\Emby-Server\programdata\data\playlists for item 42 2024-03-14 22:47:55.216 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\AppData\Roaming\Emby-Server\programdata\data\userplaylists for item 104988 2024-03-14 22:47:55.216 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Anime for item 9 2024-03-14 22:47:55.216 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\AudioBooks for item 10 2024-03-14 22:47:55.217 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Custom test Series for item 49 2024-03-14 22:47:55.217 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Documentaries (Keep) for item 47 2024-03-14 22:47:55.217 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Ebooks for item 13 2024-03-14 22:47:55.217 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Empty for item 44 2024-03-14 22:47:55.218 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\fake_movies - Emby for item 18 2024-03-14 22:47:55.218 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Features for item 14 2024-03-14 22:47:55.219 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Foreign for item 35 2024-03-14 22:47:55.219 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Kids Movies for item 26 2024-03-14 22:47:55.219 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Mixed Content testing for item 21 2024-03-14 22:47:55.219 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Movie - Embedded test for item 24 2024-03-14 22:47:55.220 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Movie Classics for item 30 2024-03-14 22:47:55.220 Info LibraryMonitor: Watching directory with new FileSystemWatcher for C:\Users\Media\Desktop\Videos\Movies - DB for item 22 Edited March 16 by Happy2Play Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 17 Share Posted March 17 @MacGyver27? Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 18 Author Share Posted March 18 (edited) So I was testing it and only time it was automatically scanning it was when I disabled RTM for all other libraries and only `@Downloads` was configured for RTM. I tried to put back RTM for others and again it stopped doing autoscan completely for every library.. Q: How many libraries do you have? A: 18 Q: Do they all begin with periods? A: No, just 2 of them Q: Have you tried toggling RTM off and On on each library? A: Yes. I restarted Emby when I disabled for all and restarted when enabled for all. Still stopped autoscan. OKAY, found problem. When I have enabled RTM for a library containing only 4K Movies/Series than it stops doing autoscan for all other libraries as well. When I disable autoscan for that particular library, it works for rest of the libraries.. (it had RTM configured since the beginning, but only content of the library changed) BTW that many files because it contains some BluRay discs and those has many files inside.. Thanks! Edited March 18 by MacGyver27 Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 19 Author Share Posted March 19 So no.. again it is stuck.. leaving RTM enabled only for the `@Downloads` library now.. will see how it behaves tomorrow. BRB Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 19 Share Posted March 19 2 hours ago, MacGyver27 said: So no.. again it is stuck.. leaving RTM enabled only for the `@Downloads` library now.. will see how it behaves tomorrow. BRB What exactly do you think is stuck? Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 19 Author Share Posted March 19 It doesn't automatically scan the library when new files are added to its folders. Every time have to click for scanning to recognize new content. Now i had RTM enabled only for the `@Downloads` library and is not doing automatic scanning.. I will provide logs from today.. Link to comment Share on other sites More sharing options...
Luke 37115 Posted March 19 Share Posted March 19 8 hours ago, MacGyver27 said: It doesn't automatically scan the library when new files are added to its folders. Every time have to click for scanning to recognize new content. Now i had RTM enabled only for the `@Downloads` library and is not doing automatic scanning.. I will provide logs from today.. That would be great. Thanks. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 19 Author Share Posted March 19 (edited) Logs: https://pbin.aronmgv.com/EI1Ii_d5G5Fv7cS3wM2p7 Now I am seeing error mentioned above: System.IO.IOException: System.IO.IOException: The configured user limit (65536) on the number of inotify watches has been reached, or the operating system failed to allocate a required resource. 1) root@caradhras:[~/Repos/inotify-info]: inotify-info ------------------------------------------------------------------------------ INotify Limits: max_queued_events 16,384 max_user_instances 128 max_user_watches 65,536 ------------------------------------------------------------------------------ Pid Uid App Watches Instances 2994954 1000 jellyfin 49,380 9 1743597 1000 Plex Media Server 15,237 1 3910014 1000 EmbyServer 243 2 2) echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p 3) Enabled RTM for all libraries. 4) oot@caradhras:[~/Repos/inotify-info]: inotify-info ------------------------------------------------------------------------------ INotify Limits: max_queued_events 16,384 max_user_instances 128 max_user_watches 524,288 ------------------------------------------------------------------------------ Pid Uid App Watches Instances 2994954 1000 jellyfin 64,769 16 3910014 1000 EmbyServer 16,177 16 1743597 1000 Plex Media Server 15,237 1 Seems it fixed the problem! Sorry to waste your time, but this error did not appear in the first log file Thanks! Edited March 19 by MacGyver27 Link to comment Share on other sites More sharing options...
Lessaj 66 Posted March 20 Share Posted March 20 Thanks for pointing out that utility, that seems useful. Link to comment Share on other sites More sharing options...
MacGyver27 17 Posted March 20 Author Share Posted March 20 14 hours ago, Lessaj said: Thanks for pointing out that utility, that seems useful. https://github.com/mikesart/inotify-info 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now