Track/Artist Index and Search not available

Need help? Post your questions here.

Moderator: moderators

Track/Artist Index and Search not available

Postby djregular » Thu Jun 29, 2017 5:59 am

I'm currently running Subsonic off of a Raspberry Pi w/Raspbian as the OS, and a few days ago the following error appeared in the A-Z index:

Code: Select all
Exception   org.springframework.dao.TransientDataAccessResourceException
Message   PreparedStatementCallback; SQL [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]; S1000 General error java.util.NoSuchElementException in statement [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]; nested exception is java.sql.SQLException: S1000 General error java.util.NoSuchElementException in statement [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]
Java version   Oracle Corporation 1.8.0_121
Operating system   Linux 4.9.28+
Server   jetty-6.1.x
Memory   Used 60 of 132 MB
Stack trace   org.springframework.dao.TransientDataAccessResourceException: PreparedStatementCallback; SQL [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]; S1000 General error java.util.NoSuchElementException in statement [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]; nested exception is java.sql.SQLException: S1000 General error java.util.NoSuchElementException in statement [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]
   at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:106)
   at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:72)
   at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
   at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:607)
   at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:641)
   at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:670)
   at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:678)
   at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:710)
   at net.sourceforge.subsonic.dao.AbstractDao.query(AbstractDao.java:97)
   at net.sourceforge.subsonic.dao.MediaFileDao.getChildrenOf(MediaFileDao.java:86)
   at net.sourceforge.subsonic.service.MediaFileService.getChildrenOf(MediaFileService.java:205)
   at net.sourceforge.subsonic.service.MusicIndexService.createSortableArtists(MusicIndexService.java:176)
   at net.sourceforge.subsonic.service.MusicIndexService.getIndexedArtists(MusicIndexService.java:60)
   at net.sourceforge.subsonic.service.MusicIndexService.getMusicFolderContent(MusicIndexService.java:70)
   at net.sourceforge.subsonic.controller.ArtistsController.handleRequestInternal(ArtistsController.java:130)
   at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
   at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
   at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875)
   at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:807)
   at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)
   at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
   at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1093)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:265)
   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
   at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:166)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:142)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.wrapper.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:81)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:173)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.ui.logout.LogoutFilter.doFilter(LogoutFilter.java:110)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
   at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
   at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:149)
   at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1084)
   at net.sourceforge.subsonic.filter.RequestEncodingFilter.doFilter(RequestEncodingFilter.java:43)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1084)
   at net.sourceforge.subsonic.filter.ParameterDecodingFilter.doFilter(ParameterDecodingFilter.java:54)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1084)
   at net.sourceforge.subsonic.filter.BootstrapVerificationFilter.doFilter(BootstrapVerificationFilter.java:59)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1084)
   at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:360)
   at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
   at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
   at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)
   at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
   at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
   at org.mortbay.jetty.Server.handle(Server.java:313)
   at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:506)
   at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:830)
   at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:514)
   at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
   at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
   at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:396)
   at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)
Caused by: java.sql.SQLException: S1000 General error java.util.NoSuchElementException in statement [select id, path, folder, type, format, title, album, artist, album_artist, disc_number, track_number, year, genre, bit_rate, variable_bit_rate, duration_seconds, file_size, width, height, cover_art_path, parent_path, play_count, last_played, comment, created, changed, last_scanned, children_last_updated, present, version from media_file where parent_path=? and present]
   at org.hsqldb.jdbc.Util.throwError(Unknown Source)
   at org.hsqldb.jdbc.jdbcPreparedStatement.executeQuery(Unknown Source)
   at org.springframework.jdbc.core.JdbcTemplate$1.doInPreparedStatement(JdbcTemplate.java:648)
   at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:591)
   ... 64 more


Also searching for anything turned up no results. I'm able to access songs in the 'Recently Played' or 'Recently Added' queue, but anything else produced the above error. I'm currently running 6.1 and haven't tried upgrading yet. If upgrading could solve the problem, any pointers on the best way to upgrade via Raspbian would be appreciated.
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am

Re: Track/Artist Index and Search not available

