Optimizing Performance on Hyper-V for SharePoint

Optimizing Performance on Hyper-V for SharePoint

I do a lot of presentations and demos of SharePoint 2007 and SharePoint 2010 on my laptop.  It is a quad-core with 10 GB ram and my SharePoint environments are a full complete installation, self-enclosed SharePoint farm with SQL Server 2008 R2 and AD Installed on it.

I’m in the process of transitioning from VMWare to HyperV on this new laptop.  Really, I’m trying to give HyperV on Windows R2 a chance after not being to impressed with its performance over the last few years.  I’ve always had success with performance using VMWare on my laptop so I have put together this combined list of resources and tips across the web that I have found that should theoretically help with performance on HyperV along with my own suggestions.  I am testing it as we speak.  Please help by making your own suggestions and/or corrections to my list.

  1. Configure the correct amount of memory for Hyper-V guests [1].  – Apparently Hyper-V images only need about 70% the ram that the machine would need if it was a physical machine but I would say at least 3 to 4 GB RAM.
  2. Use a fixed disk rather than a dynamic one, especially for environments which rely on SharePoint indexing [2]. 
  3. Get a Solid State Hard Drive!!! – probably the most important factor, I will definitely be getting one soon
  4. Make sure you put your hard drive on your fastest hard drive (at the minimum 7200 RPM). 
  5. If you are using external hard drives, stick to e-Sata instead of USB or FireWire.
  6. Optimize host CPU use – No recommendations here, it all depends on your environment, you need to test the various settings.  For me, I allocated 3 of my 4 processors to be used by the VM.  Some people say to use all processors.
  7. Use IPv4 as the network protocol for Hyper-V guests – Disable IPv6 on both host and guest, supposed to increase performance
  8. Advanced: Try optimizing your NUMA (Non Uniform Access Node) [3] – Haven’t tried this for my image yet, someone let me know if this makes a big difference for SharePoint or not
  9. Turn off unneeded hardware such as CD and Floppy
  10. Turn off unneeded Windows Services on your VM Guest OS (i.e. Print Spooler, Windows Firewall, Windows Error Reporting,  Windows Update, Windows Audio Service, etc…)
  11. Under Control Panel –> System and Security –> performance: Adjust for best performance and background services
  12. Under Control Panel –> System and Security –> performance: Optimize for background services
  13. Under Control Panel –> System and Security –> performance: Increase the size of the page files and put them on separate disks if possible
  14. Under Control Panel –> System and Security –> performance: Turn on DEP for essential Windows Programs only
  15. SQL Server: Give a max memory allocation for SQL Server under SQL Server properties in management studio so that SQL Server leaves some memory for SharePoint to do its stuff (i.e. leave 1 GB for SharePoint)
  16. SQL Server:Allocate 500MB for temp db starting size and grow by 256 MB and put on separate disk if possible
  17. In SharePoint: Turn off all unused features
  18. Remember to defrag your host and guest disk drives every little while!

Also, refer to my previous blog entitled Performance Optimization and Scaling Best Practices – Cheat Sheet for SharePoint.

More details and other great resources for performance optimization of virtualized environments can be found here and here.

1.

http://technet.microsoft.com/en-us/library/dd277865(office.12).aspx

2.

http://blogs.technet.com/b/winserverperformance/archive/2008/09/19/hyper-v-and-vhd-performance-dynamic-vs-fixed.aspx

3.

http://blogs.msdn.com/b/tvoellm/archive/2008/09/28/looking-for-that-last-once-of-performance_3f00_-then-try-affinitizing-your-vm-to-a-numa-node-.aspx

 

Leave a Reply

Your email address will not be published. Required fields are marked *