VMware Cloud Community
TomR_CAW
Contributor
Contributor

SQL Server Performance issues as a VM

Since converting an MSSQL server to a virtual machine we have seen severe performance drops and an array of unusual errors. Here's the scenario:

3 Dell PowerEdge 2950 servers each configured as follows:

2 PROC, Quad core Intel E5430 2.66Ghz

8GB RAM

2 onboard Broadcom GB NICs (used for service console and admin network only)

1 Intel GB 4 port NIC (2 for VMotion, 2 for Production VMs)

2 QLogic QLA2432 4GB HBAs

EMC CX300 SAN

Admin, VMotion and Production networks are physically separate, each with it's own GB switch.

We are running ESX 3.5 on all hosts with VC 2.5 setup as a VM. HA, DRS, VMotion all enabled. There are six VMs running currently arranged like so:

Host1

WebServer VM (4 vCPU, 3GB RAM, Win2K)

Host2

WebServer2 VM (1 vCPU, 1GB RAM, Win2K3), secondary sites, minimal traffic

WebServer3 VM (1 vCPU, 1GB RAM, Win2K3), not in production yet, no traffic

VirtualCenter VM (1 vCPU, 2GB RAM, Win2K3)

DataImport VM (1 vCPU, 1GB RAM, Win2K), processes data files to load into SQLServer

Host3

SQLServer VM (4 VCPU, 3GB RAM, Win2K, MSSQL2000 sp4) primary backend database

The WebServer, DataImport and SQLServer VMs were all converted using Converter Enterprise.

All VMs are stored on the SAN in LUN A, except SQLServer in LUN B.

All SQLServer databases (.mdf files) are in two RDMs to LUNs C & D.

All SQLServer log files are in the VM.

We operate approximately 200 SQL databases ranging in size from 20MB to 20GB. Most are around 750MB. There is a lot of SQL activity. We receive daily update files from clients to load into their databases. These files are stored in a separate physical server and processed by the DataImport VM which does most of the insert/update/delete functions. The web portals themselves are mostly just queries. Very few inserts or updates. The past couple weeks since converting everything to VMware we have seen a lot of performance issues. Web Portal requests routinely return ASP timeouts while waiting for responses from SQL. We have also seen a lot of other intermittent errors since the conversion like these:

"The RPC Server is unavailable" when accessing some pages.

and

"Microsoft OLE DB Provider for SQL Server error '80004005'

DBNETLIB ConnectionOpen (PreLoginHandshake()). General network error. Check your network documentation."

Both of these are intermittent and will often go away after refreshing a page. We've also seen these creep up on our web server: "Out of process application '/LM/W3SVC/1/ROOT/xxxxx' terminated unexpectedly."

After some monitoring with esxtop, VI client Performance, perfmon, and our switches the network, SAN fabric and memory do not appear to be dragging. The only thing that is jumping out at me is the SQLServer CPU usage. Since converting the VI client performance tab and esxtop is showing consistently above 90% CPU usage when our DataImport programs are running. If I shut them down the importers, usage drops to 30% or below. Also perfmon and taskman in the guest are showing barely 25% usage at the same time esxtop shows 100%.

I'm at a loss of where to look next. SQL Server was able to handle all site and importer requests perfectly prior to the conversion and that was with lesser hardware. Any help would be greatly appreciated.

Thanks.

Tom

Tags (1)
0 Kudos
48 Replies
TomR_CAW
Contributor
Contributor

I have a clean VM setup with SQL installed. I'm starting the process of moving the databases to the new VM. Only about a dozen will be moved initially to make sure there are no other side effects I'm not anticipating.

0 Kudos
Ken_Cline
Champion
Champion

I have a clean VM setup with SQL installed. I'm starting the process of moving the databases to the new VM. Only about a dozen will be moved initially to make sure there are no other side effects I'm not anticipating.

I hope this fixes it for you! You've certainly been persistent, and I commend you for your efforts. Please do keep us informed about how things go with the new VM.

Thanks!

Ken Cline

Technical Director, Virtualization

Wells Landers[/url]

VMware Communities User Moderator

Ken Cline VMware vExpert 2009 VMware Communities User Moderator Blogging at: http://KensVirtualReality.wordpress.com/
0 Kudos
TomR_CAW
Contributor
Contributor

So far so good, but only 7 databases have been moved and three of those are rarely used. I will be moving another 50 later today hopefully.

0 Kudos
TomR_CAW
Contributor
Contributor

90+ databases have been moved. It's off hours, but even with the data processors running, things are looking good. We'll find out tomorrow morning if things are stable enough for me to push the rest of the databases over. I've noticed that the gap between VI Client performance and Windows perfmon has closed significantly. Before it was 100% VI, 25% guest. Now it is 40% VI and 45% guest.

0 Kudos
TomR_CAW
Contributor
Contributor

All 200 databases were moved last Wednesday. Thursday and Friday ran good, but we won't know how things are really operating until the end of the day today or tomorrow morning. So far today things are running smoothly. fingers crossed

0 Kudos
Ken_Cline
Champion
Champion

Thanks for the update, Tom. Glad to hear things are better. I wish I knew what it was about the P2V process that sometimes causes these problems...

Ken Cline

Technical Director, Virtualization

Wells Landers

VMware Communities User Moderator

Ken Cline VMware vExpert 2009 VMware Communities User Moderator Blogging at: http://KensVirtualReality.wordpress.com/
0 Kudos
TomR_CAW
Contributor
Contributor

Well we have been running over a week with zero problems. I'm going to consider this one resolved. I guess it was just a bad conversion. Thanks everyone for your help with this.

0 Kudos
Ken_Cline
Champion
Champion

Well we have been running over a week with zero problems. I'm going to consider this one resolved. I guess it was just a bad conversion. Thanks everyone for your help with this.

Thank you for your efforts - and for sticking with it. Many folks would have given up and simply said "it's a bad idea to virtualize SQL Server". I wish VMware would be able to figure out what is happening in the conversion process and fix it...maybe one day Smiley Wink

Ken Cline

Technical Director, Virtualization

Wells Landers[/url]

VMware Communities User Moderator

Ken Cline VMware vExpert 2009 VMware Communities User Moderator Blogging at: http://KensVirtualReality.wordpress.com/
0 Kudos
Anders_Gregerse
Hot Shot
Hot Shot

That it great news for you and other vmware & sql users.

Perhaps it would be a good idea for vmware and other virtualization vendors to start investigating what goes wrong in some conversion projects. With enough bad performing systems it should be possible to find the cultprits.

0 Kudos