In the last post we built an image of SQL server 2019 Linux hosted in Azure Container Instance for fast access to SQL server. So, your next question is probably, lets see some database action?
When you connect to SSMS its not different, the feel and look, is, SQL server. Lets have a tour.
I create a database and issue:
SELECT * FROM sys.databases
lets check the file location.
SELECT * FROM sys.sysaltfiles
The infamous /var/opt/ location, that’s nice to see.
What if you want to check the logs? I like doing this via the Azure portal. Go to the Container Instance under containers, you will see logs.
Go to the end of the file, you will see the database creation.
Now lets stop and start the container.
What happens to the yahoo database?
Does not exist after the container instance starts back up this is because they are stateless. A better solution if you want storage to be persisted is to use SQL server in AKS – Azure Kubernetes Service via persistent volume claims. Hopefully I can get a demo on that working for everyone.