Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We have a MySQL server that supports several internal business systems. Our infrastructure team is having a spirited debate as to whether or not we can switch this database server to a VM. The argument is higher availability from the VM side versus performance from the physical hardware side. Most of the information we have been able to find is rather dated (2009 or earlier).

Does anyone have any experience with virtualizing a production MySQL server and its affect on availability and performance?

Some additional information, DB size is about 100GB, load is not that heavy, but there are a lot of writes.

EDIT: I should also note that the datadir is using a SAN volume

share|improve this question
How many disks back your SAN volume and in which RAID level? – pfo Oct 25 '12 at 13:41
up vote 2 down vote accepted

What are your current IOPS(95% percentile @ < 20ms latency) that the MySQL does? If below 100 000/s you can go virtual quite easy and use the same storage device that you used to have before.

MySQL isn't even very effective with multiple cores so assigning more than 4-6 vCPUs isn't going to help due to contention within InnoDB (I assume you run InnoDB).

share|improve this answer
Yes we are running InnoDB – Peer Allan Oct 25 '12 at 12:34

We virtualized a lot of MSSQL and Oracle Databases on HyperV and XEN including some big sharepoint Databases and we don't see any performanc issues. Our whole IT project bussines works on the sharepoint with about 100 concurrent users and a little bigger database than yours and some very big SAP Databases with Oracle under XEN. For the bigger Databases we created pass through disks so that only one layer needs to write. But I think your environment with this small database will work just fine even with virtual disks.

share|improve this answer
And for even bigger: Hyper-V now supports 32 virtual CPU's and the whoe disc can go on a SAN and be either ISCSI or FC passthrough - that is QUITE large. – TomTom Oct 25 '12 at 18:44

If possible, just give it a try? Take a dump of the Database, put it on a VM, and run some benchmarks against it?

With the dump in hand, you can even try more HA ideas like multi-master replication with tools like Galera or other.

share|improve this answer

This used to be an issue (i.e. hypervisor reporting completed disk writes when the I/O subsystem hadn't actually seen the bits yet) but has been common practice for a couple of years now.

Using a recent version of Xen/VSphere there should be no reason not to virtualise a production MySQL server - benchmark predicted workloads against a bare metal equivalent to see how much overhead the hypervisor adds.

If you have many write, SSDs could be recommended.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.