[SOLVED] Cloud-init IP config with IPv6=auto

Loredo

New Member
Feb 21, 2012
27
0
1
Munich
Hi,

it seems that the generated cloud-init.yaml file has an incorrect format for the network configuration if you set IPv6 to SLAAC for an interface.

The resulting file will have "auto/24" as an address which is an incorrect format I believe (a mix of IPv6 "auto" for the address and an IPv4 subnet of /24).

Consequently the cloud-init process is not able to handle the network setup correctly:

"Sterr: Error in network definition //etc/netplan/50-cloud-init.yaml line 10 column 12: malformed address 'auto/24', must be X.X.X.X/NN or X:X:X:X:X:X:X:X/NN"

Eventually I was logging in to the running machine and just removed that line of "- auto/24" from the file. After "netplan apply" the network would just come up as expected incl. IPv6 SLAAC.

Could this be corrected in the Proxmox packages? Thanks.
 

dcsapak

Proxmox Staff Member
Staff member
Feb 1, 2016
8,640
1,126
174
34
Vienna
can you post the complete vm config ? qm config ID
 

Loredo

New Member
Feb 21, 2012
27
0
1
Munich
Code:
agent: 1
boot: c
bootdisk: scsi0
cipassword: **********
cores: 4
cpu: host
ide2: local-zfs:vm-200-cloudinit,media=cdrom,size=5M
ipconfig0: ip=192.168.1.100/24,gw=192.168.1.1,ip6=auto
memory: 4096
name: hostname.domain.tld
net0: virtio=99:BE:6B:01:D3:16,bridge=vmbr0
onboot: 1
ostype: l26
protection: 0
scsi0: local-zfs:base-9000-disk-0/vm-200-disk-0,size=32G
scsihw: virtio-scsi-pci
serial0: socket
smbios1: uuid=bdba4900-bb20-4a6f-a9d9-7fc4235aa5d0
sockets: 1
sshkeys: ##########
vga: serial0
vmgenid: f03e2acc-0a27-40f0-9157-3716307c074a

It would work if I remove "ip6=auto" using the console command:

Code:
qm set 200 --ipconfig0 ip=192.168.1.100/24,gw=192.168.1.1

Obviously the GUI won't let me do that.
 

mira

Proxmox Staff Member
Staff member
Aug 1, 2018
2,109
252
103
If you don't need an IPv6 address just set it to static without any IP or gateway.
 

Loredo

New Member
Feb 21, 2012
27
0
1
Munich
Sadly I do need IPv6 with auto-configuration. Found my workaround as stated above it seems but the GUI support should somewhat be improved as the SLAAC option is quite irritating if it is not needed at all.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!