Static Dhcp Lease - w/ diferente gw
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 .
Stop messing directly with the config files.
Just configure it in the GUI.
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.
You cannot set a different gateway for a single client.
But you can set a different gateway for all DHCP clients.
Default lease time seconds
Maximum lease time seconds
Failover peer IP:
Enable Network booting
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:
deny bootp; #default
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;
host fix0 # TI Aba
hardware ethernet 00:13:a9:8f:96:e1;
option routers 192.168.100.250;
option domain-name-servers 188.8.131.52;
host fix1 #
hardware ethernet 00:13:20:48:6c:4c;
But as was sad to mee "Stop messing directly with the config files " i stop
d 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.
maybe a sugestion for the next version, on the gui having how to set diferentes gw and dns for fixed dhcp leases.
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.