Deploying Application Virtual Machines Just Got A Whole Lot Quicker

Several years ago, I first heard Mark Minasi talk about accidental DBAs.  The term refers to server administrators/engineers who find that the vast majority of their Windows Servers either have or use a SQL Server installation.  We were mostly still in a physical world back then, with virtualisation just in its infancy in the industry (as a whole).  Things have moved on since then.  Anyone deploying servers now should be looking at the virtual option first (be it some open cloud, Xen, VMware, or Hyper-V).  Virtualisation seems to encourage server sprawl and that means lots more servers.

My last experience as a hands-own “own it” engineer was in hosting.  Here’s how a deployment looked:

  1. Time to deploy a VM: about 30 seconds in a wizard, and do something else while the files copied
  2. Customize the OS: about 1-10 minutes
  3. Install SQL Server: 30-45 minutes (longer if SQL 2008 R2 Reporting was required)
  4. Install the SQL Server service pack (if not already slipstreamed): 30-45 minutes
  5. Install the SQL Server service pack cumulative update (if not already slipstreamed): 30-45 minutes

In my experience, I could lose the guts of a day installing SQL Server if I didn’t have a slipstreamed package, while the VM deployment itself took very little time.

“Why, in a cloud, shouldn’t the user install SQL Server?”

LMAO!  Clouds are like hosting, and I left the hosting business because 80% of the customers made me want to scream at them.  They were clueless: e.g. the guy who opened a helpdesk call to get a DR replication application written for his new SaaS business (selling DR).

Not that all of them were like that.  I learned from a few and some were doing very interesting and innovative things.

When it comes to things like SQL Server, the infrastructure people (or system) must do the installation.  But we want to minimize that time.  SQL Server 2012 SP1 CU2 has expanded support for Sysprep.  This means that you can optimise the deployment of virtual machines with SQL Server (including service pack and related cumulative update).  For more information you can see:

SQL Server 2012 RTM

I read yesterday that SQL Server 2012 had RTMd.  It’s not on MSDN yet.  The online launch event is later today at 16:00 GMT.  There’s lots more information about this new release on TechNet.  There’s a lot of new features, way too many for me to cover here, but the best one might be AlwaysOn.  That’s a new database (or group of databases) availability feature, similar to DAG in Exchange. 

Please take note that SQL 2012 licensing is very different from what you are used to and there is a migration path for those with Software Assurance/upgrade rights.

Before you go upgrading your SQL, make sure that your products support SQL Server 2012.  Don’t just go assuming that they will, e.g. System Center.

EDIT1:

SQL 2012 general availability will be April 1st.  Please, no jokes Smile

Technorati Tags:

SQL 2012 Editions & Licensing Announced … What Are They Smoking?

Every year they promise us simplification.  Let’s see how they’ve score this time around …

The major versions are:

  • Enterprise: moves up to replace the now gone Datacenter, and is only licensed on a per-core basis.  Yup, not server + CAL.
  • Business Intelligence (BI): slots in the middle and is only available under server + CAL (just to confuse).
  • Standard: Available under server + CAL, as well as per-core.

By the way, there is a lovely contradiction about Enterprise being available and limited on server + CAL basis.  But everywhere else, it says per Core only for this edition.  There’s a reason (see later).

image

We are told that:

“SQL Server 2012 will continue to be available in Developer, Express and Compact editions. Web Edition will be offered in a Services Provider License Agreement (SPLA – hosting licensing) model only. Datacenter Edition is being retired with all capabilities now available in Enterprise. Workgroup and Small business Editions are also being retired”.

If you are licensing per core then you buy the licenses in 2-core packs, with a minimum of 4 cores per physical processor.

image

If you are licensing on a per-VM basis then you have two options:

image

Note how they are counting virtual cores?  It used to be that we had a formula to count physical CPUs being used by the VM and licensed that.  Maybe the price works out similarly – I’ll have to check that out later.

More on virtualised SQL 2012:

  • To license a VM with core-based licenses, simply pay for the virtual cores allocated within the virtual machine (minimum of 4 core licenses per VM).
  • To license a VM under the Server + CAL model (for the Business Intelligence and Standard Editions of SQL Server 2012), you can buy the server license and buy associated SQL Server CALs for each user.
  • Each licensed VM that is covered with Software Assurance can be moved frequently within your server farm or to a third party hoster or cloud services provider.
  • The Enterprise Edition with Software Assurance allows you to deploy an unlimited number of database VMs on the server (or server farm) in a heavily consolidated virtualized deployment to achieve further savings.

