This is one of the most common error seen during svn sync. I myself spent some pretty good time to figure out the perfect solution for this error. After few iterations, I came up with different solutions which are given below.

Solution 1:

Accept the certificate permanently by removing “–non-interactive” from command

$ /usr/bin/svnsync synchronize svn://222.222.222.222/ –username svnsync –password ‘*********’
Error validating server certificate for ‘https://xx.xxx.com:443’:
– The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
Certificate information:
– Hostname: xxx.xxxx.net
– Valid: from Mon, 11 Jun 2012 10:17:07 GMT until Tue, 11 Jun 2013 10:17:07 GMT
– Issuer: SVN,
– Fingerprint: ac:a0:8d:85:10:7c:05:57:97:83:f0:2d:f6:46:34:86:75:f3:2d:cc
(R)eject, accept (t)emporarily or accept (p)ermanently? p

Press “p”. Now the certificate will be stored permanently and now it should work without any intervention.

Solution 2:

There are times when solution one doesn’t work, like in my case, so you can try the next idea. Run the command like this

$ /usr/bin/svnsync synchronize svn://222.222.222.222/ –username svnsync –password ‘*********’ –config-dir /xyz/zyx

This will again ask whether to accept the certificate or not, which again you should press “p” and accept it permanently.

Once done, in your post-commit file use the same thing,

/usr/bin/svnsync synchronize svn://222.222.222.222/ –username svnsync –password ‘*********’ –non-interactive –config-dir /xyz/zyx

This will hopefully solve your issue, which did in my case.

Solution 3:

This is a solution when everything else fails. Put this command in your post-commit file:

/usr/bin/svnsync synchronize svn://222.222.222.222/ –username svnsync –password ‘*********’ –non-interactive¬†–trust-server-cert

This will trust any server¬†certificate¬†provided by the server. Though it’s not recommended, as it’s a security risk, but if you are running an in-house SVN with your own certificate and everything else is failing, this is something which you can give a shot.

Hopefully this all will be helpful to you. If there are other ways also to solve this issue, please let me know and I would like to update it in my blog.

If you enjoyed this post, make sure you subscribe to my RSS feed!!!!