Results 1 to 8 of 8
  1. #1
    Untangler
    Join Date
    Apr 2010
    Posts
    37

    Default Forwarding traffic to multiple Web Servers

    Hello,

    How can one forward web traffic to two different servers without using ports in web address?

    My current setup is as follows:
    external ip: xxx.xxx.xxx.34
    port 80 goes to web server1 and port 8080 to server2

    What I want to accomplish is that when user types into browser www.mydomain.com browser goes to server1.mydomain.com but when the user types in the browser server2.mydomain.com it will display the web page on the server2.

    server2.mydomain.com has an external ip/dns registration. I have added its ip to IP alias in Untangle and made appropriate port forward and firewall rules, but when I type server2.mydomain.com into browser from external network it will go to regular website hosted on server1.

    So in a nutshell www.mydomain.com:80 should go to server1.mydomain.com:80
    and server2.mydomain.com:80 should direct to server2.mydomain.com:80

    From internal network everything is working ok, as it should.

    What I'm missing here?

  2. #2
    Untangle Ninja sky-knight's Avatar
    Join Date
    Apr 2008
    Location
    Phoenix, AZ
    Posts
    16,890

    Default

    You need two different IP addresses to perform this. You cannot forward dns names, all you can forward are IP addresses.
    Rob Sandling, BS:SWE, MCP
    Intouch Technology
    Phone: 480-272-9889
    rob@intouchtechllc.com

    UntangleAppliances.com
    Phone: 866-794-8879

  3. #3
    Untangler
    Join Date
    Apr 2010
    Posts
    37

    Default

    Yes, of course. Maybe I was not clear enough.

    external ip1 (the untangle external address) is: xxx.xxx.xxx.34
    This is the address that associated with the www.mydomain.com dns name and would be forwarded to web server1.
    server2.mydomain.com has its own external ip adress xxx.xxx.xxx.35 and dns registration (that I added as IP alias in untangle) and its own internal ip.

    In internal network obviously everything works ok. server1 displays its own web at port 80 and server2 displays its own web at port 80.

    But when I type server2.mydomain.com into browser from external network I will be directed to web page at server1.

  4. #4
    Untangle Ninja
    WebFooL's Avatar
    Join Date
    Jan 2009
    Location
    Sweden (Eskilstuna)
    Posts
    4,203

    Default

    Can you post screenshots of your portforwards?

  5. #5
    Untangle Ninja sky-knight's Avatar
    Join Date
    Apr 2008
    Location
    Phoenix, AZ
    Posts
    16,890

    Default

    The second IP address needs to be configured as an Alias on External. Once that is complete, your port-forwarding can use it to forward on to the web server.

    Beware the port forward when you use multiple external addresses can no longer use the destined local flag, this means you must use advanced forwards. Use destination address instead and manually specify the public address you're forwarding from.

    A screen shot would be the easiest way to avoid error here.
    Rob Sandling, BS:SWE, MCP
    Intouch Technology
    Phone: 480-272-9889
    rob@intouchtechllc.com

    UntangleAppliances.com
    Phone: 866-794-8879

  6. #6
    Untangler
    Join Date
    Apr 2010
    Posts
    37

    Default

    Ok, here are the screenshots.

    The first image shows the port forward to first server (server1.mydomain.com) that displays the web page of www.mydomain.com.
    The second image shows the port forward to server2 (server2.mydomain.com). This host the website that should appear when typing in server2.mydomain.com.

    Currently both www.mydomain.com and server2.mydomain.com lead to web page hosted on server1.mydomain.com

    When I delete the Destined Local attribute and try to use only Source Address I will get booted from Untangle management UI for couple of minutes with error "untangle web management not available" and all the traffic to web server1 will halt.
    Attached Images Attached Images

  7. #7
    Master Untangler
    Join Date
    Aug 2008
    Posts
    511

    Default

    Reread Rob's post. You want destination address, not source address.

  8. #8
    Untangle Ninja sky-knight's Avatar
    Join Date
    Apr 2008
    Location
    Phoenix, AZ
    Posts
    16,890

    Default

    And you must not use Destined Local! That stands for "all IP addresses on Untangle". So your second port 80 forward will never match anything. BOTH rules need fixed.
    Rob Sandling, BS:SWE, MCP
    Intouch Technology
    Phone: 480-272-9889
    rob@intouchtechllc.com

    UntangleAppliances.com
    Phone: 866-794-8879

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

SEO by vBSEO 3.6.0 PL2