org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'

Jenkins JIRA | Torsten Krah | 6 years ago
  1. 0

    Hudson does rewrite the authentication file under ${user.home}/.subversion/auth/svn.simple/$file and does not insert credentials stuff. I am using a custom build which does use the command line client (in addition to the normal svn usage of the hudson project) - so the credentials are important to be in there. My custom project is broken every time hudson does rewrite those authentication cache file from subversion. Is it possible to configure hudson not to do this rewrite or to insert those credentials when the rewrite does happen? The only workaround found is to set the immutable bit (removing write privileges is not enough) as root user to the file in question which hudson is not able to workaround (which is expected here and good). Project does build but the log grows with these exception trace: Nov 10, 2010 10:54:47 AM hudson.scm.SubversionSCM$CheckOutTask invoke INFO: Failed to estimate the remote time stamp org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64) at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.rename(SVNFileUtil.java:552) at org.tmatesoft.svn.core.internal.wc.SVNWCProperties.setProperties(SVNWCProperties.java:352) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager$PersistentAuthenticationProvider.saveAuthentication(DefaultSVNAuthenticationManager.java:810) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:276) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:606) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.info(DAVRepository.java:724) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:698) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:596) at hudson.FilePath.act(FilePath.java:753) at hudson.FilePath.act(FilePath.java:735) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:589) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:537) at hudson.model.AbstractProject.checkout(AbstractProject.java:1119) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:479) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:411) at hudson.model.Run.run(Run.java:1324) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:139) Of cause it can not rename the file, the immutable bit is set and only the root user is able to change this or any process which got the CAP_LINUX_IMMUTABLE capability bit set - of cause my hudson process does not get this privilege. So anything i can do to get rid of those subversion problem without this "workaround"?

    Jenkins JIRA | 6 years ago | Torsten Krah
    org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'
  2. 0

    Hudson does rewrite the authentication file under ${user.home}/.subversion/auth/svn.simple/$file and does not insert credentials stuff. I am using a custom build which does use the command line client (in addition to the normal svn usage of the hudson project) - so the credentials are important to be in there. My custom project is broken every time hudson does rewrite those authentication cache file from subversion. Is it possible to configure hudson not to do this rewrite or to insert those credentials when the rewrite does happen? The only workaround found is to set the immutable bit (removing write privileges is not enough) as root user to the file in question which hudson is not able to workaround (which is expected here and good). Project does build but the log grows with these exception trace: Nov 10, 2010 10:54:47 AM hudson.scm.SubversionSCM$CheckOutTask invoke INFO: Failed to estimate the remote time stamp org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64) at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.rename(SVNFileUtil.java:552) at org.tmatesoft.svn.core.internal.wc.SVNWCProperties.setProperties(SVNWCProperties.java:352) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager$PersistentAuthenticationProvider.saveAuthentication(DefaultSVNAuthenticationManager.java:810) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:276) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:606) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.info(DAVRepository.java:724) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:698) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:596) at hudson.FilePath.act(FilePath.java:753) at hudson.FilePath.act(FilePath.java:735) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:589) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:537) at hudson.model.AbstractProject.checkout(AbstractProject.java:1119) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:479) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:411) at hudson.model.Run.run(Run.java:1324) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:139) Of cause it can not rename the file, the immutable bit is set and only the root user is able to change this or any process which got the CAP_LINUX_IMMUTABLE capability bit set - of cause my hudson process does not get this privilege. So anything i can do to get rid of those subversion problem without this "workaround"?

    Jenkins JIRA | 6 years ago | Torsten Krah
    org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'
  3. 0

    Jenkins does want to rewrite the authentication svn files, but is not permitted to do so (which is intentional). The operation itself would succeed because credentials are correct, but because jenkins is unable to rename those file, exception is thrown and the complete operation is aborted. {noformat} org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/jenkins/.subversion/auth/svn.simple/auth.b4497712-3201-0010-92fc-211d0dd7ba71.tmp' to '/home/jenkins/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64) at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.rename(SVNFileUtil.java:552) at org.tmatesoft.svn.core.internal.wc.SVNWCProperties.setProperties(SVNWCProperties.java:352) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager$PersistentAuthenticationProvider.saveAuthentication(DefaultSVNAuthenticationManager.java:810) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:276) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:606) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.info(DAVRepository.java:724) at hudson.scm.SubversionSCM$CheckOutTask.checkClockOutOfSync(SubversionSCM.java:731) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:708) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:690) at hudson.FilePath.act(FilePath.java:758) at hudson.FilePath.act(FilePath.java:740) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:683) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:632) at hudson.model.AbstractProject.checkout(AbstractProject.java:1193) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:555) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:443) at hudson.model.Run.run(Run.java:1376) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(Resource {noformat} Jenkins should be able to use entered credentials, but must no rewrite them when there is no need to to so, because they are not changed - at least it should not fail the complete op if credentials are successfull but caching them does fail (because their are already valid credentials writte to the file). This is related to: https://issues.jenkins-ci.org/browse/JENKINS-8059 where the same behaviour is already described, but i was advised to open a seperate bug for this one.

    Jenkins JIRA | 5 years ago | Torsten Krah
    org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/jenkins/.subversion/auth/svn.simple/auth.b4497712-3201-0010-92fc-211d0dd7ba71.tmp' to '/home/jenkins/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Jenkins does want to rewrite the authentication svn files, but is not permitted to do so (which is intentional). The operation itself would succeed because credentials are correct, but because jenkins is unable to rename those file, exception is thrown and the complete operation is aborted. {noformat} org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/jenkins/.subversion/auth/svn.simple/auth.b4497712-3201-0010-92fc-211d0dd7ba71.tmp' to '/home/jenkins/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64) at org.tmatesoft.svn.core.internal.wc.SVNFileUtil.rename(SVNFileUtil.java:552) at org.tmatesoft.svn.core.internal.wc.SVNWCProperties.setProperties(SVNWCProperties.java:352) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager$PersistentAuthenticationProvider.saveAuthentication(DefaultSVNAuthenticationManager.java:810) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:276) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:606) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.info(DAVRepository.java:724) at hudson.scm.SubversionSCM$CheckOutTask.checkClockOutOfSync(SubversionSCM.java:731) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:708) at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:690) at hudson.FilePath.act(FilePath.java:758) at hudson.FilePath.act(FilePath.java:740) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:683) at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:632) at hudson.model.AbstractProject.checkout(AbstractProject.java:1193) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:555) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:443) at hudson.model.Run.run(Run.java:1376) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(Resource {noformat} Jenkins should be able to use entered credentials, but must no rewrite them when there is no need to to so, because they are not changed - at least it should not fail the complete op if credentials are successfull but caching them does fail (because their are already valid credentials writte to the file). This is related to: https://issues.jenkins-ci.org/browse/JENKINS-8059 where the same behaviour is already described, but i was advised to open a seperate bug for this one.

    Jenkins JIRA | 5 years ago | Torsten Krah
    org.tmatesoft.svn.core.SVNException: svn: Cannot rename file '/home/jenkins/.subversion/auth/svn.simple/auth.b4497712-3201-0010-92fc-211d0dd7ba71.tmp' to '/home/jenkins/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'
  6. 0

    Usually config is stored in {{~/.subversion}} but we can pass [ISVNOptions|http://www.svnkit.com/javadoc/org/tmatesoft/svn/core/wc/ISVNOptions.html] to {{SVNClientManager.newInstance(null, auth);}} instead of {{null}}. This should allow us to not attempt to cache credentials... {code} 08:36:40,151 ERROR SvnPollerTask,org.springframework.scheduling.quartz.SchedulerFactoryBean#0_Worker-7:129 - Early setup sanity check failed. org.tmatesoft.svn.core.SVNException: svn: E204899: Cannot create directory '/home/kmstst/.subversion/auth/svn.simple' at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64) at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:51) at org.tmatesoft.svn.core.internal.wc.DefaultSVNPersistentAuthenticationProvider.saveAuthentication(DefaultSVNPersistentAuthenticationProvider.java:300) at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:232) at org.tmatesoft.svn.core.auth.BasicAuthenticationManager.acknowledgeAuthentication(BasicAuthenticationManager.java:56) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:712) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:365) at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:353) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.performHttpRequest(DAVConnection.java:708) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:628) at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:103) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1016) at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getLatestRevision(DAVRepository.java:180) at org.kuali.kits.kms.repository.svn.SvnPollerTask.sanityCheck(SvnPollerTask.java:69) {code}

    Kuali JIRA | 3 years ago | Weldon Sams
    org.tmatesoft.svn.core.SVNException: svn: E204899: Cannot create directory '/home/kmstst/.subversion/auth/svn.simple'

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.tmatesoft.svn.core.SVNException

      svn: Cannot rename file '/home/hudson/.subversion/auth/svn.simple/auth.d17e3535-2c01-0010-81b2-1f57b38e3f1e.tmp' to '/home/hudson/.subversion/auth/svn.simple/1755861b3f63d264955a25532195c4f8'

      at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error()
    2. SVNKit Library
      DAVRepository.info
      1. org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:64)
      2. org.tmatesoft.svn.core.internal.wc.SVNFileUtil.rename(SVNFileUtil.java:552)
      3. org.tmatesoft.svn.core.internal.wc.SVNWCProperties.setProperties(SVNWCProperties.java:352)
      4. org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager$PersistentAuthenticationProvider.saveAuthentication(DefaultSVNAuthenticationManager.java:810)
      5. org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.acknowledgeAuthentication(DefaultSVNAuthenticationManager.java:276)
      6. org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:606)
      7. org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:275)
      8. org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:263)
      9. org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:516)
      10. org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:98)
      11. org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1001)
      12. org.tmatesoft.svn.core.internal.io.dav.DAVRepository.info(DAVRepository.java:724)
      12 frames
    3. Hudson
      Executor.run
      1. hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:698)
      2. hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:596)
      3. hudson.FilePath.act(FilePath.java:753)
      4. hudson.FilePath.act(FilePath.java:735)
      5. hudson.scm.SubversionSCM.checkout(SubversionSCM.java:589)
      6. hudson.scm.SubversionSCM.checkout(SubversionSCM.java:537)
      7. hudson.model.AbstractProject.checkout(AbstractProject.java:1119)
      8. hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:479)
      9. hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:411)
      10. hudson.model.Run.run(Run.java:1324)
      11. hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
      12. hudson.model.ResourceController.execute(ResourceController.java:88)
      13. hudson.model.Executor.run(Executor.java:139)
      13 frames