Doc. # 1-00000961 | |||
---|---|---|---|
Date Updated | 10-26-2018 | Date Created | 09-12-2017 |
Document Type | Knowledge Base | Related OS | |
Related Product | ERT310/ ERT312/ RT3G-300/ RT3G-300-W/ RT3G-302/ RT3G-304/ RT3G-310/ RT3G-310-W/ RT3G-311/ RT3G-320-W/ RT3G-322/ RT3G-324/ RT3G-330/ RT3G-340-W/ RTLTE-300-VZ/ RTLTE-302-VZ/ RTLTE-304-VZ/ RTLTE-311-VZ |
How do you change DHCP Server of Spectre router to hand out a different Gateway and DNS Server? | |||
---|---|---|---|
Solution:
The DHCP server configuration file is created dynamical. To do this you can use your own DHCP server. You will need to turn DHCP server off on web coniguration (Enable dynamic DHCP leases) on LAN configuration and then you can use Startup Script for your DHCP server. See below for example of what can be used in Startup Script. #!/bin/sh## This script will be executed *after* all the other init scripts.# You can put your own initialization stuff in here. [ -h /usr/sbin/dhcp2d ] || ln -s /usr/sbin/dhcpd /usr/sbin/dhcp2d cat > /var/dhcp/dhcp2d.conf << EOFoption routers 192.168.1.1;option domain-name-servers 8.8.8.8, 1.2.3.4, 11.12.13.14, 192.168.2.1;default-lease-time 600;max-lease-time 86400;subnet 192.168.1.0 netmask 255.255.255.0 { range 192.168.1.2 192.168.1.254; }EOF touch /var/dhcp/dhcp2d.leases /usr/sbin/dhcp2d -q -cf /var/dhcp/dhcp2d.conf -lf /var/dhcp/dhcp2d.leases -pf /var/dhcp/dhcp2d.pid eth0 2> /dev/null &
|