Postby djregular » Fri Jun 30, 2017 1:12 am

Update: Upgraded to 6.1.1 and it didn't help. Didn't make things any worse, thankfully.
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am

Re: Track/Artist Index and Search not available

Postby alphawave7 » Fri Jun 30, 2017 3:58 am

S1000 error generally indicates a corrupt db, often after a java update, for whatever reason (improper service shutdown is suspected). You can try renaming to old.db, and rebuild your db, but you will lose existing users/settings/etc. Once fixed, back this db up..and keep current backups handy for this issue in the future.
alphawave7
 
Posts: 1042
Joined: Thu Feb 11, 2010 9:54 am

Re: Track/Artist Index and Search not available

Postby djregular » Fri Jun 30, 2017 7:12 am

So I tried to clear the database to try and save my settings, users, etc by stopping subsonic, and doing the following:
Code: Select all
1. Backed up /var/subsonic/db/subsonic.script file
"cp /var/subsonic/db/subsonic.script /root/"
2. Deleted the contents of my /var/subsonic/db/ directory
"rm /var/subsonic/db/*"
3. Restored subsonic.script file
"cp /root/subsonic.script /var/subsonic/db/"


And it appeared to work, no errors returned and I was able to log in successfully. But I've been trying to scan my library and it's getting stuck at 1. Even after a reboot and making sure to run from admin. If I need to delete the old db entirely, let me know how to actually rebuild the db if I'm mistaken on the process. Otherwise, is there a reason that the scanning process would hang like this? When I was getting the error, I could still manage to play music, I just wasn't able to access it via the index.

Thanks in advance!
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am

Re: Track/Artist Index and Search not available

Postby djregular » Sat Jul 01, 2017 2:40 am

Update: So, I've done the following to try and get the scan to progress past 1 file:
1. Unmounted and remounted the drive where the files are located.
2. Various restarts of the Pi and Subsonic.
3. Created a new location to mount the drive to, and pointed Subsonic to it.

That last step did result in some progress. The scanning now updated to 2, and less than half of my files do show up in the 'recently added' section. I've also checked, and all of my files are still present, there's just something keeping Subsonic from progressing the scan. It doesn't ever stop, but it doesn't move any further.
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am

Re: Track/Artist Index and Search not available

Postby djregular » Sun Jul 09, 2017 4:39 pm

Bumping this thread. Eventually, the scan seemed to progress (albeit slowly) as normal, and eventually all my files showed back up. Unfortunately, shortly afterward, I was back to square one after clearing my database. Scanning files stuck at 1, no files visible in Subsonic, but all my files on disk are still there.

I'm wagering that I'll have to start over from the beginning, but if there's any assistance anyone can offer, I'd appreciate it.
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am

Extremely slow scanning and database problems

Postby djregular » Sat Aug 12, 2017 3:24 am

Bumping this thread, one more time. My Subsonic routine has basically devolved into this:

djregular wrote:So I tried to clear the database to try and save my settings, users, etc by stopping subsonic, and doing the following:
Code: Select all
1. Backed up /var/subsonic/db/subsonic.script file
"cp /var/subsonic/db/subsonic.script /root/"
2. Deleted the contents of my /var/subsonic/db/ directory
"rm /var/subsonic/db/*"
3. Restored subsonic.script file
"cp /root/subsonic.script /var/subsonic/db/"


And it appeared to work, no errors returned and I was able to log in successfully. But I've been trying to scan my library and it's getting stuck at 1.


From there, after a LONG time (somewhere in-between 24 to 48 hours), then scan eventually finishes, at a certain jumping up to a much larger file number. Then I'm able to use Subsonic normally for anywhere from a few days to about a week before I get some sort of input/output database error.

Do I have any other recourse aside from completely scrapping the DB entirely? I'll say it again, if I need to delete the old db entirely, please let me know how to actually rebuild the db if I'm mistaken on the process. Otherwise, is there a reason that the scanning process would hang like this? Is it possibly a java issue?
djregular
 
Posts: 7
Joined: Sat Feb 21, 2015 3:03 am


Return to Help

Who is online

Users browsing this forum: No registered users and 28 guests