SharePoint - High CPU utilization-w3wp.exe - Asked By IFI IFI on 05-Oct-11 05:39 PM

Hi All,

How can the high cpu utilization due to w3wp.exe in sharepoint 2010 servers can be resolved?

Please help me on this to overcome the issue.


Riley K replied to IFI IFI on 05-Oct-11 09:47 PM



The reason for High CPU Utilization could be because of some errors while retreiving data from SQL Server,

I recommend you to check event log for error messages

please check event log for W3C application pools recycle message.

 If there are plenty off messages that AppPool reaches his limit and is recycled you
can increase this limit. As far as I got feeling your RAM is not heavily
used.

Every W3W is running under Application Pool which you can configure in IIS
manager - there is section where you can limit RAM - so check that.

You can check this link regarding your issue



Regards
Sakshi a replied to IFI IFI on 05-Oct-11 10:05 PM

A simillar situation was met and the solution in that case was to uninstall some feature using stsadm and restart of iis.

Other options which will help you arrive at solving the problem are:

1. Perform Load testing, using tools such as Visual Studio Team Test or WCAT
2. If you are using IIS7 configure Failed Request Tracing to generate a trace if requests take more a certain amount of time
3. Use logparser to see which requests arrived at the time of the CPU spike
the following command will analyze logfile and find witch page have long time execution

c:\> logparser "select top 10 cs-uri-stem, time-taken from ex071105.log group by cs-uri-stem order by time-taken desc" -q:on

4. Use  the following :
   a. Process Explorer
   b. Windows Resource Monitor
   c. Detailed error logging
   d. use custom trace logging.
5. Check whether it happens on AppPool recycles.
6. Changing Session state from Inproc to State server or sql server is one option
7. IISPeek will also help.
8. Check what appliaction pool the w3wp.exe is attached to.
in task manager show the processID of the task
and run the IIS script iisapp.vbs to show what application pool is attached to what teh offending w3wp.
IF there are multiple applications in that pool seperate them off futher to narrow down the search if possible.
9. Moreover you can follow , iis app pool settings,
   http://blogs.msdn.com/b/joelo/archive/2007/10/29/sharepoint-app-pool-settings.aspx



Suchit shah replied to IFI IFI on 05-Oct-11 11:49 PM
Download and install all the Windows Updates. Also install all the latest patches on WSUS server. It will be fixed.

you can use Logparser to analyze logfile and find witch page have long time execution

Use the following code 

c:\> logparser "select top 10 cs-uri-stem, time-taken from ex071105.log group by cs-uri-stem order by time-taken desc" -q:on

 

Suchit shah replied to IFI IFI on 06-Oct-11 12:03 AM
The w3wp worker process is generate per application pool. I would first check to make sure each of your Sharepoint web applications is on its own application pool and check to ensure each service application has its own application pool. In addition you can look in IIS to see what is running on that particular worker process to get an idea of what applications are causing the high CPU utilization.