3 .
/etc
/network.overrides
4 [ "$FAILSAFE" != "true" -a -e /etc
/config
/network
] && .
/etc
/config
/network
6 # interface to use for DHCP
9 ifname
=$
(nvram get
${iface}_ifname
)
10 ipaddr
=$
(nvram get
${iface}_ipaddr
)
11 netmask
=$
(nvram get
${iface}_netmask
)
13 # check for existing DHCP server
14 udhcpc
-n -q -R -s /bin
/true
-i $ifname >&- ||
{
16 ipaddr
=$
(ip2int
$ipaddr)
17 netmask
=$
(ip2int
${netmask:-255.255.255.0})
18 network
=$
((ipaddr
&netmask
))
20 start
=$
(nvram get dhcp_start
)
21 start
=$
((network
+${start:-100}))
22 end
=$
(nvram get dhcp_num
)
23 end
=$
((start
+${end:-150}))
25 wanproto
=$
(nvram get wan_proto
)
26 [ -z "$wanproto" -o "$wanproto" = "none" ] || wanif
=$
(nvram get wan_ifname
)
28 args
="-l /tmp/dhcp.leases -K -F $(int2ip $start),$(int2ip $end),$(int2ip $netmask),12h ${wanif:+-I ${wanif} }"
This page took 0.044759 seconds and 5 git commands to generate.