After adding Agents to protection, they go offline. When the metadata is refreshed for the Agent, the following error is present:
Exception chain:
•The remote server returned an error: (502) Bad Gateway.
•Call to service method https://bass:8006/apprecovery/api/agent/metadata/fullMetadata PUT failed: The remote server returned an error: (502) Bad Gateway.
•Agent is offline
Replay.Core.Contracts.Agents.AgentIsOfflineException: Agent is offline ---> WCFClientBase.ClientServerErrorException: Call to service method https://bass:8006/apprecovery/api/agent/metadata/fullMetadata PUT failed: The remote server returned an error: (502) Bad Gateway. ---> Microsoft.Http.HttpStageProcessingException: The remote server returned an error: (502) Bad Gateway. ---> System.Net.WebException: The remote server returned an error: (502) Bad Gateway.
at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
at System.Net.HttpWebRequest.GetRequestStream()
at Microsoft.Http.HttpWebRequestTransportStage.HttpTransportAsyncResult..ctor(Boolean preferSync, HttpRequestMessage request, HttpWebRequestTransportSettings settings, AsyncCallback callback, Object state)
at Microsoft.Http.HttpWebRequestTransportStage.ProcessRequestAndTryGetResponse(HttpRequestMessage request, HttpResponseMessage& response, Object& state)
at Microsoft.Http.HttpStageProcessingAsyncResult.NextRequest(HttpStageProcessingAsyncResult self)
There are two options to correct this issue:
1) Identify and fix the faulty event that is affecting DNS or WINS in the environment.
2) For each Agent, configure the settings so the Core connects to the Agent via IP address opposed to hostname. This can be done by navigating to Agent -> Configuration. At this window, click the change button in the upper right hand corner. Change the Host Name input to the IP address of the machine.