Navigation

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

    Static Dhcp Lease - w/ diferente gw

    DHCP and DNS
    2
    6
    3982
    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.
    • M
      moliterno380 last edited by

      Hi I'm needing too set a diferente gateway for some o the static dhcp leases ,

      I'm able to do it on other bsd and linux editing de dhcpd.conf and putting "option routers xxx.xxx.xxx.xxxx." insite the configuration for the static lease .  I look at the config.xml and triede tu put thr filds there too but it did'nt work out too.

      I used to had this on ipcop box , but pfsense is way better , houw can I make it too work on pfsense ???

      P.s Sorry for the poor english , I'm from brazil .

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

        Stop messing directly with the config files.
        Just configure it in the GUI.

        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
        • M
          moliterno380 last edited by

          I,m using 1.2.2 and tried out 1.2.3 ,  whith the gui on the dhcp i have set the default router "gateway" ,  on the leases page , where i set a static lease for for one specific machine i have on the gui the options for setting the mac , IP , name and description , but no to set a diferente gateway for that lease.

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

            You cannot set a different gateway for a single client.

            But you can set a different gateway for all DHCP clients.

            Subnet
            Subnet mask
            Available range
            Range to
            WINS servers
            DNS servers
            Gateway
            Default lease time    seconds
            Maximum lease time seconds
            Failover peer IP:
            Static ARP
            Dynamic DNS
            NTP servers
            Enable Network booting

            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
            • M
              moliterno380 last edited by

              that i did , for the basic configuration of the cleintes ,  the problem is that i have some fixed dhcp leases that needes a diferente gateway .  on server that i build using config files ( freebsd , linux ) I edit the dhcp.conf , to look like this:

              ddns-update-style none;
              deny bootp;     #default
              authoritative;

              subnet 192.168.100.0 netmask 255.255.255.0
              {
                     range 192.168.100.100 192.168.100.150;
                     option subnet-mask 255.255.255.0;
                     option domain-name "Abracadabra";
                     option routers 192.168.100.253;
                     option domain-name-servers 192.168.100.253;
                     default-lease-time 3600;
                     max-lease-time 7200;
              }

              host fix0 # TI Aba
              {
                     hardware ethernet 00:13:a9:8f:96:e1;
                     fixed-address 192.168.100.22;
                     option routers 192.168.100.250;
                     option domain-name-servers 211.1.186.250;
              }

              host fix1 #
              {
                     hardware ethernet 00:13:20:48:6c:4c;
                     fixed-address 192.168.100.23;
              }

              But as was sad to mee "Stop messing directly with the config files " i stopd traing to do that on the config files . Sinse the web Gui doesnt have a option when i configure a static dhcp lease , I cold get some help using the config files to do that.

              Thanks

              maybe a sugestion for the next version, on the gui having how to set diferentes gw and dns for fixed dhcp leases.

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

                It's not that modifying the configs directly is bad.
                The problem with messing with files directly is, that it's not persistent.
                The next time the rules are reloaded or you reboot all your changes are lost.
                This due to the nature of pfSense of generating all configs dynamically out of the config.xml.

                If you're using a fixed config, you could backup the config file of the DHCP and copy your own file over the dynamically generated config with a cronjob or something like this.

                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
                • First post
                  Last post