From 1a227126a525baec2030ec9cfc9cd8a503ba6c7a Mon Sep 17 00:00:00 2001 From: Darren 'Tadgy' Austin Date: Wed, 6 Nov 2019 18:19:44 +0000 Subject: Remove IP6ALIASES block. IP6ADDR->IP6ADDRS. --- rc.inet1 | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/rc.inet1 b/rc.inet1 index ae9280b..691db79 100644 --- a/rc.inet1 +++ b/rc.inet1 @@ -172,7 +172,7 @@ if_up() { # If the interface is a bridge, then create it first: [ -n "${BRNICS[$i]}" ] && br_open $i # Skip unconfigured interfaces: - if [ -z "${IPADDR[$i]}" ] && [ "${USE_DHCP[$i]}" != "yes" ] && [ -z "${IP6ADDR[$i]}" ] && \ + if [ -z "${IPADDR[$i]}" ] && [ "${USE_DHCP[$i]}" != "yes" ] && [ -z "${IP6ADDRS[$i]}" ] && \ [ "${USE_DHCP6[$i]}" != "yes" ] && [ "${USE_SLAAC[$i]}" != "yes" ]; then debug_log "skipping ${1} early, interface is not configured in /etc/rc.d/rc.inet1.conf" return @@ -327,22 +327,6 @@ if_up() { fi done fi - if [ -e /proc/sys/net/ipv6 ] && [ -n "${IP6ALIASES[$i]}" ]; then - # IPv6's Duplicate Address Detection (DAD) causes a race condition when bringing up interfaces, as - # described here: https://www.agwa.name/blog/post/beware_the_ipv6_dad_race_condition - # Disable DAD while bringing up the interface - but note that this means the loss of detection of a - # duplicate address. It's a trade off, unfortunately. - echo "0" >/proc/sys/net/ipv6/conf/$1/accept_dad - for ipalias in ${IP6ALIASES[$i]}; do - ip="${ipalias%/*}" - nm="${ipalias#*/}" - [ -z "$nm" ] || [ "$ip" == "$nm" ] && nm="64" - # Unlike IPv4, v6 addresses don't get a label: - echo "/etc/rc.d/rc.inet1: /sbin/ip -6 address add ${ip}/${nm} dev ${1}" | $LOGGER - /sbin/ip -6 address add ${ip}/${nm} dev ${1} || \ - echo "/etc/rc.d/rc.inet1: failed to add IP ${ip} to ${1}" | $LOGGER - done - fi # Force an MTU (possibly over-riding that set by DHCP or RA): if [ -n "${MTU[$i]}" ]; then echo "/etc/rc.d/rc.inet1: /sbin/ip link set dev ${1} mtu ${MTU[$i]}" | $LOGGER -- cgit v1.2.3