Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Multiple Gateways on same subnet

    Routing and Multi WAN
    multi-wan subnet gateway routing firewall
    6
    26
    5.0k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • RicoR
      Rico LAYER 8 Rebel Alliance
      last edited by

      Your windows tracert not showing the pfSense LAN IP as first hop means you have something terribly wrong in your whole setup.

      -Rico

      D 1 Reply Last reply Reply Quote 0
      • D
        dr_tech @Rico
        last edited by

        @Rico said in Multiple Gateways on same subnet:

        Your windows tracert not showing the pfSense LAN IP as first hop means you have something terribly wrong in your whole setup.

        Oh yes, didn't notice that. I'll try setting up pfSense back from scratch and report back.

        DaddyGoD 1 Reply Last reply Reply Quote 0
        • D
          dr_tech
          last edited by

          I re-did all my steps, installing a new pfSense instance, adding a WAN interface with static IP and gateway (10.1.0.1), did a traceroute, all traffic was being routed through the pfSense box :

          10284131-bcde-4120-8996-c2d76d87257a-image.png

          Added a second gateway under System > Routing :

          33aac1c4-29b7-4414-b03b-2d25b03f6dad-image.png

          Modified the default firewall rule to route all traffic through second gateway :
          b3fcd643-6d38-4d22-8903-732bc0c20db2-image.png
          Redid a traceroute :
          7925ffc3-8b7a-466e-86c2-c263d47c235f-image.png
          Everything just breaks apart, NAT stops working, pfSense starts acting sort of like a switch, even when my LAN IP is stil 192.168.1.2/24.

          Please help

          DaddyGoD 1 Reply Last reply Reply Quote 0
          • DaddyGoD
            DaddyGo @dr_tech
            last edited by

            @dr_tech said in Multiple Gateways on same subnet:

            Oh yes, didn't notice that.

            this is not entirely the case...
            only ICMP question, listen....

            0f8131cd-b72f-42f9-a94c-df990984c39f-image.png

            Cats bury it so they can't see it!
            (You know what I mean if you have a cat)

            1 Reply Last reply Reply Quote 0
            • DaddyGoD
              DaddyGo @dr_tech
              last edited by

              @dr_tech said in Multiple Gateways on same subnet:

              Everything just breaks apart, NAT stops working, pfSense starts acting sort of like a switch,

              there may be serious configuration deficiencies ...
              I suggest you try to install only one WAN interface first

              and let us see that this behaves, because basically this is a dual-NAT configuration

              Cats bury it so they can't see it!
              (You know what I mean if you have a cat)

              1 Reply Last reply Reply Quote 0
              • D
                dr_tech
                last edited by

                @DaddyGo said in Multiple Gateways on same subnet:

                I suggest you try to install only one WAN interface first

                I did that, and until that point it works fine. (Pleas refer to my previous post)

                As soon as I add the second gateway, and set up the firewall rules to divert traffic through the second gateway, I stop seeing the first hop as the IP of pfSense.

                @dr_tech said in Multiple Gateways on same subnet:

                all traffic was being routed through the pfSense box :

                c4782351-7291-4894-bc0f-db61cc6de2ff-image.png

                (Only the first gateway - 10.1.0.1 Campus Network Installed)

                DaddyGoD 1 Reply Last reply Reply Quote 0
                • DaddyGoD
                  DaddyGo @dr_tech
                  last edited by

                  @dr_tech said in Multiple Gateways on same subnet:

                  Pleas refer to my previous post

                  try something please do this:

                  a1475b14-b1b4-4abf-90f8-39e284051576-image.png

                  Cats bury it so they can't see it!
                  (You know what I mean if you have a cat)

                  1 Reply Last reply Reply Quote 0
                  • D
                    dr_tech
                    last edited by

                    @DaddyGo said in Multiple Gateways on same subnet:

                    try something please do this:

                    I have already set it as automatic, the moment I added a second gateway.

                    DaddyGoD 1 Reply Last reply Reply Quote 0
                    • DaddyGoD
                      DaddyGo @dr_tech
                      last edited by DaddyGo

                      @dr_tech

                      What is this.......LAN /16???

                      400f88c9-59a2-44fb-b8d4-4611a27a8a01-image.png

                      +++edit:
                      do you want to say / 24

                      Cats bury it so they can't see it!
                      (You know what I mean if you have a cat)

                      1 Reply Last reply Reply Quote 0
                      • D
                        dr_tech
                        last edited by

                        @DaddyGo said in Multiple Gateways on same subnet:

                        do you want to say / 24

                        No, I meant that the subnet for my LAN is 255.255.0.0, not the default /24 block. But regardless, even if I try the 24 block, I face the same issue.

                        DaddyGoD 1 Reply Last reply Reply Quote 0
                        • DaddyGoD
                          DaddyGo @dr_tech
                          last edited by

                          @dr_tech

                          Ohhh...OK

                          if you think,..... I have a couple of lab pfSense units, I'll try to model your problem tomorrow...
                          we have saturday night at 9pm and my wife is waiting with a bottle of wine...

                          is this right for you?

                          btw:
                          what is a brief description of your hardware?

                          Cats bury it so they can't see it!
                          (You know what I mean if you have a cat)

                          1 Reply Last reply Reply Quote 0
                          • D
                            dr_tech
                            last edited by dr_tech

                            @DaddyGo said in Multiple Gateways on same subnet:

                            we have saturday night at 9pm

                            Sure, Have a nice weekend !!

                            My hardware :
                            Router 1 (College Router) : Asus RT-AC53 (10.1.0.1)
                            Router 2 (ISP Router): TP-Link Archer C1200 (10.1.0.2)

                            pfSense: Running on VMWare ESXi (with an Intel i350-T4 passed through)
                            Port 1 : Input from Asus RT-AC53
                            Port 2 : Connected to a Switch (pfSense LAN 192.168.1.0/24)

                            K 1 Reply Last reply Reply Quote 0
                            • K
                              kkrazyken @dr_tech
                              last edited by

                              @dr_tech Where is your connection from pfSense to the ISP router?

                              D 1 Reply Last reply Reply Quote 0
                              • D
                                dr_tech
                                last edited by

                                This post is deleted!
                                1 Reply Last reply Reply Quote 0
                                • D
                                  dr_tech @kkrazyken
                                  last edited by

                                  @kkrazyken
                                  Router 1 and Router 2 are connected to each other (DHCP turned off on router 2). This was so that I could just switch the gateway address on my phone/laptop to access blocked websites quickly, without changing the network.

                                  That is the reason why Router 1 is at 10.1.0.1/16 and Router 2 at 10.1.0.2/16.

                                  K 1 Reply Last reply Reply Quote 0
                                  • K
                                    kkrazyken @dr_tech
                                    last edited by

                                    @dr_tech I see, two Gateways on the same WAN interface. On the WAN interface page, what is the GW set to there? Does changing it make a difference?

                                    1 Reply Last reply Reply Quote 0
                                    • JeGrJ
                                      JeGr LAYER 8 Moderator
                                      last edited by

                                      As @johnpoz likes to say, that setup is bonkers ;)

                                      Yes you can use multiple gateways on a single WAN that's right, but it makes things complicated, as PF rules are setup to e.g. reply on the interface. But reply-to whom? The GW that is set up with the WAN IF is used primarily for many thing. If that's not the wanted you have to get those two Gateways to separate interfaces and add a second WAN interface to properly use MultiWAN the right way. Why are both gateways in the same subnet anyways? Is that necessary for anyone?

                                      I'd change the IP of the second WAN (the ISP one) and set it up as an additional WAN(2). That way all routing and forwarding functionality can work the right way right from the start including Gateway Groups or port forwardings that otherwise are hard to make work.

                                      Don't forget to upvote 👍 those who kindly offered their time and brainpower to help you!

                                      If you're interested, I'm available to discuss details of German-speaking paid support (for companies) if needed.

                                      1 Reply Last reply Reply Quote 2
                                      • johnpozJ
                                        johnpoz LAYER 8 Global Moderator
                                        last edited by johnpoz

                                        not bonkers - borked ;) hehhe

                                        https://www.urbandictionary.com/define.php?term=borked

                                        I'd change the IP of the second WAN (the ISP one) and set it up as an additional WAN(2).

                                        This is the correct answer... But doesn't explain why the pfsense lan drops out of the the trace.. So clearly there is info from this puzzle that is missing.

                                        An intelligent man is sometimes forced to be drunk to spend time with his fools
                                        If you get confused: Listen to the Music Play
                                        Please don't Chat/PM me for help, unless mod related
                                        SG-4860 24.11 | Lab VMs 2.7.2, 24.11

                                        1 Reply Last reply Reply Quote 0
                                        • D
                                          dr_tech
                                          last edited by

                                          So putting the gateways on separate subnets (hence IF) did in fact solve my issue, as reported here : https://forum.netgate.com/topic/156788/possible-to-select-gateway-based-on-url?_=1600096323225

                                          @JeGr said in Multiple Gateways on same subnet:

                                          But reply-to whom

                                          Maybe the mystery lies here in.

                                          1 Reply Last reply Reply Quote 0
                                          • JeGrJ
                                            JeGr LAYER 8 Moderator
                                            last edited by

                                            @dr_tech said in Multiple Gateways on same subnet:

                                            So putting the gateways on separate subnets (hence IF) did in fact solve my issue, as reported here

                                            You are opening another can of worms with incorrect subnet boundaries. Why not simply reconfigure those routers, too and why do they even have to talk to each other. That's a recipe for a (routing) desaster waiting to happen.

                                            Don't forget to upvote 👍 those who kindly offered their time and brainpower to help you!

                                            If you're interested, I'm available to discuss details of German-speaking paid support (for companies) if needed.

                                            D 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.