We are booting instances outside of rax and they don't always come with
extra devices that can be repurposed for swap. If in that case then
create a swapfile instead.
Note we do not use fallocate as swapon's manpage says this is suboptimal
with the linux kernel's swap implementation.
We want to launch a new bastion host to run ansible on. Because we're
working on the transition to ansible, it seems like being able to do
that without needing puppet would be nice. This gets user management,
base repo setup and whatnot installed. It doesn't remove them from the
existing puppet, nor does it change the way we're calling anything that
Add bridge.openstack.org to the disabled group so that we don't try to
run puppet on it.
When we create the ext4 filesystem on the ephemeral device presented to
rax nodes do so with roughly twice the number of inodes as the default
ext4 bytes to inodes ratio.
We do this because we have found that we have in multiple cases needed
more inodes and that is difficult to deal with after the fact. This may
create more inodes than necessary in other cases but the cost is
relatively low (just more disk used).
Rackspace is now providing a partition table on /dev/xvde1, so check
to see if a filesystem exists, and if now, delete it and rebuild.
Import our logic from devstack-gate role to fix swap issues too.
Signed-off-by: Paul Belanger <email@example.com>
Now that we have a shade version of the launch node script adding in
support for attaching a cinder volume is simple. Do this so that
launching mirrors which rely on cinder volumes is simpler.
This updates the mount_volume.sh script to setup the first cinder volume
with lvm and mount it under the specified path. It will also install
lvm2 pacakges since they may not be present on all base images.
This updates the make_swap.sh script to avoid blindly using /dev/vdb as
the location for swap as this may be a cinder volume or config drive.
We add availability zone, device specification, mount path, and
fs label support to shade-launch-node.py as these are all necessary
inputs to properly mount a cinder volume in a VM.
Add a script to handle cloud servers with no swap. This can be
used before install_puppet when developers run it by hand, and
is called directly by launch_node. If the host has
no swap, create a swap partition from the ephemeral disk and use
the remainder on /opt.