Drupal 5.7 with IIS & SQL Server

Hi, I am running Windows 2k3 server, 3gb ram, 2.66ghz Xeon processor, eAcellerator, ISAPI Rewrite 3.x, and Drupal 5.7. I was having issues with CPU and php-cgi.exe process usage where people would visit the site and it would take long periods of time (10 seconds and more) to load. CPU usage would peak and stay around 80 percent.

I then turn on Drupal "normal" caching, which dropped everything down to below 10% usage, however, for people who log into the site, the pages load slowly again and CPU usage goes up.

I'm wondering if anyone has suggestions... there clearly seems to be an issue with requests and using up too much memory and CPU.

Any help would be much appreciated!

Average rating
(0 votes)
Brashquido's picture

Location: Melbourne, Australia

Joined: Sep 2003

Send PM

Brashquido said:

I suggest installing the Devel module as a first step. Using it you'll be able to identify if the bottleneck is MySQL, PHP, or both.
----------------
Dominic Ryan
4 x Microsoft IIS MVP, MCSE, MCSA
IIS Aid owner/webmaster

sj20's picture

Joined: Jul 2008

Send PM

sj20 said:

I ran devel and it looks like the biggest time consumer is updating the views_cache table (440ms out of a total 1110ms query run). It says 1110ms total, but the page takes about 5 or 7 seconds to actually load. I still don't understand why hits to the DB would cause IIS CPU time to increase, however... I have i18n installed, with several url_aliases, which is a bulk of the queries run on each page load when logged in or not.... .85ms each. Any other suggestions? I really appreciate your help!

Brashquido's picture

Location: Melbourne, Australia

Joined: Sep 2003

Send PM

Brashquido said:

First step by the sounds is a bit of MySQL tuning. You have 3GB of RAM, what DB tuning steps have you taken so far?
----------------
Dominic Ryan
4 x Microsoft IIS MVP, MCSE, MCSA
IIS Aid owner/webmaster

sj20's picture

Joined: Jul 2008

Send PM

sj20 said:

Yeah, I'm using SQL Server, so there's the first issue (see the title of my first post). So, it could be that... I checked to see that columns were being indexed, etc. Again, that views_cache UPDATE query takes about 400ms, which probably equates to more like 1 second or so...

Brashquido's picture

Location: Melbourne, Australia

Joined: Sep 2003

Send PM

Brashquido said:

Aha, there you go. SQL is the language, not the proprietor. So when you say that you use SQL with a PHP app most people in the PHP world will assume MySQL or PostgreSQL. Very few open source PHP apps actually have direct support for MSSQL. Regardless, I'm not going to be much use to you for MSSQL performance tuning as I've not used it to any great depth for several years. With those query times though it definitely sounds like you could find some better performance there using your hardware.
----------------
Dominic Ryan
4 x Microsoft IIS MVP, MCSE, MCSA
IIS Aid owner/webmaster