[pve-devel] applied: [PATCH container] fix #2027: do not disable IPV6_AUTOCONF on centos

Wolfgang Bumiller w.bumiller at proxmox.com
Thu May 9 14:19:21 CEST 2019


applied

On Thu, May 09, 2019 at 01:57:29PM +0200, Oguz Bektas wrote:
> we used to disable IPV6_AUTOCONF when the DHCP option was chosen for the
> container network (was only activated with SLAAC option).
> 
> however, this option is actually dependent on IPV6FORWARDING (which is
> set to no by default), according to this rule:
> 
> IPV6_AUTOCONF=!IPV6FORWARDING
> 
> which enables it automatically when forwarding is disabled. this way, we
> respect the defaults set by centos.
> 
> Signed-off-by: Oguz Bektas <o.bektas at proxmox.com>
> ---
> 
> i included the test script edits in this commit, since they are
> required for compiling after we do the change in CentOS.pm
> 
>  src/PVE/LXC/Setup/CentOS.pm                                            | 2 --
>  src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth0.exp | 1 -
>  src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth1.exp | 1 -
>  3 files changed, 4 deletions(-)
> 
> diff --git a/src/PVE/LXC/Setup/CentOS.pm b/src/PVE/LXC/Setup/CentOS.pm
> index 2b7f90c..84bde5c 100644
> --- a/src/PVE/LXC/Setup/CentOS.pm
> +++ b/src/PVE/LXC/Setup/CentOS.pm
> @@ -206,8 +206,6 @@ sub setup_network {
>  	    $data .= "IPV6INIT=yes\n";
>  	    if ($d->{ip6} eq 'auto') {
>  		$data .= "IPV6_AUTOCONF=yes\n";
> -	    } else {
> -		$data .= "IPV6_AUTOCONF=no\n";
>  	    }
>  	    if ($d->{ip6} eq 'dhcp') {
>  		$data .= "DHCPV6C=yes\n";
> diff --git a/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth0.exp b/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth0.exp
> index a6cc799..6f04e03 100644
> --- a/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth0.exp
> +++ b/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth0.exp
> @@ -5,5 +5,4 @@ IPADDR=1.2.3.4
>  NETMASK=255.255.255.0
>  GATEWAY=4.3.2.1
>  IPV6INIT=yes
> -IPV6_AUTOCONF=no
>  IPV6ADDR=2000::1/64
> diff --git a/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth1.exp b/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth1.exp
> index 6b92947..a97b78b 100644
> --- a/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth1.exp
> +++ b/src/test/test-centos6-002/etc/sysconfig/network-scripts/ifcfg-eth1.exp
> @@ -2,6 +2,5 @@ DEVICE=eth1
>  ONBOOT=yes
>  BOOTPROTO=none
>  IPV6INIT=yes
> -IPV6_AUTOCONF=no
>  IPV6ADDR=2222::1/64
>  IPV6_DEFAULTGW=fe80::1
> -- 
> 2.11.0




More information about the pve-devel mailing list