[pve-devel] RFC: qemu-server : add cloudinit support

Dietmar Maurer dietmar at proxmox.com
Mon Jun 15 16:55:57 CEST 2015

> Here's the current data I gathered:
> -) From the UI perspective, the IP address configuration for cloud-init
> could be done in the network device's configuration.
> -) AFAIK there are ebtable patches to do filtering by mac address around
> which are still pending.

re-thought this, and I think this is an unrelated feature. But we also want
to integrate this in new 4.0 release.

> -) Similar to the MAC firewall rules the host can then activate IP
> firewall rules for the guest system when the VM is booted with
> cloud-init support.

We already have special 'ipfilter' ipsets:


So we can just add those IPs to the 'ipfilter' ipset (automatically).

> -) We don't really like the whole "rebooting after configuration"
> option. It could be an optional flag, but ideally the user only needs to
> boot once, and since the IP options are always available in the GUI it
> also wouldn't be harmful to always include the cloud-init drive. This
> also improves compatibility to "default installations" of cloud init
> (like on ubuntu where it otherwise by default tries to connect to a
> magic IP.).

Yes, we need a way to configure some behavioral cloud-init option, 
for example:

cloudinit: mode=[never|always|once],template=/etc/pve/cloudinit/test

> -) From the CLI and configuration side: cloning would need an option to
> change the IP by network-interface.

yes, but this looks challenging to me - it will be difficult to provide
a nice GUI for that.

> -) For migration support: if we by default keep the config drives around
> they need to be stored somewhere on a shared storage. So we need an
> option to configure which storage the ISOs end up on. Then they'd appear
> in the template/iso/ directory of the configured storage, which has to be a
> shared one if you want to be able to migrate. The images are tiny anyawy
> (more filesystem overhead than actual data when they only contain
> network configuration.)
> -) Instance ID: VMs need a counter which is bumped at boot time when
> there have been changes since the previous boot (or just bump on every
> change, that's easier to implement :P). Cloning needs to reset or bump
> the counter as well. (Reset if the source's counter is > 1, or bump to 2
> if it's still 1 etc.)

Can't we simply generate a digest including all cloudinit configuration values?

More information about the pve-devel mailing list