FAQ  •  Register  •  Login

1.5.2 on MacOSX El Capitan OutOfMemory

<<

falcon

Serviio newbie

Posts: 1

Joined: Wed Oct 21, 2015 11:19 pm

Post Wed Oct 21, 2015 11:50 pm

1.5.2 on MacOSX El Capitan OutOfMemory

I am new to Serviio and rather like the experience so far.

However, I am having a number of problems. Don't know how they may depend on each other ...

1. The java process is pretty heavy on CPU, seems better now that I disabled "Keep library automatically updated" in console. Is this normal? The load is to high.

2. I often fail to start console successfully. I then only get an "About" dialog from the console dialog, but no main window popping up.
I have to follow unload/load as per http://serviio.org/component/content/article?id=21#q13, with an additional kill of the java process in between.

3. Are the server parameters all controlled via /Library/Application\ Support/Serviio/bin/serviio.sh ?
What does -Dserviio.libraryPollerFrequency=5 mean? 5 what? Can I change it to run the library update scan less frequently, i.e., to reduce average CPU load?

4. I have 80MP JPG images in my repository. Serviio takes ages to create a thumbnail for it. This is odd as fast thumbnail creators exist for JPG. You could run a command line to fetch a JPGs thumbnail. I had to disable thumbnails.

5. I have about a million images in my repository and this seems to work.

6. I get OutOfMemory exceptions from the Java process. But that process didn't seem to die. Most exceptions were without stack trace, but this one I got:

  Code:
...
Exception in thread "ServioThread-4-EventDispatcher" java.lang.OutOfMemoryError: Java heap space
usage: dirname path
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
   at java.util.Arrays.copyOfRange(Arrays.java:3664)
   at java.lang.String.<init>(String.java:201)
   at java.lang.String.toUpperCase(String.java:2798)
   at org.apache.derby.iapi.util.StringUtil.SQLToUpperCase(Unknown Source)
   at org.apache.derby.impl.sql.GenericResultDescription.findColumnInsenstive(Unknown Source)
   at org.apache.derby.impl.jdbc.EmbedResultSet.findColumnName(Unknown Source)
   at org.apache.derby.impl.jdbc.EmbedResultSet.getLong(Unknown Source)
   at org.serviio.library.dao.MediaItemDAOImpl.initMediaItem(MediaItemDAOImpl.java:417)
   at org.serviio.library.dao.MediaItemDAOImpl.mapResultSet(MediaItemDAOImpl.java:404)
   at org.serviio.library.dao.MediaItemDAOImpl.getMediaItemsInRepository(MediaItemDAOImpl.java:193)
   at org.serviio.library.local.service.MediaService.getMediaItemsInRepository(MediaService.java:81)
   at org.serviio.library.local.indexing.LibraryOneTimeScanner.searchForRemovedAndUpdatedFiles(LibraryOneTimeScanner.java:228)
   at org.serviio.library.local.indexing.LibraryOneTimeScanner.searchForUpdatesAndRemovals(LibraryOneTimeScanner.java:133)
   at org.serviio.library.local.indexing.LibraryOneTimeScanner.scanLibrary(LibraryOneTimeScanner.java:82)
   at org.serviio.library.local.indexing.LocalLibraryManager.performManualScan(LocalLibraryManager.java:186)
   at org.serviio.library.local.indexing.LocalLibraryManager.startLibraryScanning(LocalLibraryManager.java:117)
   at org.serviio.MediaServer.main(MediaServer.java:162)
usage: dirname path

Exception: java.lang.OutOfMemoryError thrown from the UncaughtExceptionHandler in thread "ActionDistributor: Thread-5"
...


You run with up to 512MB of memory. What size would you recommend per million items? And why does it consume this much memory? This is more memory than just reading a text file into a hash map, with 1 million lines. And you use SQL. Doesn't make any sense to me ...

Kind regards and thanks for any help to get this running,
Falk
<<

zip

User avatar

Serviio developer / Site Admin

Posts: 17215

Joined: Sat Oct 24, 2009 12:24 pm

Location: London, UK

Post Thu Oct 22, 2015 4:30 pm

Re: 1.5.2 on MacOSX El Capitan OutOfMemory

Memory - try + error will give you your best value, I'm not sure. It looks like the DB query loads a lot of stuff into memory, but it's up to the DB driver . Not much I can do unless I change the DB query. I haven't seen it before, but your library is pretty huge.

Thumbnails - they are creates in-proc in java, and yes, it sucks. But saves me from compiling an external tool for all the platforms to distribute with Serviio.

CPU load -OSX doesn't have a OS-level folder monitoring in Java, so it just does a manual compare in time cycles. That's where the CPU load comes from. Maybe for you is best to do manual scan once in a while.

Return to Serviio Support & Help

Who is online

Users browsing this forum: Google [Bot] and 19 guests

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.