Global.asa file not being found post server upgrade

Matt Brown 1 Reputation point
2025-12-02T16:59:41.7033333+00:00

We upgraded from Win 2016 to Win 2022. When I try to access the site, I am getting a 404 status code. In the Failed Request Logs folder, the log file is pointing to not finding the global.asa file. Except, it was never there in the first place. The infostructure has a wwwroot folder where it is looking for the said file, and then a subfolder which contains the global.asax file. I have combed over IIS and seeing if I defined anything differently post upgrade, and I am not seeing it. Any idea on what setting I need to change so it can look for the correct file?

Developer technologies | ASP.NET | Other
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Q&A Assist
    2025-12-02T16:59:50.8033333+00:00
    AI generated content. This question contains an answer created with AI from Q&A Assist. Learn more

    The issue you are encountering with the 404 status code and the missing global.asa file after upgrading to Windows Server 2022 may be related to how IIS is configured to handle application files. The global.asa file is typically used in classic ASP applications, while global.asax is used in ASP.NET applications. Since you mentioned that the global.asax file is present, it suggests that your application is likely ASP.NET-based.

    Here are a few steps you can take to troubleshoot and resolve the issue:

    1. Check Application Pool Settings: Ensure that the application pool for your site is set to use the correct version of the .NET Framework that your application targets.
    2. Verify Virtual Directory Configuration: If you are using a virtual directory, ensure that it is correctly configured in IIS and that the path points to the directory containing your global.asax file.
    3. Enable ASP.NET Features: Make sure that ASP.NET features are enabled in IIS. You can do this through the IIS Manager by selecting your site and checking the features under the IIS section.
    4. Review Request Filtering Settings: Check the request filtering settings in IIS to ensure that the global.asax file is not being blocked. You can find this under the site's features in IIS Manager.
    5. Inspect the Failed Request Logs: Since you mentioned the Failed Request Logs, review them for any additional details that might indicate why the request for global.asa is being made instead of global.asax.

    If the application is configured correctly and the issue persists, consider checking for any custom routing or URL rewriting rules that may be affecting how requests are processed.


    References:


  2. Tom Tran (WICLOUD CORPORATION) 3,040 Reputation points Microsoft External Staff Moderator
    2025-12-03T10:09:48.3+00:00

    Hi @Matt Brown ,

    Thanks for sharing all your details!

    Based on your description, I think the main root cause is that IIS is looking in the wrong place and falling back to classic ASP defaults. That’s why you see it searching for global.asa or default.asp, even though your app clearly uses global.asax and *.aspx pages. After the upgrade, the site’s root might not be pointing to the actual ASP.NET application folder.

    Perhaps you could try to check these workarounds first:

    • Point IIS to the correct folder: In IIS Manager, go to your site → Basic Settings and make sure the physical path is the folder that contains web.config, global.asax, and your *.aspx files. If your app is inside a subfolder, convert that subfolder into an Application so IIS treats it as the root for ASP.NET
    • Check ASP.NET features and handlers: On Windows Server 2022, confirm ASP.NET 4.8 and related components are installed under Server Manager → Add Roles and Features → Web Server (IIS) → Application Development. Also, in Handler Mappings, make sure ASP.NET handlers like PageHandlerFactory are present. (See Handlers)
    • Update the Application Pool: Use an app pool with .NET CLR v4.0 and Integrated pipeline mode. This ensures ASP.NET pages are processed correctly (See Application Pool Identities).
    • Clean up Default Documents: Remove default.asp or move Default.aspx to the top of the list so IIS doesn’t keep looking for classic ASP files. (See Default Document)

    I also managed to find other similar posts, please check them out when you have the time:

    Disclaimer: Some links are non-Microsoft websites. The pages appear to be providing accurate, safe information. Watch out for ads on the site that may advertise products frequently classifies as a PUP (Potentially Unwanted Products). Thoroughly research any product advertised on the site before you decide to download and install it.


    I hope this helps! If you have any questions, please feel free to comment below. I'll be happy to help!


  3. AgaveJoe 30,396 Reputation points
    2025-12-04T20:22:48.72+00:00

    It is highly likely that your IIS configuration is incorrect, but we need more information to diagnose the issue. Since a 500 error indicates the request reached the server but failed due to an unhandled exception or configuration mismatch, please provide the following:

    Configuration: Screenshots or details of how the application is set up in IIS.

    Fix Details: What specific changes did you make to resolve the initial 404 error?

    Framework Clarification: Your mention of global.asax suggests an older ASP.NET Framework application (Web Forms or MVC), but you also referenced wwwroot, which is standard for ASP.NET Core (unless you meant inetpub/wwwroot).

    Please clarify your target framework and application type so we can help you move forward.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.