Jump to content

System.OutOfMemoryException


andcbii

Recommended Posts

Emby keeps crashing on me and i'm not sure why. I've have the server setup for a few months but this just started 2 weeks ago. I've attached logs. 

 

Here is link to the log just before the crash:

https://drive.google.com/folderview?id=0B06_gNvTSUaISUVDQVpyN3JweTA&usp=sharing

 

I have 16GB of ram and normally only use about 30% of that. 

unhandled_583999ee-caf0-4719-8c7d-bb87e1644afc.txt

unhandled_2c3f3670-2608-43b6-bde2-9140883d8d36.txt

Link to comment
Share on other sites

revengineer

You have to remember having lots of RAM means nothing to a 32-bit application.

 

Have you seen or tried this?

http://emby.media/community/index.php?/topic/19476-emby-out-of-memory-errors/page-3?hl=%2Bram+%2Bhack&do=findComment&comment=198792

Good point and I will give that patch a shot. But there should be a more elegant solution in the long run. I don't think emby needs to hold that much info in memory.

Link to comment
Share on other sites

Happy2Play

I rarely see over 600K being used, but the more plugins and live tv features being used I can see it becoming more of an issue.

Link to comment
Share on other sites

revengineer

I rarely see over 600K being used, but the more plugins and live tv features being used I can see it becoming more of an issue.

From what I am reading there may be a memory leak with downloading TV Guide data. I suspect this is the issue for me.
Link to comment
Share on other sites

mediacowboy

Those of you won't the memory leak, do you just have a lot of channels or do you have about of channels and multiple Tuners?

Link to comment
Share on other sites

revengineer

Those of you won't the memory leak, do you just have a lot of channels or do you have about of channels and multiple Tuners?

I have a single HD Homerun CC (cablecard version), which has three built-in tuners. Because it's cable I do have a lot of channels, about 400 of them.

 

I did another test yesterday, by restarting the emby server and then invoking the guide update manually. During the update process the RAM footprint grew from 200 MB to 500 MB and the memory was not released when the process was compete.

Edited by revengineer
Link to comment
Share on other sites

Happy2Play

I have a single HD Homerun CC (cablecard version), which has three built-in tuners. Because it's cable I do have a lot of channels, about 400 of them.

 

I did another test yesterday, by restarting the emby server and then invoking the guide update manually. During the update process the RAM footprint grew from 200 MB to 500 MB and the memory was not released when the process was compete.

About 500MB is what Emby normally uses, so is your test just a matter of timing with Emby starting up to there is nothing to release?

Edited by Happy2Play
Link to comment
Share on other sites

revengineer

About 500MB is what Emby normally uses, so is your test just a matter of timing with Emby starting up to there is nothing to release?

I will keep that in mind my testing.

Link to comment
Share on other sites

revengineer

I did more detailed testing and stand by my statement that there is a memory leak. However, the leak is not related to out of memory errors, which this thread is about. So I have opened another thread at the link below, where I detail my findings.

 

http://emby.media/community/index.php?/topic/25852-memory-leak-with-guide-update/

Link to comment
Share on other sites

Nathanio

Today I've had two TV shows that have appeared to start late by around 25 minutes (F1 in Suzuka and XFactor). However, when interrogating the logs I see this:

 

 

2015-09-27 19:22:29.4159 Error - App: Error getting programs for channel Challenge TV

*** Error Report ***
Version: 3.0.5724.5
Command line: C:\Users\Administrator\AppData\Roaming\Emby-Server\system\MediaBrowser.ServerApplication.exe -service
Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
Processor count: 8
64-Bit OS: True
64-Bit Process: False
Program data path: C:\Users\Administrator\AppData\Roaming\Emby-Server
Application Path: C:\Users\Administrator\AppData\Roaming\Emby-Server\system\MediaBrowser.ServerApplication.exe
Exception of type 'System.OutOfMemoryException' was thrown.
System.OutOfMemoryException
  at MediaBrowser.Server.Implementations.Persistence.SqliteExtensions.GetMemoryStream(IDataReader reader, Int32 ordinal)
  at MediaBrowser.Server.Implementations.Persistence.SqliteItemRepository.GetItem(IDataReader reader)
  at MediaBrowser.Server.Implementations.Persistence.SqliteItemRepository.RetrieveItem(Guid id)
  at MediaBrowser.Server.Implementations.Library.LibraryManager.GetItemById(Guid id)
  at MediaBrowser.Server.Implementations.LiveTv.LiveTvManager.<GetProgram>d__64.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
  at MediaBrowser.Server.Implementations.LiveTv.LiveTvManager.<RefreshChannelsInternal>d__c7.MoveNext()
 
