locked
IIS ARR Multiple Ports RRS feed

  • Question

  • User10229462 posted

    HI.

    I'm having a hard time configuring the balance in IIS via ARR with multiple ports. The difficulty is in working with different doors than the 80 and 443. On the same server I have applications on port 80, 443 and 8080. I managed to make it work on port 80 and 443. When I add port 8080 it is redirected to port 443.

    The structure is as follows:

    IP PUBLIC:80   > IIS ARR > Private IP1:80, PRIVATE IP2:80
    IP PUBLIC:443  > IIS ARR > Private IP1:443, PRIVATE IP2:443
    IP PUBLIC:8080 > IIS ARR > Private IP1:8080, PRIVATE IP2:8080

    The rules I have for url rewrite are:

                    <rule name="ARR_serverfarm_loadbalance" enabled="true" patternSyntax="Wildcard" stopProcessing="true">
                        <match url="*" />
                        <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
                        <action type="Rewrite" url="http://serverfarm/{R:0}" />
                  </rule>

    Other Rule:

                    <rule name="forward proxy" enabled="true" patternSyntax="Wildcard" stopProcessing="true">
                        <match url="*" negate="true" />
                        <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
                            <add input="{HTTP_HOST}" pattern="*" />
                        </conditions>
                        <action type="Rewrite" url="http://{C:1}/{R:0}" />
                    </rule>

    I appreciate the help.

    </div> </div> </div>

    Friday, May 28, 2021 7:41 PM

Answers

  • User10229462 posted

    Hi.

    In summary, I couldn't configure port 80, 443 and 8080 on the same destination and ended up creating two different webfarms, one on 80 and 443 and another on 8080 and 8443.
    After that as a final solution, I created conditions based on the URL.

    Example:

    <conditions trackAllCaptures = "true" >
    <add input = "{URL}" pattern = "^/app1/( . *)"/> 
    </conditions>

    • Marked as answer by An0nym0u5User Friday, September 17, 2021 12:00 AM
    Thursday, June 17, 2021 6:48 PM

All replies

  • User1065476709 posted

    Hi Christovam,

    Christovam

    I'm having a hard time configuring the balance in IIS via ARR with multiple ports. The difficulty is in working with different doors than the 80 and 443. On the same server I have applications on port 80, 443 and 8080. I managed to make it work on port 80 and 443. When I add port 8080 it is redirected to port 443.

    I suggest you use failed request tracking for troubleshooting.

    Using Failed Request Tracing Rules to Troubleshoot Application Request Routing

    Best regards,

    Sam

    Monday, May 31, 2021 1:37 AM
  • User10229462 posted

    Good Morning.

    I turned on tracing on the ARR server, but it doesn't generate the errors. I reviewed it again, so I believe there are no errors in this issue.
    I'm trying to create the rule with the source on port 8080 and destination on port 8080.
    If you have any further questions please let me know.

    Tuesday, June 1, 2021 12:27 PM
  • User1065476709 posted

    Hi Christovam,

    I turned on tracing on the ARR server, but it doesn't generate the errors. I reviewed it again, so I believe there are no errors in this issue.
    I'm trying to create the rule with the source on port 8080 and destination on port 8080.

    You can check the generated xml file, it will show where to redirect port 8080 to port 443.

    Best regards,

    Sam

    Friday, June 4, 2021 3:11 AM
  • User10229462 posted

    Hi.

    In summary, I couldn't configure port 80, 443 and 8080 on the same destination and ended up creating two different webfarms, one on 80 and 443 and another on 8080 and 8443.
    After that as a final solution, I created conditions based on the URL.

    Example:

    <conditions trackAllCaptures = "true" >
    <add input = "{URL}" pattern = "^/app1/( . *)"/> 
    </conditions>

    • Marked as answer by An0nym0u5User Friday, September 17, 2021 12:00 AM
    Thursday, June 17, 2021 6:48 PM