They note that:

  • Further savings can be achieved by operating a database server utility or SQL private cloud. This is a great option for customers who want to take advantage of the full computing power of their physical servers and have very dynamic provisioning and de-provisioning of virtual resources.
  • Customers will be able to deploy an unlimited number of virtual machines on the server and utilize the full capacity of the licensed hardware.
  • They can do so by fully licensing the server (or server farm) with Enterprise Edition core licenses and Software Assurance based on the total number of physical cores on the servers.  This allows customers the ability to have unlimited virtual machines to handle their dynamic workloads and fully utilize the hardware’s computing power.

In other words, if you will have lots of SQL VMs then you should have a dedicated virtualisation (any platform) cluster for your SQL VMs, and license it using Enterprise per-core licenses with SA.  That’s what we currently advise to save on licensing – you have to do the maths on additional Windows Server + hardware + power + management time/licenses VS SQL license cost reduction.

If you want to license Enterprise SQL via server + CAL then you better move quick:

“New Server licenses for EE will only be available for purchase through 6/30/2011. Additional EE licenses in the Server and CAL license model will not be sold thereafter.

Both newly purchased Server licenses for SQL Server EE 2012 or EE licenses with SA upgraded to SQL Server EE 2012 will be limited to server deployments with 20 cores or less. If you purchased SQL Server 2008 R2 Enterprise Edition in the Server + CAL model with Software Assurance and at the launch of SQL Server 2012 are running on a server with > 20 physical cores, contact your Microsoft representative for help transitioning to the new licensing model”.

The SA upgrade story looks confusing.  I’m not going to try interpret it.  I’ll leave it with this thought …. WTF are they thinking and who OKd this!?!?!  I’ve said it before and I’ll say it in public now: this stuff makes an EU treaty look easy to comprehend.  My advice to MSFT is to burn the licensing rules, and start over.

BTW, I am one to say I told you so:

“Microsoft licensing never stays still for very long. Microsoft licensing is a maze of complexity that even the experts argue over. Microsoft will lose revenue as host/CPU capacities continue to grow unless they make a change. And Microsoft is not in the business of losing money”.

Technorati Tags: ,,

Licensing A VM for SQL Server Per Proc in a Virtual Machine

If your virtual machine has 4 vCPUs and it’s running on a multiple CPU host, how many SQL Per Proc licenses do you need to buy (if you’re not doing Server/CAL)?  Well this question just came up at work and we wanted to get it right for the customer.

There are two sources of information.  This blog post distils it down and this whitepaper explains it on page 5.

Right now, the answer is usually 1 per Proc license per virtual OSE (VOSE or virtual operating system environment – aka a guest OS in a VM) in the Hyper-V world.   And here’s why.

Take a 4 vCPU VM running on a host with 2 * quad core CPUs.  4 vCPUs = 4 logical processors.  With hyperthreading disabled (or enabled in this case) this VM never runs on more than 1 physical CPU.  We can license SQL Server by pCPU.  So if it never runs on 1 pCPU then we can buy just 1 copy of SQL Server per proc. 

What if this VM runs on a Hyper-V cluster?  Do we need to buy 1 per Proc license per host?  Nope.  We buy the licensing for the VOSE (VM OS).

Let’s change it up.  What if the host has 2 dual core CPUs with no hyperthreading?  Now we need to use a formula:

VOSE SQL Server Per Proc Licenses = A / B where

  • A = number of VPUs in the VM
  • B = Cores/CPU

In this case the number of SQL Server per proc licenses = 4/2 = 2.  And that makes sense; the 4 vCPUs in the VM run on 4 logical processors, and the 4 logical processors are made up by 2 dual core CPUs.

Things are kind of easy right now with Windows Server 2008 R2 Hyper-V (maximum of 4 vCPUs per VM).  But what about Windows Server 8 or vSphere 5.0 where it increases to 32 vCPUs/VM?  Let’s have a 32 vCPU VM running on 4 * 10 core Intel CPUs with hyperthreading enabled.  Ouch, my head hurts already.

  • A = 32
  • B = 20 (10 cores by 2 threads)

