Jump to content

Library scan hangs


Go to solution Solved by Happy2Play,

Recommended Posts

Posted

After the v4 upgrade, my library scan hangs at 88%.  After looking at the log, it looks like it does finish sometimes, but it takes 30 minutes to complete. Other times it appears to bomb out and start over.  Either way, once it finishes, it starts right back up. Before the upgrade it took less than a minute.  All Plugins have been upgraded and the server has been rebooted.  I have disabled ipv6 and subtitle downloads per other users questions. I also upgraded to 4.0.1.0 last night and I have the same results.  I have attached my server log.

EmbyServer.txt

Posted

Do you by any chance have the libraries set to monitor for change and are adding new content to these libraries?

Posted

Real time monitoring is turned on, but I am not adding content all day long. The scans start, run for 30 minutes, stop, then start again all day long.  It did not behave this way before upgrading.

Posted

For kicks and diagnosing the issue could you turn that off on your libs to see if that stops it from constantly rescanning?

Posted

I just turned it off on all my libraries.  I will let you know how it behaves.

  • Like 1
Posted

According to the log the scan completed normally. It did not hang, it just had some periods of time where the % did  not change a whole lot. Please let us know if this helps. Thanks.

Posted

So far it is still sitting around the 88% mark during scans.  I would consider this hanging up since it just sits there.  This is not how it behaved prior to the update nor should a library scan take 30 minutes and then immediately start over.  Do you have any other suggestions?  Right now, I have left the real time monitoring off, but I don't think that is the cause.

Posted

You have a log showing a completed scan. Why not just wait for it to complete?

Posted

I do wait and it starts right back up as the log states. This is an issue and I would like it to be addressed. I can access my server at any point of the day and it will say 88.x% and sometimes I can actually watch it go from 88.x% down to 87.x%.  Right now it say 88.3%.  Can we start troubleshooting this issue?  Could it be a plugin causing this?  Could it be the update?  Again, this did not happen before the update and you can not say scanning should basically run all day long except a few seconds out of each day.

Posted

If you would like a faster library scan, you could remove these plugins:

	Auto Box Sets 1.2.2.0
	Email Notifications 3.1.4.0
	Fanart.tv 1.0.2.0
	GameBrowser 3.2.0.0
	IMVDb 1.0.5.0
	MusicBrainz 1.0.1.0
	Nfo Metadata 1.0.10.0
	OMDb 1.0.3.0
	Open Subtitles 1.0.11.0
	Statistics 2.0.8.0
	TheAudioDb 1.0.4.0
	Trailers 1.1.9.0
Posted

I will start removing plugins to see which ones, if any, are causing the issue.  I will say this, I didn't install most of those, did they get installed during the update?

Posted

Some of them are included with the server, but you can remove them if you don't need them.

Posted

Update, I removed all the plugins you suggested, restarted Emby, and the library scan still taking 30 minutes.  Gets to 87.7% and starts to very slowly increment .1% at a time.

Posted

The other issue is, because the scan never stops (for more than a split second), the CPU usage stays around 13%.  When I manually stop the scan it drops back down to 0%.  Having CPU chewed up by a process that doesn't stop running is not a good thing.  That is valuable resources that could be used for transcoding. Any one else have any suggestions?  Worst case, I will revert back to my snapshot in vmware and try the upgrade again.

 

5c47c010f0af5_2019012219_25_02svrembyRem5c47c0181d0d3_2019012219_25_46svrembyRem

Happy2Play
Posted (edited)

What triggers do you have setup for library scan, it appears to be firing about every 30 minutes?

