Uncover the Secret to Solving That "Trust Server Certificate Connection Error" in Azure Data Studio!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in this video we're going to have a look at the server certificate connection error when creating a new connection with SQL server in Azure data Studio hello I'm Philip Burton of I do data.com when you create a new connection in Azure data Studio you may see this connection error message a connection will successfully established with the server but then an error occurred during the login process the error the certificate chain was issued by an authority which is not trusted so under what circumstances do we see this error and what should we do about it so I'm going to click on a close and cancel to get me back to a blank Azure data Studio screen and then under connections I'm going to add a connection to a new server by clicking on this Plus so I'll click on a server that I've previously used and click connect and that generates the error so what's happening more recent versions of azure data Studio have enabled encryption on any new connections this means that data sent between you and the server is encrypted so that it cannot be easily intercepted on Route however as part of the encryption process Azure data Studio checks the server certificate for your SQL Server now if you're using Azure SQL database then that does support encrypted connections and will have a trusted certificate so you will not see this dialog box however if you're connecting to on-premises SQL server or SQL server in a virtual machine then Azure data Studio checks to see if the SQL Server that you're connecting with has a certificate from a trusted certificate Authority in other words one that you pay for and then you authenticate who you are so that's why it is a trusted certificate if however you installed for instance SQL Server developer or Express on your computer you will not have a certificate from a trusted certificate Authority it will be a self-signed certificate so you've got two options firstly you can ask whoever is administering your SQL Server to get a certificate from a trusted certificate Authority however that will take time and a bit of money alternatively you can say I want to trust the self-signed service certificate that is on the connection now notice it says a self-signed certificate offers only limited protection and is not a recommended practice for production environments so if you've got a production environment in other words you have installed SQL server on a server at your office it should ideally have a certificate from a trusted certificate Authority and then this error won't come up if you don't have that so you're connecting say to your own machine a Developer Edition you can click on enable trust server certificate if I close this an alternate way of doing this is when you're connecting go down to the trust server certificate and change it from the default false to true and now when you connect then it trusts your server certificate whether it is self-signed or whether it is from a trusted certificate Authority well I hope you've enjoyed this video if you'd like more information about how to use Azure data Studio then there will be a video link on the end screen coming up please click on it to find out how to use Azure data studio if you'd like some help creating your tsql select statement then please go to my website I do data.com where you will see a variety of courses about SQL server or why not have a look on this YouTube channel to see more videos I hope you enjoyed this video if you did then why not click that like And subscribe and click that Bell that way you'll be notified of any new videos I'm Phillip Burton of I do data.com thank you very much for watching and keep learning
Info
Channel: SQL Server 101
Views: 5,502
Rating: undefined out of 5
Keywords: sql server, sql, microsoft sql server, sql server learn, sql server videos, azure data studio, Enable trust server certificate, azure connection error, certificate chain was issued, certificate chain was issued by an authority that is not trusted, trust server certificate, azure new connection error
Id: e-Oz_FCz62A
Channel Id: undefined
Length: 4min 10sec (250 seconds)
Published: Thu Mar 09 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.