diff options
| author | 2026-01-21 15:40:02 -0800 | |
|---|---|---|
| committer | 2026-01-22 12:03:05 -0800 | |
| commit | bb62046d42c91f206dc03154587053c7f9c487aa (patch) | |
| tree | e96d0fa42dbf7d56b7a3fcacd57e855d6ed3098a | |
| parent | 89f990af38ec8a498352a5bda155f33be016248c (diff) | |
| download | kiwi-descriptions-bb62046d42c91f206dc03154587053c7f9c487aa.tar.gz kiwi-descriptions-bb62046d42c91f206dc03154587053c7f9c487aa.zip | |
Configure Azure DHCP to retry indefinitely
Azure requires VMs to attempt DHCP for at least 300 seconds during
provisioning. Setting ipv4.dhcp-timeout and ipv6.dhcp-timeout to
2147483647 (NetworkManager's value for infinity) allows indefinite
retries, which is robust than fixed timeout value. Both IPv4 and IPv6
are configured to prepare for IPv6-only scenarios.
Signed-off-by: Bala Konda Reddy M <bala12352@gmail.com>
| -rwxr-xr-x | config.sh | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -180,6 +180,20 @@ cat > /etc/NetworkManager/conf.d/99-azure-unmanaged-devices.conf << EOF [keyfile] unmanaged-devices=driver:mlx4_core;driver:mlx5_core EOF + +# Configure DHCP timeout for Azure to retry indefinitely during VM provisioning +cat > /etc/NetworkManager/conf.d/99-azure-dhcp-timeout.conf << EOF +# Azure requires VMs to attempt DHCP for at least 300 seconds during provisioning, +# as that's the upper bound of how long Azure waits to make networking available. +# NetworkManager's ipv4.dhcp-timeout setting accepts 2147483647 as a special value +# representing infinity, which ensures DHCP keeps retrying indefinitely. This is +# more robust than a fixed timeout and matches systemd-networkd's default behavior. +# Both IPv4 and IPv6 are configured to prepare for IPv6-only scenarios. +# Reference: https://networkmanager.dev/docs/api/latest/nm-settings-nmcli.html +[connection] +ipv4.dhcp-timeout=2147483647 +ipv6.dhcp-timeout=2147483647 +EOF fi if [[ "$kiwi_profiles" == *"GCE"* ]]; then |