Are we now seeing just a frisson of excitement amongst database professionals at the potential of virtualization, and containerization technologies? I read with interest Andrew Pruski’s recent post on SQL Server and containers. Wow, I thought: so I can now run a Docker SQL Server Express in a Hyper-V Container on Windows Server 2016! Then I hesitated: but is this really going to be useful to me?
I’ve always considered the use of virtualization and containerization, as a means of provisioning a database server, to be of more interest to developers and testers, rather than DBAs and Ops people, because the hardware configuration is so important for the consistent performance of production database servers.
Indeed, it is in development and testing that use of Virtual Machines and containers has now become more commonplace; it is now relatively simple to set up virtual test environments for each developer, where they can install all the processes they need, including SQL Server, to run their tests. However, it’s still basically one instance per VM. What if a team wants to run multiple parallel database tests against realistic volumes of data? Surely, they can simply spin up multiple ‘containerized’ instances of SQL Server ‘on demand’, automate the install and configuration of SQL Server, load the data, run the tests, then immediately tear them down again? However, I don’t know many teams who are doing database testing in this way. Maybe all it needs is that flash of inspiration while wrestling with the technology to start to understand better how these technologies solve real problems.
At Redgate, we run an extraordinary number of tests, numbered in their thousands, whilst releasing a tool like SQL Compare or SQL Backup, using VMs. However, the step of provisioning a database with realistic data, for these tests, remained laborious. This chore inspired a developer to think of a creative way of exploiting VM technology, and the idea of SQL Clone was born. This tool just uses standard virtualization technology baked into Windows. A database clone is just a Virtual Hard Disk (VHD) mount point, holding the source data image of the database, plus a differencing disk, to which SQL Server unwittingly writes any changes we make to the data in the clone. SQL server writes to a disk as usual, but the same clone can be mounted on as many machines as you need for your test or development work, and the build and tear down is quick and relatively painless. As with the taming of Containerization to produce Docker, the rest was the struggle to make the technology easy for the end user to install and manage.
This makes me wonder if there are other ways of exploiting the virtualization technology in both Linux and Windows to solve problems. Containerization, especially Docker, can be convenient, but there is, surely, a lot of other ways that the technology behind PaaS and Virtual Machines can be exploited to make our working lives easier?
I’d be interested to hear if you are using virtualization and containerization as part of database development and testing work? Are there good reasons still to be wary?