2015-09-27 19:22:29.4159 Info - App: Channel Station ID is: 75804
2015-09-27 19:22:29.4159 Debug - App: Request string for schedules is: [{"stationID":"75804","date":[]}]
2015-09-27 19:22:29.4159 Info - App: HttpClientManager POST: https://json.schedulesdirect.org/20141201/schedules
2015-09-27 19:22:29.9229 Debug - App: Found 21 programs on 47 ScheduleDirect
2015-09-27 19:22:29.9229 Info - App: HttpClientManager POST: https://json.schedulesdirect.org/20141201/programs
2015-09-27 19:22:30.4150 Debug - HttpServer: HTTP GET http://192.168.0.1:8096/dlna/bd797ea31d9c765f68381cced83d7bd9/description.xml
Ip: 192.168.0.1:58562. Headers: Host=192.168.0.1:8096,Connection=close
2015-09-27 19:22:30.4150 Debug - Dlna: No matching device profile found. The default will be used. 
2015-09-27 19:22:30.4150 Debug - HttpServer: HTTP Response 200 to 192.168.0.1. Response time: 7.0007 ms.
2015-09-27 19:22:31.7441 Info - App: HttpClientManager POST: https://json.schedulesdirect.org/20141201/metadata/programs
2015-09-27 19:22:32.4292 Info - App: Finished with EPGData
2015-09-27 19:22:32.4802 Info - App: Channel Station ID is: 46306
2015-09-27 19:22:32.4802 Debug - App: Request string for schedules is: [{"stationID":"46306","date":[]}]
2015-09-27 19:22:32.4802 Info - App: HttpClientManager POST: https://json.schedulesdirect.org/20141201/schedules
2015-09-27 19:22:33.7373 Debug - App: Found 21 programs on 48 ScheduleDirect
2015-09-27 19:22:33.7373 Info - App: HttpClientManager POST: https://json.schedulesdirect.org/20141201/programs
2015-09-27 19:22:33.7453 Error - Main: UnhandledException
*** Error Report ***
Version: 3.0.5724.5
Command line: C:\Users\Administrator\AppData\Roaming\Emby-Server\system\MediaBrowser.ServerApplication.exe -service
Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
Processor count: 8
64-Bit OS: True
64-Bit Process: False
Program data path: C:\Users\Administrator\AppData\Roaming\Emby-Server
Application Path: C:\Users\Administrator\AppData\Roaming\Emby-Server\system\MediaBrowser.ServerApplication.exe
Exception of type 'System.OutOfMemoryException' was thrown.
System.OutOfMemoryException
  at MediaBrowser.Server.Implementations.Persistence.SqliteExtensions.GetMemoryStream(IDataReader reader, Int32 ordinal)
  at MediaBrowser.Server.Implementations.Persistence.SqliteItemRepository.GetItem(IDataReader reader)
  at MediaBrowser.Server.Implementations.Persistence.SqliteItemRepository.RetrieveItem(Guid id)
  at MediaBrowser.Server.Implementations.Library.LibraryManager.GetItemById(Guid id)
  at MediaBrowser.Providers.Manager.ProviderManager.<RefreshTimerCallback>d__8d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<>c__DisplayClass2.<ThrowAsync>b__5(Object state)
  at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(Object state)
  at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
  at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
  at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
  at System.Threading.ThreadPoolWorkQueue.Dispatch()
  at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()
 
 

 

It then restarts the emby service and overwrites the already started recording. 

 

I only have 62 items in my live tv line up but it is set to a 15min refresh rate (now changed). I did have it so high so not to miss changes in guide due to program over runs. 

 

What else could be causing this?

 

Xeon E3-1240v3

8GB DDR3

240GB SSD for boot 

32GB scratch drive

WHS2011

 

Otherwise rock solid machine

 

Attached log

 

server-63578932419.txt

Link to comment
Share on other sites

mine crashes with emby theatre and I've no live tv application I think it's the screensaver tho as it only crashes when I leave it... tbh i'm really regretting going windows 10... WMC come back all is forgiven

Link to comment
Share on other sites

  • 3 weeks later...
andcbii

Based on the comments in this thread and others i've changed how often my TV Guide data refreshes. I'm hoping this will resole the issue for the time being.... 

Link to comment
Share on other sites

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...