java.io.IOException: File C:\home\hudson\workspace\Nexus\jdk\1.6\label\windows\trunk\nexus\nexus-test-harness\nexus-test-harness-launcher\target\nexus\nexus-work-dir\tmp\ehcache\org.sonatype.security.realms.XmlAuthorizingRealm-345-authorization.data unable to be deleted.

Sonatype JIRA | 7 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    We NEED to completely disable the ehcache disk access, it should only be in memory. Periodically still seeing errors as follows in ITs java.io.IOException: File C:\home\hudson\workspace\Nexus\jdk\1.6\label\windows\trunk\nexus\nexus-test-harness\nexus-test-harness-launcher\target\nexus\nexus-work-dir\tmp\ehcache\org.sonatype.security.realms.XmlAuthorizingRealm-345-authorization.data unable to be deleted. at org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1279) at org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507) at org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458) at org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1272) at org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507) at org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458) at org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.cleanWorkDir(AbstractNexusIntegrationTest.java:282) at org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.beforeStartClean(AbstractNexusIntegrationTest.java:219) at org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.oncePerClassSetUp(AbstractNexusIntegrationTest.java:182)

    Sonatype JIRA | 7 years ago
    java.io.IOException: File C:\home\hudson\workspace\Nexus\jdk\1.6\label\windows\trunk\nexus\nexus-test-harness\nexus-test-harness-launcher\target\nexus\nexus-work-dir\tmp\ehcache\org.sonatype.security.realms.XmlAuthorizingRealm-345-authorization.data unable to be deleted.
  2. 0

    Using the Nexus UI, I deleted the "org" folder from my Maven central proxy. This took several minutes and then failed, turns out a build running at the same time which was pulling artifacts through the central proxy. Not sure what the exact algorithm used here is, but it looks like the we are traversing the directory and deleting contents? If this is the case this makes this sort of thing much more likely to happen. It would be safer to attempt rename the folder to a statistically unique name before deleting anything. If any files are in use this will fail, and you can safely abort the operation. {code} 2010-01-26 13:15:49 ERROR [qtp-10233621-19] - o.s.p.r.r.PlexusRes~:Reposit~ - IO error! org.sonatype.nexus.proxy.StorageException: Got IOException during wastebasket handling! at org.sonatype.nexus.proxy.wastebasket.DefaultFSWastebasket.delete(DefaultFSWastebasket.java:216) at org.sonatype.nexus.proxy.storage.local.AbstractLocalRepositoryStorage.deleteItem(AbstractLocalRepositoryStorage.java:189) at org.sonatype.nexus.proxy.repository.AbstractRepository.doDeleteItem(AbstractRepository.java:1197) at org.sonatype.nexus.proxy.repository.AbstractRepository.deleteItem(AbstractRepository.java:930) at org.sonatype.nexus.proxy.repository.AbstractRepository.deleteItem(AbstractRepository.java:591) at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.delete(AbstractResourceStoreContentPlexusResource.java:188) at org.sonatype.plexus.rest.resource.RestletResource.removeRepresentations(RestletResource.java:357) at org.sonatype.nexus.rest.NexusRestletResource.removeRepresentations(NexusRestletResource.java:109) at org.restlet.resource.Resource.delete(Resource.java:223) at org.restlet.resource.Resource.handleDelete(Resource.java:383) at org.restlet.Finder.handle(Finder.java:361) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.sonatype.plexus.rest.RetargetableRestlet.doHandle(RetargetableRestlet.java:39) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at com.noelios.restlet.StatusFilter.doHandle(StatusFilter.java:130) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at com.noelios.restlet.application.ApplicationHelper.handle(ApplicationHelper.java:112) at org.restlet.Application.handle(Application.java:341) at org.restlet.ext.wadl.WadlApplication.handle(WadlApplication.java:705) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at org.restlet.Component.handle(Component.java:673) at org.restlet.Server.handle(Server.java:331) at com.noelios.restlet.ServerHelper.handle(ServerHelper.java:68) at com.noelios.restlet.http.HttpServerHelper.handle(HttpServerHelper.java:147) at com.noelios.restlet.ext.servlet.ServerServlet.service(ServerServlet.java:881) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:52) at org.jsecurity.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:105) at org.jsecurity.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:135) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:57) at org.jsecurity.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:105) at org.jsecurity.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:135) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:57) at org.jsecurity.web.servlet.JSecurityFilter.doFilterInternal(JSecurityFilter.java:382) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:387) 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:765) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:326) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520) Caused by: org.sonatype.nexus.proxy.StorageException: Could not delete File in repository "Maven Central" (id="central") from path C:\nexus\nexus-professional-webapp-1.5.0\bin\jsw\windows-x86-32\..\..\..\..\sonatype-work\nexus\storage\central\org at org.sonatype.nexus.proxy.storage.local.fs.DefaultFSLocalRepositoryStorage.shredItem(DefaultFSLocalRepositoryStorage.java:595) at org.sonatype.nexus.proxy.wastebasket.DefaultFSWastebasket.delete(DefaultFSWastebasket.java:207) ... 78 more Caused by: java.io.IOException: Directory C:\nexus\nexus-professional-webapp-1.5.0\bin\jsw\windows-x86-32\..\..\..\..\sonatype-work\nexus\storage\central\org\apache\maven unable to be deleted. at org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1462) at org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1272) at org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507) at org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458) at org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1272) at org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507) at org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458) at org.sonatype.nexus.proxy.storage.local.fs.DefaultFSLocalRepositoryStorage.shredItem(DefaultFSLocalRepositoryStorage.java:591) ... 79 more 2010-01-26 13:15:49 ERROR [qtp-10233621-19] - o.s.n.e.r.ErrorRepo~ - Detected Error in Nexus org.restlet.resource.ResourceException: Got IOException during wastebasket handling! at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.handleException(AbstractResourceStoreContentPlexusResource.java:680) at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.delete(AbstractResourceStoreContentPlexusResource.java:196) at org.sonatype.plexus.rest.resource.RestletResource.removeRepresentations(RestletResource.java:357) at org.sonatype.nexus.rest.NexusRestletResource.removeRepresentations(NexusRestletResource.java:109) at org.restlet.resource.Resource.delete(Resource.java:223) at org.restlet.resource.Resource.handleDelete(Resource.java:383) at org.restlet.Finder.handle(Finder.java:361) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.sonatype.plexus.rest.RetargetableRestlet.doHandle(RetargetableRestlet.java:39) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at com.noelios.restlet.StatusFilter.doHandle(StatusFilter.java:130) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at com.noelios.restlet.application.ApplicationHelper.handle(ApplicationHelper.java:112) at org.restlet.Application.handle(Application.java:341) at org.restlet.ext.wadl.WadlApplication.handle(WadlApplication.java:705) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at org.restlet.Component.handle(Component.java:673) at org.restlet.Server.handle(Server.java:331) at com.noelios.restlet.ServerHelper.handle(ServerHelper.java:68) at com.noelios.restlet.http.HttpServerHelper.handle(HttpServerHelper.java:147) at com.noelios.restlet.ext.servlet.ServerServlet.service(ServerServlet.java:881) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:52) at org.jsecurity.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:105) at org.jsecurity.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:135) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:57) at org.jsecurity.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:105) at org.jsecurity.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:135) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.jsecurity.web.servlet.FilterChainWrapper.doFilter(FilterChainWrapper.java:57) at org.jsecurity.web.servlet.JSecurityFilter.doFilterInternal(JSecurityFilter.java:382) at org.jsecurity.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:180) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:387) 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:765) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:326) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520) {code}

    Sonatype JIRA | 7 years ago | Rich Seddon
    org.sonatype.nexus.proxy.StorageException: Got IOException during wastebasket handling!

