github externals fail after server move

Hi,

I've moved our TeamCity installation from one physical server to another one today, and after the move, our subversion externals against github are failing. New server running CentOS with bundled OpenJDK.

Old java version

java version "1.7.0_09-icedtea"
OpenJDK Runtime Environment (rhel-2.3.8.0.el6_4-x86_64)
OpenJDK 64-Bit Server VM (build 23.7-b01, mixed mode)


New java version
java version "1.7.0_85"
OpenJDK Runtime Environment (rhel-2.6.1.3.el6_7-x86_64 u85-b01)
OpenJDK 64-Bit Server VM (build 24.85-b03, mixed mode)

[2015-08-18 13:47:20,642]   WARN [rmal executor 6] -  jetbrains.buildServer.VCS.SVN - Cannot process externals: svn: E175002: java.security.ProviderException: java.security.KeyException
svn: E175002: OPTIONS request failed on '/pathongithub/trunk'
Externals URL: https://github.com/pathongithub/trunk
Current path: /localpath/externalpath
Connection URL: https://vcs.example.com/svn/projects/trunk
org.tmatesoft.svn.core.SVNException: svn: E175002: java.security.ProviderException: java.security.KeyException
svn: E175002: OPTIONS request failed on '/pathongithub/trunk'
     at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:106)
     at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:90)
     at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:750)
     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.getRepositoryUUID(DAVRepository.java:148)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.newConnection(SvnConnection.java:277)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.newConnection4Externals(SvnConnection.java:259)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection$7.runAction(SvnConnection.java:747)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.processAllExternals(SvnConnection.java:310)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.processExternalsExport(SvnConnection.java:737)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.exportFilesForDirectory(SvnConnection.java:725)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.exportFiles(SvnConnection.java:679)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnConnection.buildPatch(SvnConnection.java:613)
     at jetbrains.buildServer.buildTriggers.vcs.svn.SvnSupport$SvnIncludeRulePatchBuilder.buildPatch(SvnSupport.java:430)
     at jetbrains.buildServer.vcs.VcsSupportUtil.buildPatch(VcsSupportUtil.java:154)
     at jetbrains.buildServer.serverSide.impl.projectSources.BuildPatchUtil.buildPatch(BuildPatchUtil.java:2)
     at jetbrains.buildServer.serverSide.impl.projectSources.PatchComposer.buildCleanPatch(PatchComposer.java:87)
     at jetbrains.buildServer.serverSide.impl.projectSources.PatchComposer.makePatch(PatchComposer.java:103)
     at jetbrains.buildServer.serverSide.impl.projectSources.PatchComposer.buildPatchForRoot(PatchComposer.java:34)
     at jetbrains.buildServer.serverSide.impl.projectSources.PatchComposer.buildPatch(PatchComposer.java:170)
     at jetbrains.buildServer.serverSide.impl.BuildTypeImpl.buildPatch(BuildTypeImpl.java:375)
     at jetbrains.buildServer.serverSide.impl.BuildStarter$2.call(BuildStarter.java:9)
     at java.util.concurrent.FutureTask.run(FutureTask.java:262)
     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
     at java.lang.Thread.run(Thread.java:745)
Caused by: javax.net.ssl.SSLException: java.security.ProviderException: java.security.KeyException
     at sun.security.ssl.Alerts.getSSLException(Alerts.java:208)
     at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1916)
     at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1874)
     at sun.security.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1857)
     at sun.security.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1783)
     at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:127)
     at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
     at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
     at org.tmatesoft.svn.core.internal.util.SVNLogOutputStream.flush(SVNLogOutputStream.java:48)
     at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.sendData(HTTPConnection.java:314)
     at org.tmatesoft.svn.core.internal.io.dav.http.HTTPRequest.dispatch(HTTPRequest.java:168)
     at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:450)
     ... 28 more
Caused by: java.security.ProviderException: java.security.KeyException
     at sun.security.ec.ECKeyPairGenerator.generateKeyPair(ECKeyPairGenerator.java:146)
     at java.security.KeyPairGenerator$Delegate.generateKeyPair(KeyPairGenerator.java:704)
     at sun.security.ssl.ECDHCrypt.<init>(ECDHCrypt.java:78)
     at sun.security.ssl.ClientHandshaker.serverKeyExchange(ClientHandshaker.java:714)
     at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:278)
     at sun.security.ssl.Handshaker.processLoop(Handshaker.java:913)
     at sun.security.ssl.Handshaker.process_record(Handshaker.java:849)
     at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1035)
     at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1344)
     at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:721)
     at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122)
     ... 34 more
Caused by: java.security.KeyException
     at sun.security.ec.ECKeyPairGenerator.generateECKeyPair(Native Method)
     at sun.security.ec.ECKeyPairGenerator.generateKeyPair(ECKeyPairGenerator.java:126)


... 44 more
3 comments
Comment actions Permalink

Seems to work with a newer Java,

openjdk version "1.8.0_51"
OpenJDK Runtime Environment (build 1.8.0_51-b16)
OpenJDK 64-Bit Server VM (build 25.51-b03, mixed mode)


But I couldn't run our old TeamCity with that version, perhaps it's time to upgrade. Or is there a quick solution? Tried adding the certificate to the cert store without any luck.

0
Comment actions Permalink

We hit the exact same issue with 'rhel-2.6.1.3.el6_7-x86_64'. I can also confirm that 'rhel-2.6.1.3.el6_6-x86_64' works fine.

If anyone knows the source/cause of the problem it would be good to hear what it is. Thanks in advance.

0
Comment actions Permalink

Looks some internal error in Java 1.7. Haven't found a specific workaround, sit I bit the apple and upgraded to latest TeamCity and Java 1.8.

0

Please sign in to leave a comment.