Live Chat Icon For mobile
Live Chat Icon

ASP.NET FAQ - Deployment Issues

Find answers for the most frequently asked questions
Expand All Collapse All

This happens for example, when you try to export data to excel from a datagrid.

The problem occurs if the server is using Secure Sockets Layer (SSL) and has added one or both of the following HTTP headers to the response message:


Pragma: no-cache
Cache-control: no-cache,max-age=0,must-revalidate

For more details refer PRB: Internet Explorer Is Unable to Open Office Documents from an SSL Web Site

Permalink

Here is an excerpt from the KB article: KB 816782

Find the ASP.NET Version Used for the Application
View the script map for an ASP.NET application to determine the version of ASP.NET that the application uses. To view the script map for an ASP.NET application, follow these steps:

  1. Click Start, point to Programs, and then click Control Panel.
  2. Double-click Administrative Tools, and then double-click Internet Information Services (IIS).
  3. Expand local computer, expand Web Site, and then expand Default Web Site.
  4. Locate the folder that contains the ASP.NET application.
  5. Right-click the folder that contains the ASP.NET application, and then click Properties.
  6. Click the Directory tab, and then click Configuration. The Application Configuration dialog box opens.
  7. Click the Mappings tab, and then select an ASP.NET application extension, such as .asmx or .aspx.
    The Executable Path column of the dialog box lists the path to the ASP.NET ISAPI version that the application uses. By default, the ASP.NET ISAPI is installed in %WindowsDirectory%\Microsoft.NET\Framework\%versionNumber%. The version number in the path indicates the version number of the ASP.NET ISAPI that the application uses. The ASP.NET ISAPI version determines the version of the runtime that the application uses.

Use Aspnet_regiis.exe to Update the Script Map
To make it easier to reconfigure the script map for an ASP.NET application, each installation of the .NET Framework is associated with a version of the ASP.NET IIS Registration tool (Aspnet_regiis.exe). You can use this tool to remap an ASP.NET application to the ASP.NET ISAPI version associated with the tool.

Note Because Aspnet_regiis.exe is linked to a specific version of the .NET Framework, you must use the appropriate version of Aspnet_regiis.exe to reconfigure the script map for an ASP.NET application. Aspnet_regiis.exe only reconfigures the script map of an ASP.NET application to the ASP.NET ISAPI version associated with the tool

Configure ASP.NET 1.0 for the Application
When ASP.NET 1.1 is configured on the root Web site, follow these steps to configure ASP.NET 1.0 for an application:

  1. Click Start, and then click Run. In the Open text box, type cmd, and then click OK.
  2. At the command prompt, locate the following directory path:
    %WindowsDirectory%\Microsoft.NET\Framework\v1.0.3705\
  3. Type the following command to configure the ASP.NET 1.0 application in IIS:
    
    aspnet_regiis -s w3svc/1/root/ApplicationName 
    

    To remove ASP.NET 1.0 from this application, repeat steps 1and 2, and then type the following command:

    
    aspnet_regiis -k w3svc/1/root/ApplicationName
    

Configure ASP.NET 1.1 for the Application
When ASP.NET 1.0 is configured on the root Web site, follow these steps to configure ASP.NET 1.1 to run an application:

  1. Click Start, and then click Run. In the Open text box, type cmd, and then click OK.
  2. At the command prompt, locate the following directory path:
    %WindowsDirectory%\Microsoft.NET\Framework\v1.1.4322
  3. If ASP.NET 1.1 is not already registered, type the following command to register it:
    aspnet_regiis -ir
    Note The -ir option registers ASP.NET 1.1 without updating the scripts in IIS.
  4. Type the following to configure the ASP.NET 1.1 application in IIS:
    
    aspnet_regiis -s w3svc/1/root/ApplicationName 
    

    To remove ASP.NET 1.1 from this application, repeat steps 1 and 2, and then type the following command:

    
    aspnet_regiis -k w3svc/1/root/ApplicationName
    
Permalink

By default, ASP.NET runs its worker process (Aspnet_wp.exe) with a weak account (the local machine account, which is named ASPNET) to provide a more secure environment. On a domain controller or on a backup domain controller, all user accounts are domain accounts and are not local machine accounts. Therefore, Aspnet_wp.exe fails to start because it cannot find a local account named ‘localmachinename\ASPNET’. To provide a valid user account on the domain controller, you must specify an explicit account in the section of the Machine.config file, or you must use the SYSTEM account.
For more details : FIX: ASP.NET Does Not Work with the Default ASPNET Account on a Domain Controller
Permalink

This is because if you have the /3GB boot switch enabled, the ASP.NET worker process (Aspnet_wp.exe) does not start. For more information see Microsoft Knowledge Base Article – 320353

To create and set the ‘ASPNETENABLE3GB’ environment variable as mentioned in the above article, right click MyComputer ->Properties->Advanced > Environment Variables > System variables > New.

Add the variable name in the top text box and the value in the lower textbox.

Permalink

When you install the .Net framework on your web server, it installs some script files (including the above) under the root folder (usually ‘C:\inetpub\wwwroot’ if you do a default installation) . You can then find the above file at ‘C:\Inetpub\wwwroot\aspnet_client\system_web\1_1_4322’, for example.

