25: Configuring DHCP forwarding
_______________________________________________________________________________________________________
_______________________________________________________________________________________________________
© Virtual Access 2018
GW2020 Series User Manual
Issue: 2.1
Page 248 of 423
Web Field/UCI/Package Option
Description
Web: Enabled
UCI: dhcp_fwd.main.enabled
Opt: enabled
Defines whether DHCP forwarding is enabled or disabled.
0
Do not send router solicitations.
1
Send router solicitations.
Web: Interfaces
UCI: dhcp_fwd.main.listen_interface
Opt: list listen_interface
Defines a list of the source interface name(s) to forward DHCP
messages from. Multiple interface_name(s) are entered using
uci set
and
uci add_list
commands. Example:
uci set dhcp_fwd.main.listen_interface=LAN1
uci add_list dhcp_fwd.main.listen_interface=LAN2
or using a list of options via package options
list listen_interface ‘LAN1’
list listen_interface ‘LAN2’
Web: DHCP Servers
UCI: dhcp_fwd.main.server
Opt: list server
Defines a list of the network DHCP servers to forward DHCP
messages to. Multiple interface_name(s) are entered using
uci
set
and
uci add_list
commands. Example:
uci set dhcp_fwd.main.server=1.1.1.1
uci add_list dhcp_fwd.main.main.server=2.2.2.2
or using a list of options via package options
list server ‘1.1.1.1’
list server ‘2.2.2.2’
Table 77: Information table for the DHCP forwarder section
25.3
Configuring DHCP forwarding using command line
The configuration files for DHCP client are stored in /etc/config/dhcp_fwd
25.3.1
DHCP forwarding using UCI
root@VA_router:~# uci show dhcp_fwd
dhcp_fwd.main=dhcpfwd
dhcp_fwd.main.enabled=1
dhcp_fwd.main.listen_interface=LAN3 lan2
dhcp_fwd.main.server=1.1.1.1
25.3.2
DHCP forwarding using package options
root@VA_router:~# uci export dhcp_fwd
package dhcp_fwd
config dhcpfwd 'main'
option enabled '1'
list listen_interface 'LAN3'
list listen_interface 'lan2'
list server '1.1.1.1'