Skip to content
Snippets Groups Projects
Verified Commit e1314716 authored by anarcat's avatar anarcat
Browse files

move disk partitioning to node installation

That needs to be done everywhere.
parent 3fcf1847
No related branches found
No related tags found
No related merge requests found
......@@ -2640,6 +2640,25 @@ be reclaimed eventually.
cumin -p 0 'C:roles::ganeti::chi' 'puppet agent -t'
10. partition the extra disks:
mdadm --create --verbose --level=10 --metadata=1.2 --raid-devices=6 /dev/md2 /dev/sd[abcdef] &&
cryptsetup luksFormat --key-file=/etc/luks/crypt_dev_md2 /dev/md2 &&
cryptsetup luksOpen --key-file=/etc/luks/crypt_dev_md2 /dev/md2 crypt_dev_md2 &&
pvcreate /dev/mapper/crypt_dev_md2 &&
vgcreate vg_ganeti /dev/mapper/crypt_dev_md2 &&
echo crypt_dev_md2 UUID=$(lsblk -n -o UUID /dev/md2 | head -1) /etc/luks/crypt_dev_md2 luks,discard >> /etc/crypttab &&
update-initramfs -u
Normally, this would have been done in the `setup-storage`
configuration, but we were in a rush.
TODO: `vg_ganeti_nvme` configuration.
11. Reboot to test the LUKS configuration:
reboot
10. Then the node is ready to be added to the cluster, by running
this on the master node:
......@@ -2662,22 +2681,7 @@ the SSH `known_hosts` file, see [SSH key verification failures](#ssh-key-verific
### gnt-dal cluster initialization
This procedure replaces the `gnt-node add` step in the initial setup
of the first Ganeti node when the `gnt-chi` cluster was setup:
First, we need to partition the disks. Normally, this would have been
done in the `setup-storage` configuration, but we were in a rush:
mdadm --create --verbose --level=10 --metadata=1.2 --raid-devices=6 /dev/md2 /dev/sd[abcdef] &&
cryptsetup luksFormat --key-file=/etc/luks/crypt_dev_md2 /dev/md2 &&
cryptsetup luksOpen --key-file=/etc/luks/crypt_dev_md2 /dev/md2 crypt_dev_md2 &&
pvcreate /dev/mapper/crypt_dev_md2 &&
vgcreate vg_ganeti /dev/mapper/crypt_dev_md2 &&
echo crypt_dev_md2 UUID=$(lsblk -n -o UUID /dev/md2 | head -1) /etc/luks/crypt_dev_md2 luks,discard >> /etc/crypttab &&
update-initramfs -u
Reboot to test the LUKS configuration:
reboot
of the first Ganeti node when the `gnt-chi` cluster was setup.
Initialize the ganeti cluster:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment