[arch-general] Generating Arch OpenStack images
Victor Dmitriyev
mrvvitek at gmail.com
Sun Jun 21 10:50:12 UTC 2015
On 21.06.2015 02:25, Sebastian Pipping wrote:
> Hi!
> I registered for a closed beta account at CloudScale [1] a few weeks ago
> and noticed that they offer a number of Linux flavors: Debian, Ubuntu,
> CentOS, .. but no Arch Linux. They use OpenStack with the official
> OpenStack images [2] of Debian, Ubuntu and so on.
>
> It seems there are no official OpenStack images for Arch. There are the
> ec2 images of Uplinklabs [3] but that's all I find on the net.
Arch is highly configurable so it's assumed that you build a system for
your needs by yourself.
> I have been working on a tool called image-bootstrap [4] for a while,
> originally aimed at creating virtual machine images for Debian and
> Ubuntu. Recently, I have added Arch Linux support to image-bootstrap
> (and created an Arch equivalent of Debian's debootstrap [5] called
> "directory-bootstrap" in the process, same code base).
There is pacstrap utility. I think it is official equivalent of
debootstrap AND it is maintained by Arch developers.
> Since today,
> when passing the --openstack option to image-boostrap, it does create
> bootable Arch OpenStack images. But there is something missing.
>
>
> When giving birth to a new virtual machine, an OpenStack image file [6]
> of say 1 GiB size is copied onto a say 50 GiB "disk", some kind of block
> device passed to a hypervisor. The original image was generated
> believing that the given hard disk was say 2 GiB in size, some fixed
> size, not the size that OpenStack is actually launching virtual machines
> with.
> To give access to the full disk space to users, OpenStack images are
> prepared to do the following:
>
> 1. During early boot (initramfs time), the one and only partition is
> enlarged to the full size of the disk.
>
> 2. during normal boot, cloud-init is running resize2fs to enlarge
> the ext4 root file system to the new size of that partition.
>
> It's a little crazy, but it works: the user hardly notices.
>
> In Debian, apart from cloud-init that magic is done by packages
> cloud-utils and cloud-initramfs-growroot of cloud-initramfs-tools [7].
> While Arch does have cloud-init, I find cloud-utils in AUR only and no
> cloud-initramfs-growroot at all.
It seems that cloud-init can perform this task by itself
(https://wiki.archlinux.org/index.php/Cloud-init#Other_sections_in_cloud.cfg).
There is also mkinitcpio-growrootfs
(https://aur.archlinux.org/packages/mkinitcpio-growrootfs/). It's
probably what you were looking for but it looks like package is not
supported by its developer anymore. So you probably shouldn't use this
mkinitcpio hook.
The cloud-utils package right now is in official repositories
(https://www.archlinux.org/packages/community/any/cloud-init/), how you
missed that?
> I am looking for Arch developers to bring these to the Arch master
> repository.
>
>
> There is yet something else: Trust. Anyone can make images and upload
> them but who is going to trust the image if it is not signed by a person
> that they trust?
> There is a group of five people in the Arch master signing keys [8].
> One of them created, signed and uploaded the
> archlinux-bootstrap-*.tar.gz files that users rely on. My hope is that
> one of these five is willing to use image-bootstrap [4] to create, sign
> and upload OpenStack images as well.
archlinux-bootstrap-*.tar.gz files are meant for installation of
Archlinux from a computer running another Linux distribution
(https://wiki.archlinux.org/index.php/Install_from_existing_Linux#Method_B:_Using_the_Bootstrap_Image_.28recommended.29),
so, of course, Arch developers sign this installation medium.
In my opinion, official Arch OpenStack images is pointless because what
point in server image that you need to configure anyway?
>
> Thanks for your attention. Best,
>
>
>
> Sebastian
>
>
> [1] https://www.cloudscale.ch/
> [2] http://docs.openstack.org/image-guide/content/ch_obtaining_images.html
> [3] https://www.uplinklabs.net/projects/arch-linux-on-ec2/
> [4] https://github.com/hartwork/image-bootstrap
> [5] https://wiki.debian.org/Debootstrap
> [6] http://docs.openstack.org/image-guide/content/ch_openstack_images.html
> [7] https://packages.debian.org/source/sid/cloud-initramfs-tools
> [8] https://www.archlinux.org/master-keys/
>
In conclusion, I have an impression that you miss the point of Arch, so
I point you towards the ArchWiki again:
Arch Linux -- https://wiki.archlinux.org/index.php/Arch_Linux
The Arch Way -- https://wiki.archlinux.org/index.php/The_Arch_Way
Installation guide --
https://wiki.archlinux.org/index.php/Installation_guide
cloud-init -- https://wiki.archlinux.org/index.php/Cloud-init
and, in general, the ArchWiki has a lot of useful information.
Regards,
Victor
More information about the arch-general
mailing list