I originally posted this on StackOverflow but I feel as though the problem lies with the hardware / OS configuration. I'm hoping that someone here has had a similar experience and can offer some advice.
I have deployed a MVC2 application to IIS7.5 running on Windows Server 2008 R2 Standard server (physical machine; Dell R710 w/ plenty of memory). It's connecting to a SQL Server 2008 database (also physical machine; Windows Server 2008 R2 Standard; Dell R710 w/ plenty of memory) and the applications performance is abysmal. It's fairly simple and it's only making a few calls to stored-procedures.
The developer has tested the application running in the debugger on his own workstation (Windows 7, 64-bit; IIS7.5) connecting to the same database back-end. It screams. Loads in the blink of an eye. Running under Server 2008 R2 it takes about 10-15 seconds and it pauses between each call to the DB. I'm run tests in the SQL Server Profiler and the SP's run fast. The performance problem manifests itself when migrated to Server 2008 R2.
What I've tried thus far:
- disabled firewall
- rebuilt the application for compatibility mode (either 32 or 64 bit)
- rebuilt the application specifically for 64-bit
- configured the server for 32-bit mode worker process
- disabled tcp-chimney offloading
- rebuilt the server in desperation
Each of those had no discernible effect on performance.
Any help with diagnosing this performance issue would be appreciated, thank you.
It appears that opening the connection to the database is part of the bottleneck with the subsequent firing of stored procedures also taking a considerable amount of time:
-Open db connection: 5 sec (subsequent connections are cached so they don’t require 5 seconds)
-First sproc : < 1 sec
-Second sproc: 5 sec
-Third sproc: < 1 sec
-Fourth sproc: < 1 sec
-Fifth sproc: 6 sec