500 internal server error

      45
Was this troubleshooting playbook helpful? Please let us know by clicking Send Feedback.

Videos

Watch the following videos to lớn learn more about solving 500 Internal vps Errors.

Bạn đang xem: 500 internal server error

đoạn clip Description
Introduction Provides an introduction to 500 Internal server Errors and possible causes. Also demonstrates a real time 500 Internal server error along with steps lớn troubleshoot và resolve the error.
Handle Service Callout and Extract Variable errors Demonstrates two 500 Internal vps Errors caused by Service Callout and Extract Variable policies and shows how to troubleshoot và resolve these errors.
Handle JavaScript policy errors Shows a 500 Internal vps Error caused by a JavaScript policy & the steps lớn troubleshoot and resolve this error.
Handle failures from backend servers Shows example 500 Internal vps Errors caused by a failure in backend server and shows steps to resolve the errors.

Symptom

The client application gets an HTTP status code of 500 with the message "Internal vps Error" as a response for API calls. The 500 Internal hệ thống error could be caused by an error during the execution of any policy within Edge or by an error on the target/backend server.

The HTTP status code 500 is a generic error response. It means that the server encountered an unexpected condition that prevented it from fulfilling the request. This error is usually returned by the hệ thống when no other error code is suitable.

Error Messages

You may get the following error message:

HTTP/1.1 500 Internal hệ thống Error In some cases, you may observe another error message which has more details. Here is a sample error message:

"fault": "detail": "errorcode":"steps.servicecallout.ExecutionFailed" , "faultstring":"Execution of ServiceCallout callWCSAuthServiceCallout failed. Reason: ResponseCode 400 is treated as error"

Possible Causes

The 500 Internal vps Error could be thrown due khổng lồ a number of different causes. In Edge, the causes can be classified into two main categories based on where the error occurred:

Cause Details Detailed Troubleshooting Steps are Provided For
Execution Error in an Edge Policy A Policy within the API proxy may fail for some reason. Edge Private và Public Cloud users
Error in the Backend Server The backend server may fail for some reason.

Xem thêm: "Mysql Server Has Gone Away" Error, Mysql Server Has Gone Away Error

Edge Private and Public Cloud users

Execution Error in an Edge Policy

A Policy within the API proxy may fail for some reason. This section explains how to lớn troubleshoot the issue if the 500 Internal vps Error occurs during the execution of a policy.

Diagnosis

Note: The 500 Internal server error can arise due to many different reasons. For example, a 500 error can occur when a policy executes or it can originate on the backend target server. Because of this, we"ve provided below several general diagnostic steps khổng lồ help you identify và troubleshoot this type of issue. We also provide several examples that give specific steps for resolving these errors, depending on the cause of the problem. Diagnostic Steps for Private và Public Cloud Users

If you have the trace UI session for the error, then:

Select the API request that is failing with 500 Internal hệ thống Error in the trace. Examine the request và select the specific policy that has failed or the flow named "Error" that is immediately following the failed policy in the trace. Get more details about the error either by checking the "error" field under the Properties section or the Error content. Using the details you"ve collected about the error, try lớn determine its cause. Diagnostic Steps for Private Cloud Users Only

If you don"t have the trace UI session, then:

kiểm tra the Message Processor logs (/opt/xugame.biz/var/log/edge-message-processor/logs/system.log) and search for the quality request message id in it. If you bởi vì find the unique request message ID, see if you can get more information about the cause for the failure.

Resolution

If you have determined the cause of the issue with the policy, try to correct the problem by fixing the policy và redeploying the proxy.

The following examples illustrate how khổng lồ determine the cause & resolution for different types of issues.

If you need further assistance in troubleshooting 500 Internal server Error or you suspect that it"s an issue within Edge, tương tác xugame.biz Support.

Example 1: Failure in Service Callout policy due to lớn an error in the backend server

If the điện thoại tư vấn to the backend vps fails within the Service Callout policy with any error such as 4XX or 5XX, then it will be treated as 500 Internal hệ thống Error.

Here"s an example where the backend service fails with a 404 error within the Service Callout policy. The following error message is sent khổng lồ the over user:

"fault": "detail": "errorcode":"steps.servicecallout.ExecutionFailed" ,"faultstring":"Execution of ServiceCallout service_callout_v3_store_by_lat_lon failed. Reason: ResponseCode 404 is treated as error" } The following trace UI session shows 500 status code caused due to an error in Service Callout policy:

*

In this example, the "error" property lists the reason for the Service Callout policy failure as "ResponseCode 404 is treated as error". This error might occur if the resource being accessed via the backend server URL in the Service Callout policy is not available. Kiểm tra the availability of the resource on the backend server. It might not be available temporarily/permanently or it might have been moved lớn a different location. Example 1 Resolution kiểm tra the availability of the resource on the backend server. It might not be available temporarily/permanently or it might have been moved to lớn a different location. Fix the backend hệ thống URL in the Service Callout policy to point lớn a valid & existing resource. If the resource is only temporarily unavailable, then try making the API request once the resource is available. Example 2: Failure in Extract Variables Policy

Let"s now look at another example, where 500 Internal vps Error is caused due khổng lồ an error in the Extract Variables policy và see how to troubleshoot và resolve the issue.

The following trace in UI session shows 500 status code due to an error in Extract Variables policy:

*

Select the failing Extract Variables policy, scroll down & look at the "Error Content" section for more details:
*
The Error nội dung indicates that the"serviceCallout.oamCookieValidationResponse" variable is not available in the Extract Variables policy. As the name of the variable indicates, it should be holding the response of the preceding Service Callout policy. Select the Service Callout policy in the trace & you might find that the "serviceCallout.oamCookieValidationResponse" variable was not set. This indicates that the điện thoại tư vấn to the backend service failed, resulting in an empty response variable. Though the Service Callout policy has failed, the execution of the policies after Service Callout policy continue because the "continueOnError" flag in the Service Callout policy is set to true, as shown below:

Callout.OamCookieValidation false serviceCallout.oamCookieValidationResponse http://Url cảnh báo the quality message id "X-xugame.biz.Message-ID" for this specific API request from the trace, as follows: Select the "Analytics Data Recorded" phase from the request. Scroll down and lưu ý the value of X-xugame.biz.Message-ID.

*

Note:
The following steps can only be carried out by the Edge Private Cloud users. View the Message Processor log (/opt/xugame.biz/var/log/edge-message-processor/system.log) and search for the quality message id noted down in step #6. The following error message was observed for the specific API request: