Sql-server – Mirroring problems after removing domain

mirroringsql serversql-server-2008

I successfully created a mirror with certificates between two servers. One of those servers was a domain controller. After removing the domain the mirror was interrupted. After hours of searching I reinstalled SQL Server hoping all possible domain removal issues would be gone, but still the mirror refuses to work. I keep getting the vague error:

Msg 1418, Level 16, State 1, Line 1
The server network address "TCP://…" can not be reached or does not exist. Check the network address name and that the ports for the local and remote endpoints are operational.

If I check the eventlog of the mirrorserver I see 2 errors:

  1. 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.
  2. A system cryptographic call failed during a Service Broker or Database Mirroring operation: system error '5(failed to retrieve text for this error. Reason: 15105)'.

Any ideas/suggestions?

Best Answer

After days of searching, I found the answer 10 minutes after this post. The problem was that the admin account did not have read/write rights on c:\ProgramData\Microsoft\Crypto\RSA\MachineKeys\ . After changing that I also had to recreate the master keys and certificates to make it work.