Page 1 of 1

serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 2:14 am
by mbnu99
Hi there,

first things first and excellent media server.

After following the excellent instruction on a link via this forum I got Serviio up and running on my Synology NAS DS211 it generated the thumbnails and was working excellent I was able to view and browse video on my Sony TV.

In the early hours of this morning, I noticed the NAS CPU usage was up and down like a yo-yo and the memory was at 90% capacity. . . as Serviio finished generating thumbnails a many hours ago I sent the reboot command over telnet and re-booted the server. when it came back up Serviio did not start automatically for some reason, it had done previously, I started the script S99serviio.sh manually and using ps I can see the service starts OK:

6985 serviio 2988 S -sh -c /opt/serviio/bin/serviio.sh
6988 serviio 2988 S /bin/sh /opt/serviio/bin/serviio.sh
6993 serviio 494m S /opt/java/ejre1.6.0_25/bin/java -Xmx384M -Djava.net.

but within 30 seconds shuts down.

I've checked all the package installs, reinstalled java, checked all the files either edited or created with nano, reinstalled serviio, the web PHP ui, checked the FFmpeg install and can't find anything wrong. . . does anyone have any ideas?

I've got the log and there are errors on it. . . some of which I've cut and paste below:



Caused by: java.sql.SQLException: Failed to start database 'db' with class loader sun.misc.Launcher$AppClassLoader@f4a24a, see the next exception for details.
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
... 72 more
Caused by: java.sql.SQLException: Error encountered while trying to write data to disk during database recovery. Check that the database disk is not full. If it is then delete unnecessary files, and retry connecting to the database. It is also possible that the file system is read only, or the disk has failed, or some other problem with the media. System encountered error while processing page Page(758,Container(0, 1392)).
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
... 69 more
Caused by: ERROR XSDFI: Error encountered while trying to write data to disk during database recovery. Check that the database disk is not full. If it is then delete unnecessary files, and retry connecting to the database. It is also possible that the file system is read only, or the disk has failed, or some other problem with the media. System encountered error while processing page Page(758,Container(0, 1392)).
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
at org.apache.derby.impl.store.raw.data.FileContainer.reCreatePageForRedoRecovery(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseContainerHandle.reCreatePageForRedoRecovery(Unknown Source)
at org.apache.derby.impl.store.raw.data.InitPageOperation.getPageForRedoRecovery(Unknown Source)
at org.apache.derby.impl.store.raw.data.PageBasicOperation.findpage(Unknown Source)
at org.apache.derby.impl.store.raw.data.PageBasicOperation.needsRedo(Unknown Source)
at org.apache.derby.impl.store.raw.log.FileLogger.redo(Unknown Source)
at org.apache.derby.impl.store.raw.log.LogToFile.recover(Unknown Source)
at org.apache.derby.impl.store.raw.RawStore.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startModule(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.bootServiceModule(Unknown Source)
at org.apache.derby.impl.store.access.RAMAccessManager.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startModule(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.bootServiceModule(Unknown Source)
at org.apache.derby.impl.db.BasicDatabase.bootStore(Unknown Source)
at org.apache.derby.impl.db.BasicDatabase.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.boot(Unknown Source)
at org.apache.derby.impl.services.monitor.TopService.bootModule(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.bootService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startProviderService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.findProviderAndStartService(Unknown Source)
at org.apache.derby.impl.services.monitor.BaseMonitor.startPersistentService(Unknown Source)
at org.apache.derby.iapi.services.monitor.Monitor.startPersistentService(Unknown Source)
... 69 more
Caused by: ERROR XSLAA: The store has been marked for shutdown by an earlier exception.
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
at org.apache.derby.impl.store.raw.log.LogToFile.flush(Unknown Source)
at org.apache.derby.impl.store.raw.log.LogToFile.flush(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseDataFileFactory.flush(Unknown Source)
at org.apache.derby.impl.store.raw.data.CachedPage.writePage(Unknown Source)
at org.apache.derby.impl.store.raw.data.CachedPage.createIdentity(Unknown Source)
at org.apache.derby.impl.services.cache.ConcurrentCache.create(Unknown Source)
... 95 more
Caused by: ERROR XSDB0: Unexpected exception on in-memory page Page(758,Container(0, 1392))
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
at org.apache.derby.impl.store.raw.data.StoredPage.initSlotTable(Unknown Source)
at org.apache.derby.impl.store.raw.data.StoredPage.initFromData(Unknown Source)
at org.apache.derby.impl.store.raw.data.CachedPage.setIdentity(Unknown Source)
at org.apache.derby.impl.services.cache.ConcurrentCache.find(Unknown Source)
at org.apache.derby.impl.store.raw.data.FileContainer.getAnyPage(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseContainer.getAnyPage(Unknown Source)
at org.apache.derby.impl.store.raw.data.BaseContainerHandle.getAnyPage(Unknown Source)
... 92 more
2011-07-26 02:15:57,712 ERROR [MediaServer] An unexpected error occured. Ending the application. Message: null

Any help would be appreciated.

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 4:28 am
by zip
make sure serviio has write access to its library folder

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 7:02 am
by mbnu99
Hi Petr,

Thanks for such a prompt response, so that I'm crystal clear on this do you mean the library where the video/audio/photo/ files are? (these are read only at the moment) or it's home directors (this is currently R/W) or is there somewhere else? . . . sorry to ask but thought I'd better get it right first time.

Martyn

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 7:13 am
by Cerberus
mbnu99 wrote:Hi Petr,

Thanks for such a prompt response, so that I'm crystal clear on this do you mean the library where the video/audio/photo/ files are? (these are read only at the moment) or it's home directors (this is currently R/W) or is there somewhere else? . . . sorry to ask but thought I'd better get it right first time.

Martyn


in the serviio installation folder there is a folder called " LIBRARY " make sure serviio has write access to this folder

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 7:27 am
by mbnu99
Thanks again Petr,

This is not obvious way I can see to check/ensure that it does not already have RW access to this folder on my Synology NAS, do you know how it's done.

Finally how can I contribute to the work being done here, I've always paid for software, especially support and it doesn't seem right that so far for Serviio I've not paid anything, is there any place I can make a donation to the cause?

Martyn

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 7:33 am
by Cerberus
mbnu99 wrote:Thanks again Petr,

This is not obvious way I can see to check/ensure that it does not already have RW access to this folder on my Synology NAS, do you know how it's done.

Finally how can I contribute to the work being done here, I've always paid for software, especially support and it doesn't seem right that so far for Serviio I've not paid anything, is there any place I can make a donation to the cause?

Martyn


you can check by either telnetting into the NAS or via FTP.

also you could check this thread for more information on setting up serviio on synology NAS systems.

viewtopic.php?f=14&t=1731

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 7:45 am
by mbnu99
THanks yet again,

I've bnot used inux/unix for 30 years and I'm still in re-learning mode. . . the current permissions are:

DS211> ls -l library
total 8
drwxr-xr-x 5 serviio users 4096 Jul 26 08:22 db
-rw-r--r-- 1 serviio root 138 Aug 6 2010 derby.propertie

which, if memory serves correctly, means the user (serviio in this case) has RWX permission and the group (users) only has RX. . .as does other.

I'm still unsure as to why this problem has occurred on a system that was running OK in the first place, is it a good idea to stop the service running before any reboot?

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 8:07 am
by mbnu99
I forgot to say I did use the guide patters put together, could not have got this far without it. . . he rocks eh?

Everything seems to be up and running OK again, after going through it for the past hour. . . the concern is still there over what went wrong in the first place.

Thanks for all your help
Martyn

Re: serviio service start then stops on Synology NAS

PostPosted: Tue Jul 26, 2011 3:39 pm
by zip
mbnu99 wrote:Finally how can I contribute to the work being done here, I've always paid for software, especially support and it doesn't seem right that so far for Serviio I've not paid anything, is there any place I can make a donation to the cause?

Martyn

There is a link on the home page. Donations are appreciated :)