Skip to main content

AWS application load balancer 404 [Resolved]

I'm following tutorial to create an application load balancer and the listener path is as follow:

LB -> path -> server1 or -> path -> server2

The problem:

I can get to server1 via the LB url ok but when I tried to go to server2 i received 404 page.

If i delete & reconfigure the LB & swap the server around then I can get to server2 but will get 404 if i tried to go to server1.

I can get to both server just fine directly.

Thanks for your help




Question Credit: vikiro
Question Reference
Asked June 25, 2019
Posted Under: Network
1 Answers

I think you're getting 404 because when you access {YourALB}/server1/something the path is passed on to {IntASG}/server1/something instead of {IntASG}/something. If you can check the IntASG access logs you will probably see it there.

IIRC there is a way to remove the routing part of the path before forwarding it on to the backend. Check the ALB docs, it will be described there.

Hope that helps :)

credit: MLu
Answered June 25, 2019
Your Answer