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

Wolfgang Bumiller w.bumiller at proxmox.com
Thu Jun 11 10:24:38 CEST 2015


There are a few things that still confuse me about cloud-init, and the
documentation lacks a description of the very basic mode of operation of
cloud-init. (When does which part start and where does it do what
exactly. The source isn't easy to navigate either without more
documentation... (it's a big load of python))

For one, it seems to be started on several points during the init
process. There seem to be 5 different systemd units specified for it
even.
Then there seems to be a system-wide configuration in /etc/cloud that
defines not just datasources but also default configurations, like a
default user, and whether root may login with a password, etc. At this
point I'm wondering whether this configuration will be re-applied on
every boot. (The documentation doesn't mention any of this actually, I
found this part on the ArchWiki[1]...)

The documentation only mentions a directory structure in /var. [2]

Now I'm left to wonder... does the cloud init process somehow
overwride/interfere with the regular initialization process? Does it
actually perform physical merging of configuration files from the
datasource into /var? (The documentation also mentions merging[3])

And does that mean cloud-init keeps overwriting the systems's regular
configuration files?

To me the entire thing still seems a bit cloudy. (no pun intended...)

Finally: OS support. It seems to only ship with support linux (few 
specific distros even) and freebsd [4]. For that purpose it seems a
little overengineered.

[1] https://wiki.archlinux.org/index.php/Cloud-init
[2] https://cloudinit.readthedocs.org/en/latest/topics/dir_layout.html
[3] https://cloudinit.readthedocs.org/en/latest/topics/merging.html
[4] https://cloudinit.readthedocs.org/en/latest/topics/availability.html

On Thu, Jun 11, 2015 at 08:11:45AM +0200, Alexandre DERUMIER wrote:
> Also, 
> 
> cloud-init feature is only usefull when creating a new vm,
> 
> so cloning a clean template with cloud-init support.
> 
> 
> Maybe we could simply pass options to qm clone .... -nameserver -searchdoman -eth0 ipaddress gateway ....
> 
> start the vm after cloning, and cloud-init shutdown it when finished.
> 
> 
> 
> (We could also add some kind of import template like for container, they are a lot of cloud-init templates available on the net)
> 
> 
> ----- Mail original -----
> De: "aderumier" <aderumier at odiso.com>
> À: "dietmar" <dietmar at proxmox.com>
> Cc: "pve-devel" <pve-devel at pve.proxmox.com>
> Envoyé: Jeudi 11 Juin 2015 07:54:06
> Objet: Re: [pve-devel] RFC: qemu-server : add cloudinit support
> 
> >>And is that reboot necessary? Its a bit clumsy, because the boot-loader 
> >>is presented 2 times to the user. 
> 
> I forgot to say that I shutdown the vm (with cloudinit) at the end of the setup, not reboot. 
> That's why I setup in pending removal ide3. 
> 
> 
> 
> ----- Mail original ----- 
> De: "aderumier" <aderumier at odiso.com> 
> À: "dietmar" <dietmar at proxmox.com> 
> Cc: "pve-devel" <pve-devel at pve.proxmox.com> 
> Envoyé: Jeudi 11 Juin 2015 07:17:33 
> Objet: Re: [pve-devel] RFC: qemu-server : add cloudinit support 
> 
> >>And is that reboot necessary? Its a bit clumsy, because the boot-loader 
> >>is presented 2 times to the user. 
> 
> No, but I just want to clean remove the cdrom config. 
> I setup it as ide3. (in case if use have already a cdrom is default ide2). 
> 
> 
> It could be possible to eject cd from guest in cloudinit config, but currently we can't catch qemu events. 
> 
> 
> ----- Mail original ----- 
> De: "dietmar" <dietmar at proxmox.com> 
> À: "aderumier" <aderumier at odiso.com> 
> Cc: "pve-devel" <pve-devel at pve.proxmox.com> 
> Envoyé: Jeudi 11 Juin 2015 07:13:53 
> Objet: Re: [pve-devel] RFC: qemu-server : add cloudinit support 
> 
> > >>How long does such configuration cycle run (start/cloudinit/stop)? 
> > 
> > It's fast, maybe <15s after grub for basic network config. 
> > But for example if you want to upgrade packages at first boot or launch 
> > puppet/chef, 
> > it can take a lot more. 
> 
> And is that reboot necessary? Its a bit clumsy, because the boot-loader 
> is presented 2 times to the user. 




More information about the pve-devel mailing list