Not Your Dad's IT

Updated Solutions to Classic Challenges

A personal website dedicated to helping IT professionals review where we've been, where we are, and maybe where we are headed.

  • Blog
  • About
  • Disclaimer
SQL_Server_Logo_01.PNG

Install SQL Server 2019 via Docker Container on Windows 10

September 25, 2018 by Nathaniel Avery

One of the big announcements from the Microsoft Ignite Conference was SQL Server 2019 being made available for public preview. Public preview means the software isn’t very far from being made generally available (GA) to everyone as a finished product. IT Pros who support SQL Server typically take a look at the new version to investigate features and understand how the software might fit into their environment. In this post I show an easy way for IT pros to try using SQL Server 2019 on a Windows 10 computer running Docker.

Assumption - Docker is already running on your Windows 10 computer. I’m making this assumption to avoid walking through install and setup of Docker on Windows 10.

Step 1. Download the software

Downloading the software is pretty easy, but it requires you know the name and repo location from where it can be retrieved. At the time of this writing, the container label is “vNext-CTP2.0-ubuntu“ and it can be found on docker hub at “docker pull mcr.microsoft.com/mssql/server .”

The full pull command looks like this:

docker pull mcr.microsoft.com/mssql/server:vNext-CTP2.0-ubuntu

Image01_Pull_container.PNG


Step 2. Run the Downloaded Container

The next step is to run the container. To do so, the End User License Agreement (EULA) must be agreed upon, a password for the sa user must be set, the port to bind the container to, and a name needs to be assigned to the container as well as the image being run.

Note: Because this is a Windows example, the quotation marks are double quotes instead of single quotes.

docker run -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=Pa33word" -p1433:1433 --name sql2019 -d mcr.microsoft.com/mssql/server:vNext-CTP2.0-ubuntu


Image01_run_conatainer.PNG


Verify it’s running by issuing the docker ps command.

Image01_verify_conatainer.PNG


Step 3. Connect to SQL Server

Connect to SQL Server using either SQL Server Management Studio or SQL Server Operations Studio. Use the sa account and the password provided in step 2 when running the container.

Image01_SQL_Operations_Studio_Connection.PNG

You’ll notice that even though you are on a Windows machine, SQL Operations Studio displays the OS as Ubuntu. This is because the container running the SQL Server binaries is ubuntu based.

Image01_SQL_Operations_Studio_General.PNG

The SQL version appears in the general info screen, but it can also be verified in a query window by executing using select @@version. SQL Server 2019 releases should start with 15.x.x.

Image01_SQL_Operations_Studio_Version.PNG

References

Docker hub Public Repository for SQL Server https://hub.docker.com/r/microsoft/mssql-server/

Introducing SQL Server 2019 - https://www.microsoft.com/en-us/sql-server/sql-server-2019#Install









September 25, 2018 /Nathaniel Avery
SQL, SQL Server, Docker, Windows, Windows 10, containers
  • Newer
  • Older

Powered by Squarespace