The above problem could happen if you reconfigured your web root directory to be a different one after you installed ASP.Net in your web server. If that is the case, then run ’aspnet_regiis -c’ (utility is under %windir%\Microsoft.NET\Framework\v1.1.4322, for example) or copy over manually the above script files into a similar sub-directory below your current web root directory. Also, if you look at the error message in detail, you will notice where the file is supposed to be.

Permalink

You would get this error if the application mappings for ASP.NET file name extensions (such as .aspx) are not configured correctly in Microsoft Internet Information Services (IIS).

To resolve this go to C:\Windows Directory\Microsoft.Net\Framework\Version and type aspnet_regiis -i to configure the required application mappings correctly

On Trying to Debug an application, by the F5 key I get the error: ‘Error while trying to run project: Unable to start debugging on the web server. Catastrophic failure’?

This issue occurs if the account that is used to run the ASP.NET Worker process (by default, the ASPNET user account) is not assigned the ‘Impersonate a client after authentication’ user right in the ‘Local Security Policy’ settings. This issue may occur when you install Microsoft Visual Studio .NET after you install Windows 2000 Service Pack 4 (SP4) on the computer. In this situation, the ASPNET account is not assigned the ‘Impersonate a client after authentication’ user right in the ‘Local Security Policy’ settings.To resolve it, please use the method at: To work around the problem, manually assign Impersonate a client after authentication to the IWAM account. To do so, follow these steps:

  1. Click Start, point to Programs, point to Administrative Tools, and then click Domain Controller Security Policy.
  2. Click Security Settings.
  3. Click Local Policies, and then click User Rights Assignment.
  4. In the right pane, double-click Impersonate a client after authentication.
  5. In the Security Policy Setting window, click Define these policy settings.
  6. Click Add, and then click Browse.
  7. In the Select Users or Groups window, select the IWAM account name, click Add, and then click OK.
  8. Click OK, and then click OK again.

To enforce an update of computer policy, type the following command: secedit /refreshpolicy machine_policy /enforce

At a command prompt, type iisreset. In case your server is a Domain Controller Refer PRB: ‘Catastrophic Failure’ Error Message When You Try to Debug an ASP.NET Application on Windows 2000 Domain Controller

Permalink

This is 1 of the most commonly asked question & since the release of Windows 2000, IIS is no longer available for download as it is part of the OS.

IIS 4 was the last version of IIS that was available for download. Since the advent of Windows 2000, IIS has been part of the OS & is NOT available for download.

OS Version – IIS Version

  • Windows 2000 – IIS 5
  • WindowsXP Pro – IIS 5.1
  • Windows Server 2003 – IIS 6
    Permalink

    To verify if IIS is installed, go to your ’Add or Remove Programs’ utility in the Control panel and click on the ’Add/Remove Windows Components’ in the side menu.

    On XP Pro and below, you should see an item called ‘Internet Information Services (IIS)’. If this is checked, IIS should be installed.

    On Win2K3, you’ll see ‘Application Server’. If this is checked, select it and then click ’Details’. Another form should open which will contain ‘Internet Information Services (IIS)’. If it is checked, IIS should be installed.

    Permalink

    This is because the server control tags were not converted into their respecting HTML element tags by ASP.Net. This happens when ASP.Net is not properly registered with IIS.

    .Net framework provides an Administration utility that manages the installation and uninstallation of multiple versions of ASP.NET on a single machine. You can find the file in C:\WINNT\Microsoft.NET\Framework\v**\aspnet_regiis.exe

    use the command: aspnet_regiis.exe -u —> to uninstall current asp.net version.

    use the command: aspnet_regiis.exe -i —> to install current asp.net version.

    Permalink

    To configure WebApp1 to use ASP.NET 1.0, follow these steps:

    1. Click Start, and then click Run.
    2. In the Open text box, type cmd, and then click OK.
    3. At the command prompt, locate the following directory:
      WindowsDirectory\Microsoft.NET\Framework\v1.0.3705\
    4. At the command prompt, type one of the following commands:
      • To Install ASP.NET 1.0 recursively

        aspnet_regiis -s W3SVC/1/ROOT/WebApp1

      • To Install ASP.NET 1.0 non-recursively

        aspnet_regiis -sn W3SVC/1/ROOT/WebApp1

    To configure WebApp2 to use ASP.NET 1.1, follow these steps:

    1. Click Start, and then click Run.
    2. In the Open text box, type cmd, and then click OK.
    3. At the command prompt, locate the following directory:
      WindowsDirectory\Microsoft.NET\Framework\v1.1.4322\
    4. At the command prompt, type one of the following commands:
      • To Install ASP.NET 1.1 recursively

        aspnet_regiis -s W3SVC/1/ROOT/WebApp2

      • To Install ASP.NET 1.1 non-recursively

        aspnet_regiis -sn W3SVC/1/ROOT/WebApp2

    Permalink

    Share with

    Couldn't find the FAQs you're looking for?

    Please submit your question and answer.