2019-01-22 00:18:14.874 Info TaskManager: ExecuteQueuedTasks                                (Shows before each scan)
2019-01-22 00:18:15.113 Info TaskManager: Executing Scan media library
2019-01-22 00:23:06.560 Info TaskManager: IntervalTrigger fired for task: Scan media library
 
	Line 327: 2019-01-22 00:48:36.299 Info TaskManager: Executing Scan media library
	Line 437: 2019-01-22 01:18:48.722 Info TaskManager: Executing Scan media library
	Line 531: 2019-01-22 01:48:59.069 Info TaskManager: Executing Scan media library
	Line 634: 2019-01-22 02:19:00.298 Info TaskManager: Executing Scan media library
	Line 742: 2019-01-22 02:49:31.436 Info TaskManager: Executing Scan media library
	Line 832: 2019-01-22 03:23:02.176 Info TaskManager: Executing Scan media library
	Line 928: 2019-01-22 03:56:46.976 Info TaskManager: Executing Scan media library
	Line 1022: 2019-01-22 04:27:49.190 Info TaskManager: Executing Scan media library
	Line 1114: 2019-01-22 04:58:12.251 Info TaskManager: Executing Scan media library
	Line 1206: 2019-01-22 05:27:50.198 Info TaskManager: Executing Scan media library
	Line 1312: 2019-01-22 05:56:51.848 Info TaskManager: Executing Scan media library
	Line 1406: 2019-01-22 06:27:10.486 Info TaskManager: Executing Scan media library
	Line 1500: 2019-01-22 07:01:13.648 Info TaskManager: Executing Scan media library
	Line 1733: 2019-01-22 07:34:58.709 Info TaskManager: Executing Scan media library
	Line 1890: 2019-01-22 08:05:27.767 Info TaskManager: Executing Scan media library
	Line 1980: 2019-01-22 08:35:55.361 Info TaskManager: Executing Scan media library
	Line 2167: 2019-01-22 09:06:14.973 Info TaskManager: Executing Scan media library

Edited by Happy2Play
Posted

When I first setup Emby, I set it to 15 minutes and left it.  Never had an issue before but I can try changing it.  Does the Emby community have a recommended setting for this trigger?

5c47cb12a3e53_2019012220_13_38ScheduledT

  • Solution
Happy2Play
Posted

So Emby is in a never ending scan loops as one scan finishes and another kicks off, since the initial scan finishes and two have been queued up before the first one ever finishes multiplying during every scan.

 

Unless Realtime monitoring does not work on your setup, there is no need to run a Library Scan more then the default every 12 hours.

 

 

I would delete the custom trigger in C:\Users\plex.admin\AppData\Roaming\Emby-Server\programdata\config\ScheduledTasks, look for 6330ee8f-b4a9-57f3-3981-f89aa78b030f.js then restart your server.

  • Like 1
Posted

When I first setup Emby, I set it to 15 minutes and left it.  Never had an issue before but I can try changing it.  Does the Emby community have a recommended setting for this trigger?

5c47cb12a3e53_2019012220_13_38ScheduledT

I would use the defaults.

Posted

Happy2Play - I just deleted the trigger per your instructions and restarted Emby.  It is now set back to the default 12 hours.  I will let everyone know if this resolves it.  Thanks for everyone's help!

  • Like 1
Posted

Thanks for the feedback !

Posted

This seems to have resolved it.  The last couple scans took 32+ minutes to complete, but it isn't in a loop anymore.  Thanks for the help everyone!

Posted

Thanks for the feedback.

  • 1 year later...
leeknight1981
Posted

Hi Guy's embyserver.txtquick-extract-imageseries-b372a63b-b4fd-4cc3-9200-266d27b018c6_1.txtIMG_1389.HEIC

Added some tv shows tagged them as normal but my scan is stuck at 87.1% and i cant seem to get it to progress it then says Failed. I have shut UnRaid down and re started it etc but it gets stuck again at 87.1%

put some logs but not sure which ones are useful, scheduled task is default 12 hours 

Thanks 

 

L33

Happy2Play
Posted

That log show items being processed (interval image extraction).  

What interval image option did you choose?

Are both tasks running at the same time?

I am guessing the extraction process is slowing down the library scan.

leeknight1981
Posted
1 minute ago, Happy2Play said:

That log show items being processed (interval image extraction).  

What interval image option did you choose?

Are both tasks running at the same time?

I am guessing the extraction process is slowing down the library scan.

I took the 2 shows out the folder and have re scanned and still stuck, Its never had this issue before! So i have turned off 

Thumbnail Images

Generate video preview thumbnails: NEVER 

Will try again Now whats the best options here as never had any issues with this and nothings been changed 
 
Cheers 

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...