Shrink whole disk image from 40G to 6G

Now that images are converted to raw on the undercloud we need to
consider the implications of creating a 40G whole-disk image which is
mostly empty.

The raw image file on the undercloud is sparse, so storage space is
not consumed. However transferring from the undercloud to deploying
nodes will transfer all 40G of mostly zeros, and ironic-python-agent
will also write all those zeros to disk during deployment. This makes
deployment unnecessarily slow and will cause network scalabilty issues
for large overcloud deployments.

This change reduces the size of the physical root partition to 6GB,
and makes the logical volumes big enough for space to not run out
during image building. The growvols utility will be used post-deploy
to grow all of the volumes (not just /var).

The growvols playbook now has the following default to ensure all
partitions are grown to an appropriate size:
/=8GB /tmp=1GB /var/log=10GB /var/log/audit=2GB /home=1GB /var=100%

Change-Id: I34b57958ba84714c54ed8148600e7fd0860e3ba8
Blueprint: whole-disk-default
This commit is contained in:
Steve Baker 2021-06-25 17:11:36 +12:00
parent e996653baa
commit 0203c0aa63
1 changed files with 5 additions and 5 deletions

View File

@ -19,7 +19,7 @@
size: 8MiB
- name: root
flags: [ boot ]
size: 40G
size: 6G
- lvm:
name: lvm
base: [ root ]
@ -34,22 +34,22 @@
lvs:
- name: lv_root
base: vg
extents: 23%VG
extents: 69%VG
- name: lv_tmp
base: vg
extents: 4%VG
- name: lv_var
base: vg
extents: 45%VG
extents: 15%VG
- name: lv_log
base: vg
extents: 23%VG
extents: 4%VG
- name: lv_audit
base: vg
extents: 4%VG
- name: lv_home
base: vg
extents: 1%VG
extents: 4%VG
- mkfs:
name: fs_root
base: lv_root