Cloud-init issues on static ip

I’ve been running into an issue with generic cloud images and static IP assignment with cloud-init, specifically on the AlmaLinux 10 release, and I’m hoping someone here might have some insight, as i’m stuck on it for some time.

My environment is Proxmox VE 9.1.2.

AlmaLinux 9 cloud templates as well as other OS’s work without any problems, but Alma 10 seems behaves differently.

The setup is as follows:

  • VM created from the AlmaLinux 10 generic cloud QCOW2 image
  • Cloud-init disk assigned with static ip configuration

When the VM first boots, the static IP is applied correctly and network connectivity works as expected. However, after some time, the network interface loses its IP address, and I start seeing the following log messages:

Dec 19 12:45:31 alma-10 systemd[1]: Starting NetworkManager-dispatcher.service - Network Manager Script Dispatcher Service...
Dec 19 12:45:31 alma-10 systemd[1]: Started NetworkManager-dispatcher.service - Network Manager Script Dispatcher Service.
Dec 19 12:45:32 alma-10 NetworkManager[767]: <info>  [1766148332.1590] device (eth0): state change: ip-config -> failed (reason 'ip-config-unavailable', managed-type: 'full')
Dec 19 12:45:32 alma-10 NetworkManager[767]: <info>  [1766148332.1595] manager: NetworkManager state is now DISCONNECTED
Dec 19 12:45:32 alma-10 NetworkManager[767]: <warn>  [1766148332.1597] device (eth0): Activation: failed for connection 'cloud-init eth0'
Dec 19 12:45:32 alma-10 NetworkManager[767]: <info>  [1766148332.1603] device (eth0): state change: failed -> disconnected (reason 'none', managed-type: 'full')
Dec 19 12:45:32 alma-10 NetworkManager[767]: <info>  [1766148332.1818] policy: set-hostname: set hostname to 'localhost.localdomain' (no hostname found)

Cloud-init config:

# qm cloudinit dump 8004 network
version: 1
config:
    - type: physical
      name: eth0
      mac_address: 'bc:24:11:78:4b:86'
      subnets:
      - type: static
        address: '192.168.89.11'
        netmask: '255.255.254.0'
        gateway: '192.168.88.1'
      - type: ipv6_slaac

I have tried to use both v1 and v2 as cloud-images, but issue persists.

Any help is appreciated!

Hello

Looking at the logs, the following appears:

[1766148332.1590] device (eth0): state change: ip-config → failed (reason ‘ip-config-unavailable’, managed-type: ‘full’)
[1766148332.1603] device (eth0): state change: failed → disconnected (reason ‘none’, managed-type: ‘full’)

Could this be because Cloud-init specifies IPv4 but uses SLAAC for IPv6?
Try removing the following and see if that resolves it.

  • type: ipv6_slaac

Translated with DeepL.com (free version)

1 Like

Hello,

Setting IPv6 to DHCP or SLAAC seems to be the problem, although SLAAC works with Alma 9 template. Unfortunately I lack expertise to troubleshoot if it’s my network issue.

Setting IPv6 to static resolved the issue. Thank you very much!!

1 Like