locked
Slow performance of web pages with Windows 2016 IIS10 RRS feed

  • Question

  • User-654958644 posted

    We are having one ASP.Net Web Forms Website previously hosted on Windows 2008 Server with IIS 7.0. A few days back we have decommissioned that server and hosted the application in Windows 2016 Server with IIS 10.0. After that, we are facing severe performance issue for that Website. I have tried to dig little bit to understand the problem. First of I notice problem with High TTFB while requesting the page -

    HIgh TTFB

    I have also configured Failed Request trace and found ASPNetPageRenderLeave is having high value -

    ASPNetPageRenderLeave

    We are connecting Oracle database from the code with MSDORA (ADODB) Connection Provider. For testing I have created two pages, one connecting Oracle DB and populating 4 Dropdownlists and another having hardcoded dropdownlist values without DB connection. For 1st case, Waiting time is around 332S and without DB its 30S (although 10 times lower, but still very high waiting time).

    After reading lot of forums I have changed below settings in Server side -

    1. Installed ASP, Application Initialization on IIS
    2. Changed App Pool Start Mode to AlwaysRunning
    3. Increased Maximum Worker Process from 0 to 4
    4. On Website PreloadEnabled set as True
    5. Enabled Static & Dynamic Content Compression.
    6. Enabled Output Caching for aspx files (both User-Mode & Kernel Mode)

    I have also check hardware resource utilisation of the server and found -

    1. CPU / Utilization 2*2.8 / 1 %
    2. RAM 8 GB / 25 %

    None of the above changes fixed the issue. Sample code without DB Connection (Its also taking 30-45secs to load) -

    <%@ Page Language="VB" CodeFile="~/Common/common.aspx.vb" Inherits="ManualInputBI_Include_Common" %>
    <%@ Import Namespace="System.Data" %>
    <%@ Import Namespace="System.Data.OleDb" %>
    <%@ Import Namespace="System.Data.Odbc" %>
    <%@ Import Namespace="System.ComponentModel" %>
    <%@ Import Namespace="System.Configuration" %>
    <%@ Import Namespace="System" %>
    <%@ Import Namespace="System.Net" %>
    <%@ Import Namespace="System.Globalization" %>
    <%@ Import Namespace="System.Web.UI" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <%    
      labelDEVStatusInfo.Text = HttpContext.Current.Request.AppRelativeCurrentExecutionFilePath.ToString() & " - implementation in progress. "
      labelDEVStatusInfo.Visible = False
      %>
    <!--#include file="~/Include/UserInfo.aspx"-->
    <!--#include file="~/Include/X_Screens_menu.aspx"-->
    <%
      rootWebConfig_CDS = System.Web.Configuration.WebConfigurationManager.OpenWebConfiguration("/Manual")
      cCDS = rootWebConfig_CDS.ConnectionStrings.ConnectionStrings("cCDS").ConnectionString
      %>
    <%
      labelScreenName.Text = "Test" & " screen"
      %>
    <%
      If Not (USR_RoleName = "ADMIN" Or USR_RoleName = "RBI" Or USR_RoleName = "SO" Or USR_RoleName = "STO") Then
          Response.Redirect("../../default.aspx")
      Else
          If USR_RoleName = "ADMIN" Or USR_RoleName = "STO" Then
              Response.Redirect("./test.aspx")
          Else
              If USR_RoleName = "ADMIN" Or USR_RoleName = "RBI" Then
                  Response.Redirect("./test2.aspx")
              End If
          End If
      End If
      %>
    <html xmlns="http://www.w3.org/1999/xhtml">
      <script runat="server"></script>
      <head id="Head1" runat="server">
        <title></title>
      </head>
      <body>
        <form id="form1" runat="server">
          <div id="divAppTitle" style="font-size: 16px; border-bottom: #000066 2px solid">
            Manual Input BI
            <br style="font-size: 12px" />
            <asp:Label ID="labelScreenName" Style="font-size: 12px" runat="server"></asp:Label>
            <span id="USR_Name" style="font-size: 12px">/ Logged in as <%= Me.User.Identity.Name.ToString()%> /</span>
          </div>
          <div>
            <table>
              <tr>
                <td>
                  <asp:Label ID="labelSelectFY" runat="server" Width="100px" Font-Names="Verdana" Font-Size="10pt">FY</asp:Label>
                </td>
                <td>
                  <asp:DropDownList ID="DropDownListFY" runat="server" Font-Names="Verdana" Font-Size="10pt" AutoPostBack="True">
                    <asp:listitem text="Red" value="1"></asp:listitem>
                    <asp:listitem text="Black" value="2"></asp:listitem>
                    <asp:listitem text="Blue" value="3"></asp:listitem>
                    <asp:listitem text="Green" value="4"></asp:listitem>
                    <asp:listitem text="Yellow" value="5"></asp:listitem>
                  </asp:DropDownList>
                </td>
              </tr>
              <tr>
                <td>
                  <asp:Label ID="lblSelectYM" runat="server" Width="100px" Font-Names="Verdana" Font-Size="10pt">YM</asp:Label>
                </td>
                <td>
                  <asp:DropDownList ID="dropdownSelectYM" runat="server" Font-Names="Verdana" Font-Size="10pt" AutoPostBack="True">
                    <asp:listitem text="Red" value="1"></asp:listitem>
                    <asp:listitem text="Black" value="2"></asp:listitem>
                    <asp:listitem text="Blue" value="3"></asp:listitem>
                    <asp:listitem text="Green" value="4"></asp:listitem>
                    <asp:listitem text="Yellow" value="5"></asp:listitem>
                  </asp:DropDownList>
                </td>
              </tr>
            </table>
            <table>
              <tr>
                <td>
                  <asp:Label ID="lblSelectCountry" runat="server" Width="100px" Font-Names="Verdana" Font-Size="10pt">Select Country</asp:Label>
                </td>
                <td>
                  <asp:DropDownList ID="dropdownSelectCountry" runat="server" Font-Names="Verdana" Font-Size="10pt" AutoPostBack="True">
                    <asp:listitem text="Red" value="1"></asp:listitem>
                    <asp:listitem text="Black" value="2"></asp:listitem>
                    <asp:listitem text="Blue" value="3"></asp:listitem>
                    <asp:listitem text="Green" value="4"></asp:listitem>
                    <asp:listitem text="Yellow" value="5"></asp:listitem>
                  </asp:DropDownList>
                </td>
              </tr>
              <tr>
                <td>
                  <asp:Label ID="lblSelectStore" runat="server" Width="100px" Font-Names="Verdana" Font-Size="10pt">Select Store</asp:Label>
                </td>
                <td>
                  <asp:DropDownList ID="dropdownSelectStore" runat="server" Font-Names="Verdana" Font-Size="10pt" AutoPostBack="True" >
                    <asp:listitem text="Red" value="1"></asp:listitem>
                    <asp:listitem text="Black" value="2"></asp:listitem>
                    <asp:listitem text="Blue" value="3"></asp:listitem>
                    <asp:listitem text="Green" value="4"></asp:listitem>
                    <asp:listitem text="Yellow" value="5"></asp:listitem>
                  </asp:DropDownList>
                </td>
              </tr>
            </table>
            <p>
              <asp:Label ID="labelDEVStatusInfo" runat="server" BackColor="#FFFFFF" ForeColor="#999999" Font-Names="Verdana" Font-Size="10pt" />
            </p>
            <div id="divMenu" runat="server" style="font-size: 10px; right: 10px; visibility: visible; ; top: 10px">
              <p>
                <asp:PlaceHolder ID="Menu_Content" runat="Server"></asp:PlaceHolder>
              </p>
            </div>
            <div id="divLoginStatus" runat="server" style="font-size: 10px; right: 0px; visibility: visible; ; top: 0px">
              <p>
                <asp:LoginStatus ID="LoginStatus1" runat="server" Font-Size="10px" Width="37px" BorderStyle="Solid" BorderWidth="1px" BorderColor="White" LogoutText="" LogoutAction="RedirectToLoginPage" />
              </p>
            </div>
          </div>
        </form>
      </body>
    </html>

    Can someone please how to diagonis further or how to solve the issue. Its very painful situation now as I do not have anything in my mind to fix this. How to reduce this ASPNetPageRenderLeave time?

    Monday, May 11, 2020 11:43 AM

All replies

  • User-943250815 posted

    Just a guess. Check if your server is set to Power Plan "High Performance"

    Monday, May 11, 2020 10:35 PM
  • User-654958644 posted

    Just a guess. Check if your server is set to Power Plan "High Performance"

    Yes. Its running on High Performance mode

    Tuesday, May 12, 2020 2:14 AM
  • User-1330468790 posted

    Hi,  ritnetsys

      

    According to your description, I find that you have configured IIS accordingly and the setting of IIS should be no problem. Even thought there might be some improvements, it should not cause such a big impact.

    After you removed the database connection, the page that does not fill the dropdownlist through the connection database is much faster than before. However, I think that there is still a connection database for user verification in the sample page you provide so I suggest you could try it like this:

    • Delete the user verification part of the sample page to see if the page response time returns to normal.
    • If this is indeed the case, then it is basically determined that the problem lies in the interaction with the database. Or there is no corresponding adjustment to the database.

     

    Looking forward to seeing any update.

    Best regards,

    Sean

    Wednesday, May 13, 2020 7:16 AM