Azure: Application Gateway Listeners Based Routing Configuration is not working.

Kartik Agarwal 26 Reputation points
2021-12-01T04:06:36.36+00:00

We have two environment Test and Stage. On the Test env Application Gateway Listeners and Rules have already configured. But for the Stage env we have to create Application Gateway Listeners and Rules , we have created as the same as in the Test env.
But the problem is the application listeners routing is not going through URL and may be there is a chance we missed any settings or to enable the Listeners routing, due to which our server is not hitting.
And our complete infrastructure is App Services based.
Here is the screenshot that server is not hitting.
153899-serverimg.png

And also here are some steps or screenshot as we created the Listeners and Rules and take care of some settings.
Please suggest us if we miss any settings o to enable the Listeners due to this is not working

  1. Here is our Listeners where we already uploaded the SSL Certificate. Please see the screenshot
    153981-listenersimg.png
  2. Here is our backend pool
    153900-backendpool-2.png
Azure Application Gateway
Azure Application Gateway
An Azure service that provides a platform-managed, scalable, and highly available application delivery controller as a service.
Azure Web Application Firewall
0 comments No comments
{count} votes

Answer accepted by question author
  1. GitaraniSharma-MSFT 50,181 Reputation points Microsoft Employee Moderator
    2021-12-02T11:31:16.06+00:00

    Hello @Kartik Agarwal ,

    Welcome to Microsoft Q&A Platform. Thank you for reaching out & hope you are doing well.

    I see your listener type is multi-site with Public frontend and certificate configured for HTTPs traffic. You also have the backend pool configured with an associated rule, which all seem correct. Now coming to the error message which says "this site can't be reached", may I know if you have created a CNAME mapping in your DNS to point hostnames to your Application gateway IP address?

    When you access a host name via the App gateway, the DNS resolves that host name to the public IP address of the App gateway (which should be configured as a CNAME in your DNS or local host files) and then the app gateway uses that host header to find the associated listener. Once it finds the correct listener, it checks the associated rule and use the configured http settings to direct the traffic to the configured backend service.

    Without the CNAME mapping in your DNS, the application gateway will not be aware of the host name/domain name that you are using to access the site.
    If you have not created a CNAME mapping to your Application gateway's IP in your DNS, you can also make use of host files in your local machine for the name resolution as part of testing.
    Reference : https://learn.microsoft.com/en-us/azure/application-gateway/create-multiple-sites-portal#edit-your-hosts-file-for-name-resolution

    Kindly let us know if the above helps or you need further assistance on this issue.

    ----------------------------------------------------------------------------------------------------------------

    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.