Troubleshooting Bad Request and Internal Server error
When a server responds with a Bad Request (400) or Internal Server Error (500), it typically indicates issues with how the request is being made or processed. The reasons for these errors can vary, but the most common causes are:
Incorrectly formatted POST data
- Malformed or improperly encoded URL format
- Unexpected User Agent settings
Below are steps to help diagnose and resolve these issues.
Incorrectly formatted POST data
If the server returns a 400 Bad Request, it typically means the request contains malformed or invalid data. To resolve this issue, follow these steps:
- Ensure that the data being sent with the request matches the expected format. This is particularly important for POST requests.
- Cross-check the request data format by reviewing the API documentation or the endpoint specification.
- You can test the request using tools like cURL or wget to verify the format.
Internal Server Error
An Internal Server Error (500) indicates that something went wrong on the server while processing the request. Common causes include server bugs, misconfigurations, or issues in the request itself. Here's how to troubleshoot:
Review the server logs for any exceptions or errors occurring while handling the request. This will help pinpoint what went wrong during processing.
- If you have access to server logs, look for stack traces or error messages that can provide insight into the problem. It may be an issue with how the server is handling the request or a server-side bug.
Improperly formatted URLs can also cause issues when monitoring endpoints.
- URL Encoding: URLs should be entered without prior encoding. The system will automatically encode the URL when making the request. If you have added an already encoded URL for monitoring, then there will be double encoding while making the request causing an error.
Unexpected User Agent
Certain servers are configured to reject requests that appear to come from non-browser clients. This may cause a 400 or 500 error. If you suspect this is the issue, try modifying the User Agent header of your request.
- You can find your current User Agent value by visiting WhatIsMyBrowser.
- Enter the User Agent into the "User-Agent" field in HTTP URL add monitor page > HTTP configuration section.
- Save the configuration, and test.
Still facing issues?
If the problem persists, contact our support team along with the following details: - A screenshot of the "Add Monitor" page.
- The URL debug tool response for the URL monitor.
- Reproduce the issue and share the latest Support Information File (SIF) from Applications Manager, with the "Print all logs" option enabled. To do this, go to Settings > Logging, and choose "Print all logs".
New to ADSelfService Plus?
Related Articles
Troubleshooting Server error responses
When encountering the following server error responses—Internal Server Error (500), Bad Gateway (502), Service Unavailable (503), and Gateway Timeout (504)—it typically indicates issues with the server hosting the URL. Troubleshooting Review your ...
Real User Monitor (RUM) - Troubleshooting
If the monitor has not polled data for a long time, follow the steps below for troubleshooting: Step 1: Check the RUM Agent configuration Real User Monitor requires the RUM Agent to be installed and mapped to the Applications Manager. Refer the help ...
Troubleshooting URL Monitor
Here are few of the common errors you may come across in URL monitor, we have mentioned the steps you can follow to troubleshoot them. General troubleshooting for URL monitor Ensure that the URL is accessible from the server in which Applications ...
Mail Server Monitor - Troubleshooting
Common Mail Server Monitor Errors and Troubleshooting Guide 1. Unknown Host Error Description: This error occurs when the mail client cannot resolve the hostname of the mail server to an IP address. The issue typically arises from DNS resolution ...
DNS Monitor - Troubleshooting
Common DNS Monitor Errors and Troubleshooting Guide 1. Host Not Found Description: The DNS server was unable to locate the requested lookup address. Possible Causes: This may happen if the hostname is incorrect, the domain does not exist, or there is ...