Hide Forgot
Created attachment 1605727 [details] Reproduce script. Description of problem: Cannot switch ipv6.method from ignore to ipv6.method manual with gateway Version-Release number of selected component (if applicable): NetworkManager-1.20.0-1.el8.x86_64 How reproducible: 100% Steps to Reproduce: 1. sudo ./ipv6_bug.sh 2. 3. Actual results: Error: Connection activation failed: IP configuration could not be reserved (no available address, timeout, etc.) Hint: use 'journalctl -xe NM_CONNECTION=6850b6a2-e8d0-4a02-aa37-76818b4d7636 + NM_DEVICE=dhcpcli' to get more details. Expected results: No failure. Additional info: If I remove the `ipv6.gateway 2001:db8:1::`, it works well.
Created attachment 1605728 [details] System logs with NM trace enabled
The route can't be added because gateway address 2001:db8:1:: is already assigned to interface dhcpsrv, and kernel complains with: platform-linux: netlink: recvmsg: error message from kernel: Invalid argument (22) "Gateway can not be a local address" for request 50 You should put the two dhcp* interfaces in different namespaces to reproduce a valid scenario, or use a different gateway address.
For example, I use a script like this to test DHCPv4 and IPv6 autoconf locally without conflicts between the two veth interfaces: #!/bin/sh ip link add veth0 type veth peer name veth1 ip netns add ns1 ip link set veth1 netns ns1 ip link set veth0 up ip -n ns1 link set veth1 up ip -n ns1 address add dev veth1 172.25.1.1/24 ip -n ns1 address add dev veth1 fd01::1/64 ip netns exec ns1 dnsmasq --bind-interfaces --interface veth1 -d --dhcp-range=172.25.1.100,172.25.1.200,1m --dhcp-range=fd01::100,fd01::200,slaac --enable-ra -h
Hi Beniamino Galvani, Thanks. Changing the gateway address fixed the problem.