Getting 500 internal server error in IIS published site. Though it was working fine previouly.

Kurakula, Julia 21 Reputation points
2022-10-12T03:40:39.247+00:00

Getting 500 internal server error in IIS published site. Though it was working fine previouly.

HTTP Error 500.0 - Internal Server Error

The page cannot be displayed because an internal server error has occurred.

Most likely causes:
•IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred.
•IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly.
•IIS was not able to process configuration for the Web site or application.
•The authenticated user does not have permission to use this DLL.
•The request is mapped to a managed handler but the .NET Extensibility Feature is not installed.

Things you can try:
•Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account.
•Check the event logs to see if any additional information was logged.
•Verify the permissions for the DLL.
•Install the .NET Extensibility feature if the request is mapped to a managed handler.
•Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click here.

Detailed Error Information:

Module
ManagedPipelineHandler

Notification
ExecuteRequestHandler

Handler
PageHandlerFactory-Integrated-4.0

Error Code
0x00000000

Requested URL
https://blahblah.com:443/default.aspx

Physical Path
D:\inetpub\wwwroot\BlahBlah\default.aspx

Logon Method
NTLM

Logon User
NA\abc

More Information:
This error means that there was a problem while processing the request. The request was received by the Web server, but during processing a fatal error occurred, causing the 500 error.
View more information »

Microsoft Knowledge Base Articles:
•294807

Event logs in WCF server :
Event code: 4007
Event message: URL authorization failed for the request.
Event time: 10/11/2022 11:08:00 PM
Event time (UTC): 10/12/2022 4:08:00 AM
Event ID: 2a18d7231fff4b4db0e51109da3c05b0
Event sequence: 2
Event occurrence: 1
Event detail code: 0

Event logs in WebApp server:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 10/12/2022 12:19:11 AM
Event time (UTC): 10/12/2022 5:19:11 AM
Event ID: 230dc7cecc2f4535ad1fd8dea86bf9c4
Event sequence: 28
Event occurrence: 3
Event detail code: 0

Exception information:
Exception type: CommunicationException
Exception message: An error occurred while receiving the HTTP response to https://blah-ws.com/blah.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.

Server stack trace:
at System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException, HttpWebRequest request, HttpAbortReason abortReason)
at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message message, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

The underlying connection was closed: An unexpected error occurred on a receive.
at System.Net.HttpWebRequest.GetResponse()
at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)

Internet Information Services
.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,377 questions
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,256 questions
{count} votes

3 answers

Sort by: Most helpful
  1. Julia Kurakula 41 Reputation points
    2022-10-18T10:48:31.647+00:00

    I restarted the server and the database then it worked. Thanks anyways!

    2 people found this answer helpful.
    0 comments No comments

  2. Sam Wu-MSFT 7,036 Reputation points Microsoft Vendor
    2022-10-12T07:47:03.317+00:00

    @Kurakula, Julia

    The error information doesn't show the key factor that lead to this 500 error, please enable failed request tracing to see details about 500 error.

    Besides, this problem may be related to permissions, you can try the following methods to solve the problem:

    1. Set application pool identity to NetworkService or LocalySystem, If you just want use ApplicationPoolIdentity, you could try to grant permission for "apppool/<myapppoolname>".
    2. Enable allow 32-bit application in application pool advanced setting.

    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  3. Robert Srigley 0 Reputation points
    2024-03-28T13:02:41.25+00:00

    Can you clarify or provide an example of what you could try to grant permission for "apppool/<myapppoolname>". means?

    Thank you.

    0 comments No comments