The following is Scenario 2: Environment: Win2003server+iis+asp+mssql Phenomenon: Every once in a while (indefinite, sometimes a few minutes, sometimes half an hour) a Web site opened very slowly, and sometimes even timeout to open the site, at this point to view the server-side process, the CPU occupancy rate reached 100%, of which w3wp occupy 70~80%,sql occupied 20~30%. All server-side operations have also become slow Initial solution: Each phenomenon occurs, immediately log on to the server directly to end the W3WP process or restart the IIS service, an average of about 10 operations per day, because the server is stored in the remote computer room, all operations are remote control, and sometimes there will be remote unable to connect to the situation, can only notify the computer room manager to restart the server solution, this process caused users to complain constantly Through online access to data, found that most of these phenomena due to the unreasonable Web page code, the following circumstances can lead to such a phenomenon: 1, the code in many places using application, seesion, such as server caching, resulting in excessive server data consumption; 2, the code has unreasonable syntax, such as dead circulation; 3, database corruption, especially Access database; 4, install too many third-party software or Plug-ins, and IIS or Web page feature code conflict. First-stage troubleshooting: Analysis by reference to the referenced resources 1, all site code on the server for the company's designers to write their own, can prove that there is no excessive call server caching syntax (exclusion) 2, the code whether there is unreasonable syntax (not sure) 3, according to the situation, the increase in the IIS process occupancy rate, the SQL occupancy rate increased at the same time, should be the site of the SQL database, according to the phenomenon of judgment, the library or table should be normal, estimated data may be wrong; 4, the server side in addition to the basic system services, anti-virus and web site operation of essential services, and no redundant third-party software, the probability is not (excluded).
Through the above analysis, the uncertainty is linked to the conclusion that a Web page code with SQL database has unreasonable syntax, resulting in high CPU usage of IIS and SQL processes.
The second phase of the investigation: Determine the scope, and then continue to narrow the scope. Since there are not many sites using SQL databases on the server, it is easy to establish a separate process ID to observe, all the sites using the SQL database in IIS Manager to establish separate application pool, and then through the CMD interface input: Iisapp-a to view and record the process ID number of each IIS pool, An IIS process ID is the culprit for this problem, as observed over multiple occurrences. |