The formula gives us 32/20 = 1.6 pCPUs.  The VM can’t run on 1.6 pCPUs; it will span 2 pCPUs (we always round up).  That means the 32 vCPU VM can be licensed with just 2 SQL Server Per Proc licenses on this host.

Who wants to do division, fractions, and roundups?  This might sound like hassle but it’s good because it saves you money and keeps you legal.  In our most basic example above, the customer pays for 1 per proc license instead of 4.  In the most complex one, they pay for 2 per proc licenses instead of 32.

And that’s how to license a single VM.  Things get a whole lot more complex when licensing many SQL VMs and then you start looking at buying SQL Enterprise/Datacenter licensing at the host level, and then throw in virtualisation clustering where your SQL licensing impacts on your virtualisation design so you can save large amounts of money.  I covered that one about a year ago and am happy to leave it there for the moment Smile

Technorati Tags: ,,

SQL Server 2008 R2 Service Pack 1

I hate SQL Service Packs.  Yeah, you heard me!  They just add so much more time to the installation time.  Yeah, you can “slipstream” them, but only a few people ever do it.

Good news everybody!  SQL Server 2008 R2 SP1 is launched.  Some new features are listed on that page but it’s all beyond an accidental DBA like me so I won’t copy/paste and present to understand it all.

Don’t just lash this SP out and hope for the best.  Check your application compatibility.  That applies to your System Center admins too!  There are support lists and you shouldn’t go upgrading without checking for support first.  Assuming there is support is your problem, not Microsoft’s.  You break it – you fix it Smile

Technorati Tags: ,

SQL Server 2008 R2 RTM and SQL 2008 R2 Express Downloads

SQL Server 2008 R2 was released to manufacturing.  As usual, a free (and limited scale/functionality) Express edition was also released.  There are three packages, from the version just with the core components, the version with management functionality, and the version that has management and more advanced features:

  • SQL Server 2008 R2 Express: The Microsoft® SQL Server® 2008 R2 Express RTM is a powerful and reliable data management system that delivers a rich set of features, data protection, and performance for embedded applications, lightweight Web Sites and applications, and local data stores. Designed for easy deployment and rapid prototyping, this download includes support for Sysprep, Microsoft’s System Preparation Utility for Microsoft Windows operating system deployment.
  • SQL 2008 R2 Express with Management Tools: an easy-to-use version of the SQL Server Express data platform that includes the graphical management tool SQL Server Management Studio (SMSS) Express
  • SQL 2008 R2 Express with Advanced Services: an easy-to-use version of the SQL Server Express data platform that includes the graphical management tool SQL Server Management Studio (SMSS) Express, powerful features for reporting, and advanced text-based search capabilities

The requirements for the Express edition are:

  • Windows 7; Windows Server 2003; Windows Server 2008; Windows Server 2008 R2; Windows Vista; Windows XP
  • 32-bit systems: Computer with Intel or compatible 1GHz or faster processor (2 GHz or faster is recommended.)
  • 64-bit systems: 1.4 GHz or faster processor
  • Minimum of 512 MB of RAM (2 GB or more is recommended.)
  • 2.2 GB of available hard disk space
Technorati Tags:

SQL BPA Command Line Has Encountered A Problem And Needs To Close

I was upgrading an application this morning.  Part of the process was to upgrade SQL 2000 to SQL 2005 (the application is developed by a company that tends to not be adventurous about version platform support).  After I’d gone through the setup wizard, it went to do a last check and came up with this error:

image

When you’re dealing with something like a SQL upgrade and see something like this … well … you start looking for the phone and dialling 999 (911 for those of you across the pond). 

A very quick search later and I had the solution.  A simple folder creation and a file copy sorts things out.

Technorati Tags: ,

SQL 2008 R2 Licensing

Emma Healey (MS Licensing person capable of speaking both English and Microsoft Licensing) has just posted about some changes coming with SQL 2008 R2.  The edition comparisons (available now) are:

clip_image002

SQL Datacenter edition will continue to allow unlimited virtual machines to run SQL on a host.  Enterprise edition changes to now allow up to 4 SQL instances to run on a host.

Technorati Tags: