系统升级后,虚拟机的SQL服务器性能差。

时间:2022-09-17 21:38:24

I'm managing middle sized company database. Recently we have massive system upgrade and switched to virtual machine environment. After deployment, we are having performance issues, Apparently SQL Server on the upgraded system works slower than the old configuration.

我在管理中型公司的数据库。最近我们进行了大规模的系统升级,并切换到虚拟机环境。部署之后,我们遇到了性能问题,显然升级系统上的SQL Server的工作速度要比旧配置慢。

Here are the configurations:

配置如下:

  • Old Server: SQL Server 2008, 10gb Ram, Intel Xeon E5420 x2 (Physical Machine) runs on Windows Server 2008

    老服务器:SQL Server 2008, 10gb内存,Intel Xeon E5420 x2(物理机)运行于Windows Server 2008。

  • New Server: SQL Server 2014, 64gb Ram, Intel E5 2660 x4 (virtual machine) runs on Windows Server 2012

    新服务器:SQL Server 2014, 64gb Ram, Intel E5 2660 x4(虚拟机)运行在Windows Server 2012上

Very basic IO performance comparison follows as:

非常基本的IO性能比较如下:

new server:

新服务器:

系统升级后,虚拟机的SQL服务器性能差。

old server:

旧的服务器:

系统升级后,虚拟机的SQL服务器性能差。

Even with the most basic operation:

即使是最基本的操作:

select * from table

from most used tables runs more amount of time to retrieve result. Also stored procedures run slower.

从大多数使用的表运行更多的时间来检索结果。此外,存储过程运行速度也较慢。

Example:

例子:

  • new server: 01:39 minute, 3285365 rows
  • 新服务器:01:39分钟,3285365行
  • old server: 01:00 minute, 3339738 rows
  • 老服务器:01:00分,3339738行

I have no idea what could cause this problem. Any help will be appreciated.

我不知道是什么原因引起这个问题。如有任何帮助,我们将不胜感激。

Edit: Both servers has same sql configuration tempdb and datadb is seperated

编辑:两个服务器都具有相同的sql配置tempdb,并将datadb分隔

1 个解决方案

#1


2  

This probably isn't what you want to hear, but VMs are always slower than physical servers, because of the overhead of implementing the VM. Also the 2660 has MUCH less L2 cache than the old processor.

这可能不是您希望听到的,但是VM总是比物理服务器慢,因为实现VM的开销很大。此外,与旧处理器相比,2660具有更少的L2缓存。

I'm not sure what to tell you except to make sure that the VM for the SQL Server, has as much RAM and cores allocated to it as you can spare, and that SQL Server is configured to actually use them.

我不知道该告诉您什么,除非确保SQL服务器的VM有尽可能多的内存和内核分配给它,并且SQL服务器被配置为实际使用它们。

Also, disk I/O is a big deal. Are the drives and controllers for both systems similar?

此外,磁盘I/O也很重要。这两个系统的驱动器和控制器相似吗?

VMWare has a whitepaper on the subject, so at least you're not alone. 8-)

VMWare有一个关于这个主题的白皮书,所以至少你不是一个人。8 -)

http://www.vmware.com/files/pdf/solutions/SQL_Server_on_VMware-Best_Practices_Guide.pdf

http://www.vmware.com/files/pdf/solutions/SQL_Server_on_VMware-Best_Practices_Guide.pdf

#1


2  

This probably isn't what you want to hear, but VMs are always slower than physical servers, because of the overhead of implementing the VM. Also the 2660 has MUCH less L2 cache than the old processor.

这可能不是您希望听到的,但是VM总是比物理服务器慢,因为实现VM的开销很大。此外,与旧处理器相比,2660具有更少的L2缓存。

I'm not sure what to tell you except to make sure that the VM for the SQL Server, has as much RAM and cores allocated to it as you can spare, and that SQL Server is configured to actually use them.

我不知道该告诉您什么,除非确保SQL服务器的VM有尽可能多的内存和内核分配给它,并且SQL服务器被配置为实际使用它们。

Also, disk I/O is a big deal. Are the drives and controllers for both systems similar?

此外,磁盘I/O也很重要。这两个系统的驱动器和控制器相似吗?

VMWare has a whitepaper on the subject, so at least you're not alone. 8-)

VMWare有一个关于这个主题的白皮书,所以至少你不是一个人。8 -)

http://www.vmware.com/files/pdf/solutions/SQL_Server_on_VMware-Best_Practices_Guide.pdf

http://www.vmware.com/files/pdf/solutions/SQL_Server_on_VMware-Best_Practices_Guide.pdf