103cccd786
Allocating of space on the root disk was done in kickstart, combined with config_controller. Various checks for disk and volume group space made it difficult to add new filesystem partitions. To simplify this, all checks are now merged under disk size checks. Kickstart files now create the partitions of the same size for rootfs and log partitions, no matter the disk size, with the only variable size being the cgts-vg size. Thus, any future changes will only need to consider only this size for ensuring enough space is present. The limit between small and big disks is 240GB, with a minimum disk size of 120GB. Depends-On: https://review.openstack.org/#/c/600743/ Change-Id: I37ecc8eb5468811d1ca3a71f8e2a0629525e8fad Closes-bug: 1791170 Signed-off-by: Stefan Dinescu <stefan.dinescu@windriver.com>
28 lines
1.0 KiB
INI
Executable File
28 lines
1.0 KiB
INI
Executable File
|
|
## NOTE: updates to partition sizes need to be also reflected in
|
|
## _controller_filesystem_limits() in sysinv/api/controllers/v1/istorconfig.py
|
|
|
|
ROOTFS_SIZE=20000
|
|
LOG_VOL_SIZE=8000
|
|
SCRATCH_VOL_SIZE=8000
|
|
|
|
ROOTFS_OPTIONS="defaults"
|
|
profile_mode=`cat /proc/cmdline |xargs -n1 echo |grep security_profile= | grep extended`
|
|
if [ -n "$profile_mode" ]; then
|
|
# Enable iversion labelling for rootfs when IMA is enabled
|
|
ROOTFS_OPTIONS="${ROOTFS_OPTIONS},iversion"
|
|
fi
|
|
|
|
cat<<EOF>>/tmp/part-include
|
|
part /boot --fstype=ext4 --asprimary --size=500 --ondrive=$(get_disk $rootfs_device) --fsoptions="$ROOTFS_OPTIONS"
|
|
part pv.253004 --grow --asprimary --size=500 --ondrive=$(get_disk $rootfs_device)
|
|
volgroup cgts-vg --pesize=32768 pv.253004
|
|
logvol /var/log --fstype=ext4 --vgname=cgts-vg --size=$LOG_VOL_SIZE --name=log-lv
|
|
logvol /scratch --fstype=ext4 --vgname=cgts-vg --size=$SCRATCH_VOL_SIZE --name=scratch-lv
|
|
part / --fstype=ext4 --asprimary --size=$ROOTFS_SIZE --ondrive=$(get_disk $rootfs_device) --fsoptions="$ROOTFS_OPTIONS"
|
|
|
|
EOF
|
|
|
|
%end
|
|
|