Root Cause Analysis

  1. java.io.IOException

    File C:\home\hudson\workspace\Nexus\jdk\1.6\label\windows\trunk\nexus\nexus-test-harness\nexus-test-harness-launcher\target\nexus\nexus-work-dir\tmp\ehcache\org.sonatype.security.realms.XmlAuthorizingRealm-345-authorization.data unable to be deleted.

    at org.codehaus.plexus.util.FileUtils.forceDelete()
  2. Plexus Common Utilities
    FileUtils.deleteDirectory
    1. org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1279)
    2. org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507)
    3. org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458)
    4. org.codehaus.plexus.util.FileUtils.forceDelete(FileUtils.java:1272)
    5. org.codehaus.plexus.util.FileUtils.cleanDirectory(FileUtils.java:1507)
    6. org.codehaus.plexus.util.FileUtils.deleteDirectory(FileUtils.java:1458)
    6 frames
  3. org.sonatype.nexus
    AbstractNexusIntegrationTest.oncePerClassSetUp
    1. org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.cleanWorkDir(AbstractNexusIntegrationTest.java:282)
    2. org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.beforeStartClean(AbstractNexusIntegrationTest.java:219)
    3. org.sonatype.nexus.integrationtests.AbstractNexusIntegrationTest.oncePerClassSetUp(AbstractNexusIntegrationTest.java:182)
    3 frames