Solved

Query Result [Microsoft.SqlServer.Management.Common.ExecutionFailureException:Cannot find server asymmetric key with thumbprint

  • 4 February 2022
  • 4 replies
  • 1540 views

Badge +7

Query Result [Microsoft.SqlServer.Management.Common.ExecutionFailureException:Cannot find server asymmetric key with thumbprint '0x30364636353638383632373739364134'. RESTORE DATABASE is terminating abnormally. An exception occurred while executing a Transact-SQL statement or batch.]. Source:

icon

Best answer by Stuart Painter 4 February 2022, 13:55

View original

If you have a question or comment, please create a topic

4 replies

Userlevel 7
Badge +15

Hi @Alexzy 

Please would you provide some more details so we have a little more context about what you are trying to achieve, that will help the Community understand and provide some help.

Reviewing the error, I can make a few assumptions.

The restore error suggests that you have backed up an encrypted SQL database and you are attempting an out of place restore to another server.

I’m assuming the key mentioned in the error is found in the source SQL Server, but isn’t present in the destination server, so decryption fails.

Assuming this is the case, you will need to create a master certificate in the destination server and transfer certificate from the source SQL server before attempting to restore the encrypted database.

That way, on restore, the certificate will be found which will allow the database to be decrypted in the destination server.

Thanks,

Stuart

Badge +7

Exactly we are trying to do out of place restor.

how do i create a master certificate? 

 

Userlevel 7
Badge +15

Hi @Alexzy 

Please take a look at these Microsoft guides for managing TDE keys in SQL Server:
SQL Server and Database Encryption Keys (Database Engine)

Create a Database Master Key

Move a TDE Protected Database to Another SQL Server

Thanks,

Stuart

Badge +7

Thank you very much. I was able to resolve the issue with the URL in your response.