We have a Service Broker application where we’re communicating between two SQL Server instances on two separate, non-domain machines. One of our test configurations is failing in a mode we’ve never seen before. Similarly-configured systems seem to work fine, and SSBDiagnose doesn’t indicate any problems.
Here are the errors we’re seeing:
One side logs this error:
An error occurred while receiving data: ‘10054(An existing connection was forcibly closed by the remote host.)’.
The other side of the system logs these errors in the SQL Server log:
2012-04-24 10:45:52.58 spid17s Error: 9650, Severity: 16, State: 5. 2012-04-24 10:45:52.58 spid17s A system cryptographic call failed during a Service Broker or Database Mirroring operation: system error '5(Access is denied.)'. 2012-04-24 10:45:52.59 spid17s Error: 9641, Severity: 16, State: 12. 2012-04-24 10:45:52.59 spid17s A cryptographic operation failed. This error indicates a serious problem with SQL Server. Check the SQL Server error log and the Windows event logs for further information. 2012-04-24 10:45:52.59 Logon Service Broker login attempt failed with error: Connection handshake failed. An OS call failed: (0) (null). State 87.'. [CLIENT: 192.168.220.3]
We’re guessing that the issue is with our certificate configuration, but reinstalling certificates as if we were rebuilding the system from scratch did not help.
Has anyone seen these errors before or have any idea what failure they’re pointing to?
I’ve seen this before and it always was an issue of some rogue application restricting access to the RSA key store. I never been able to locate the culprit that changes permissions… Is is not Service Broker specific, other apps run into same issue eg. RSA Key Store Permissions
The solution is to grant read-write permission to the SQL Server service account on the directory
\ProgramData\Microsoft\Crypto\RSA\MachineKeysand all contained files.If the problem persist, contact product support.
Update. Of yes, I remeber: there is an KB article for the issue, Error message when you use Service Broker or database mirroring to connect to an instance of SQL Server 2005: “Connection handshake failed”. I should had remember, I wrote the stub for that KB 🙂