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

    Multiple subnets on one interface

    Scheduled Pinned Locked Moved Routing and Multi WAN
    3 Posts 2 Posters 3.1k 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.
    • 7
      73agordon
      last edited by

      I followed a pdf doc I found to add multiple subnets to on interface by inserting the following line in the config file. <shellcmd>ifconfig vr0 inet 192.168.0.1 netmask 255.255.0.0 alias</shellcmd>.

      Inset up the firewall and nat acording to the doc. this allows me to have any ip in the 192.168.x.x subnet but i have to use 192.168.0.1 for a gateway. It would seam with a mask of 255.255.0.0 that any gateway would work. I also tryed 192.168.0.0. no luck.

      My outgoing nat looks like this. 10.0.0.0 is my main ip on interface.

      Interface  Source  Source Port  Destination  Destination Port  NAT Address  NAT Port 
      WAN  10.0.0.0/24 *                 *                   *                    *             *

      WAN  192.168.0.0/16 *                 *                   *                 *             *

      My lan firewall looks like this.
        Proto  Source  Port  Destination  Port  Gateway  Schedule  Description 
                        *     10.0.0.1/24           *                         *               *       *

      *   192.168.0.0/16            *                         *               *       *

      Any ideals?? THanks

      1 Reply Last reply Reply Quote 0
      • GruensFroeschliG
        GruensFroeschli
        last edited by

        What is the problem?
        (Sorry it's not clear out of your description).

        No you cannot use 192.168.0.0 as IP for the pfSense with a netmask of /16 because this is the NetID.

        We do what we must, because we can.

        Asking questions the smart way: http://www.catb.org/esr/faqs/smart-questions.html

        1 Reply Last reply Reply Quote 0
        • 7
          73agordon
          last edited by

          I need to enable a computer to connect to the network with an ip and gateway hardcoded that is out of the subnet set on the nic. I was trying to acomplish this by setting the nic to use multiple subnet, however when I set the subnet of 192.168.0.1/16 I can have any ip in the 192.168.x.x subnet but I  have to use a gateway of 192.168.0.1. If I use lets say 192.168.15.26 with a gateway of 192.168.15.1 it wont work. The main subnet on the nic is 10.0.0.1/24.

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