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

Assigning Interface as a gateway

Scheduled Pinned Locked Moved DHCP and DNS
11 Posts 3 Posters 653 Views
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.
  • I
    ivanjrx
    last edited by Jun 11, 2023, 10:35 PM

    Hellow Folks,

    Here's a little context:
    1 - Wan
    2 - Lan
    3 - OPT (This is what I'm trying to setup):
    I have Network that is running its own Internal DHCP Windows Server, I just need to setup a Gateway for it, so It can get access to the internet.

    Another words, ie:
    IPv4 Address: 10.27.27.2
    Subnet Mask: 255.255.255.0
    Default Gateway: 10.27.27.1 (This is what I need to setup using pfsense and that Interface )

    Any thoughts?

    J 1 Reply Last reply Jun 11, 2023, 10:39 PM Reply Quote 0
    • J
      johnpoz LAYER 8 Global Moderator @ivanjrx
      last edited by johnpoz Jun 11, 2023, 10:40 PM Jun 11, 2023, 10:39 PM

      @ivanjrx said in Assigning Interface as a gateway:

      Default Gateway: 10.27.27.1 (This is what I need to setup using pfsense and that Interface )

      If you want the gateway for this network to be pfsense, and you want it to be 10.27.27.1/24 - then set that IP on the opt interface, do not enable dhcp on pfsense for this network..

      Create the firewall rules you want that will allow traffic you want to allow.. When you add an interface it will not have any firewall rules like lan does. So you can create a any any rule like on lan net for this opt net.. Or whatever other rules you want to use.

      That is really all there is to it..

      Set whatever dhcp your running on this network to point to pfsense IP as the router/gateway - I assume the 10.27.27.1 your going to assign to the pfsense opt interface.

      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.8, 24.11

      I 1 Reply Last reply Jun 11, 2023, 10:45 PM Reply Quote 1
      • I
        ivanjrx @johnpoz
        last edited by Jun 11, 2023, 10:45 PM

        @johnpoz
        something like this
        alt text

        Plus allowing the firewall?

        S J 2 Replies Last reply Jun 12, 2023, 1:44 AM Reply Quote 0
        • S
          SteveITS Galactic Empire @ivanjrx
          last edited by Jun 12, 2023, 1:44 AM

          @ivanjrx OPT is an internal interface correct? Then yes. Add rules to allow OPT net to pfSense for DNS, and to any for internet. Block from OPT net to LAN net if desired.(above the allow to any rule)

          Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
          When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
          Upvote 👍 helpful posts!

          1 Reply Last reply Reply Quote 1
          • J
            johnpoz LAYER 8 Global Moderator @ivanjrx
            last edited by Jun 12, 2023, 1:54 AM

            @ivanjrx yeah that would be how you would set the IP on the interface - also make sure nothing else on the network is using that 10.27.27.1 address.

            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.8, 24.11

            I 1 Reply Last reply Jun 13, 2023, 3:56 AM Reply Quote 1
            • I
              ivanjrx @johnpoz
              last edited by Jun 13, 2023, 3:56 AM

              @johnpoz
              This is wonderful you guys! 🙂

              I have two more questions.
              1 - How come when I was setting up the Static IPv4 on the interface, why does it have to be /24 and not /32 ? (i noticed when i set it up on /32 there was not internet)

              2 - I have a question about firewall on the same configuration, so it can talk to another subnet on the same pfsense , do I post it here or do i need to add it in another branch of this forum like Firewalling

              S 1 Reply Last reply Jun 13, 2023, 4:42 AM Reply Quote 0
              • S
                SteveITS Galactic Empire @ivanjrx
                last edited by Jun 13, 2023, 4:42 AM

                @ivanjrx the subnet mask affects what other IPs are considered in the same network.
                https://www.iplocation.net/subnet-mask
                A /32 is only one IP.

                Re inter interface communication, as noted above, Add rules to allow OPT net to pfSense for DNS, and to any for internet. Block from OPT net to LAN net if desired.(above the allow to any rule). By default on pfSense only LAN has an allow rule hence all traffic is blocked by default on other interfaces.

                Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                Upvote 👍 helpful posts!

                I 1 Reply Last reply Jun 13, 2023, 5:02 AM Reply Quote 0
                • I
                  ivanjrx @SteveITS
                  last edited by Jun 13, 2023, 5:02 AM

                  @SteveITS
                  so how do I do for the rule for DNS?

                  and how do I add that rule to accept traffic from and back to per say LAN?

                  S 1 Reply Last reply Jun 13, 2023, 1:31 PM Reply Quote 0
                  • S
                    SteveITS Galactic Empire @ivanjrx
                    last edited by Jun 13, 2023, 1:31 PM

                    @ivanjrx is there any network to which you do not want OPT to connect?

                    Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                    When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                    Upvote 👍 helpful posts!

                    I 1 Reply Last reply Jun 14, 2023, 3:03 AM Reply Quote 1
                    • I
                      ivanjrx @SteveITS
                      last edited by Jun 14, 2023, 3:03 AM

                      @SteveITS Thank you for your response.
                      the gateway part is done 🙂 I feel like the scope of this thread was fixed.
                      I'll ad the fw question to the firewalling section.

                      Thank you @johnpoz as well

                      I 1 Reply Last reply Jun 15, 2023, 5:12 AM Reply Quote 0
                      • I
                        ivanjrx @ivanjrx
                        last edited by Jun 15, 2023, 5:12 AM

                        @ivanjrx Moderators can change the status for solved

                        1 Reply Last reply Reply Quote 0
                        1 out of 11
                        • First post
                          1/11
                          Last post
                        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                          This community forum collects and processes your personal information.
                          consent.not_received