Debian: correct kickstart.cfg for IPv6 networks

This correction:
1) removes the localhost addresses from the loopback
config file. Localhost addresses are automatically set by linux
in the loopback interface.
2) corrected the post-up operation for "$mgmt_dev" and
"vlan$mgmt_vlan" devices
3) set the correct client identifier for DHCP

Test Plan
[PASS] Install AIO-DX on IPv6 network, it is correctly
       setting the mgmt ip address after first boot on controller-1

Story: 2009968
Task: 46182

Signed-off-by: Andre Fernando Zanella Kantek <AndreFernandoZanella.Kantek@windriver.com>
Change-Id: I0e50e0c85c69ff3a4b7dc1ed4d13e17f750d70d0
This commit is contained in:
Andre Fernando Zanella Kantek 2022-09-01 11:10:18 -03:00
parent 5d6c41c737
commit 7d64e355df
1 changed files with 6 additions and 6 deletions

View File

@ -2023,29 +2023,29 @@ else
# Build networking scripts
cat << EOF > ${IMAGE_ROOTFS}/etc/network/interfaces.d/ifcfg-lo
auto lo
iface lo $mgmt_address_family static
address 127.0.0.1
netmask 255.0.0.0
post-up echo 0 > /proc/sys/net/ipv6/conf/lo/autoconf; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_ra; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_redirects
iface lo $mgmt_address_family loopback
EOF
cat << EOF > ${IMAGE_ROOTFS}/etc/network/interfaces.d/ifcfg-$mgmt_dev
auto $mgmt_dev
iface $mgmt_dev $mgmt_address_family manual
post-up echo 0 > /proc/sys/net/ipv6/conf/lo/autoconf; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_ra; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_redirects
post-up echo 0 > /proc/sys/net/ipv6/conf/$mgmt_dev/autoconf; echo 0 > /proc/sys/net/ipv6/conf/$mgmt_dev/accept_ra; echo 0 > /proc/sys/net/ipv6/conf/$mgmt_dev/accept_redirects
EOF
cat << EOF > ${IMAGE_ROOTFS}/etc/network/interfaces.d/ifcfg-vlan$mgmt_vlan
auto vlan$mgmt_vlan
iface vlan$mgmt_vlan $mgmt_address_family dhcp
vlan-raw-device $mgmt_dev
post-up echo 0 > /proc/sys/net/ipv6/conf/lo/autoconf; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_ra; echo 0 > /proc/sys/net/ipv6/conf/lo/accept_redirects
post-up echo 0 > /proc/sys/net/ipv6/conf/vlan$mgmt_vlan/autoconf; echo 0 > /proc/sys/net/ipv6/conf/vlan$mgmt_vlan/accept_ra; echo 0 > /proc/sys/net/ipv6/conf/vlan$mgmt_vlan/accept_redirects
EOF
# Reject DHCPOFFER from DHCP server that doesn't send
# wrs-install-uuid option
echo "require wrs-install-uuid;" >>/etc/dhcp/dhclient.conf
echo "require dhcp6.wrs-install-uuid;" >>/etc/dhcp/dhclient.conf
# set the same DUID-LL IDs (see RFC 8415) that will be used during regular operations
echo "send dhcp6.client-id = concat(00:03:00, hardware);" >>/etc/dhcp/dhclient.conf
echo "send dhcp-client-identifier = concat(00:03:00, hardware);" >>/etc/dhcp/dhclient.conf
# Bring up the mgmt vlan so that a dhcp lease is acquired and an address is
# setup prior to the post-install reboot. This is so that the timing of the IP