I have 2 Instance groups and HTTP load balancers for each one. Instance groups contain VMs that work on Windows Server 2012 with IIS inside.

When I send POST request from VM from one instance group to another using IP of its load balancer, I get 502 error instead of response.

Also sometimes I get this error when send GET requests.

When I send request directly to VM anything works correct.

What is the reason and how to fix error responses from load balancers?


  • 1
    @Kamran no, we didn't configure it, because actually all servers behind the balancer can perform same work. You think it'd be better to create URL map even in this situation? Strange thing is that we can send the POST request from Postman or any other tool on PC normally, but if we send such request from virtual machine behind second balancer it gets 502 Bad Gateway – Andrew Nikolin Jul 2 '15 at 10:22
  • @AndrewNikolin did you manage to solve this? – MeLight Jun 8 '16 at 11:11
  • @MeLight sadly, but I forgot if we did manage to solve this problem, I'm no longer working on that project – Andrew Nikolin Jun 10 '16 at 13:23

Here are some common causes of 5xx errors:

1) GCE instance itself can be returning 5xx. To confirm or discard this, the server logs must be examined.

2) GCE instance is taking longer to answer than the configured timeout in backend service.

3) Check the capacity setting in the backend service. It could be happening that the load is greater than the total available capacity setting (as per maximum connection rate or cpu based utilization). In that case the LB will drop overload

4) Verify that HC are working correctly.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.