Increase the memory limit for qemu-img

We appear to be bumping up against this limit when deploying
RHCOS images(currently 977MB). Curiously the problem isn't
happening all the time but increasing the limit eliminates it.

This limit was intruduced to guard against a malicious image
allocating an arbitrary amount of memory. Nothing else runs
on hosts when IPA is running so we should be ok bumping up
the limit.

Story: #2008667
Task: #41955
Change-Id: I9405995915a874b00b7177c9642c5469d05d66a8
This commit is contained in:
Derek Higgins 2021-03-01 15:14:46 +00:00
parent 4a22c887f8
commit 5492ad7da5
2 changed files with 9 additions and 2 deletions

View File

@ -46,8 +46,8 @@ sgdisk -Z $DEVICE
log "Imaging $IMAGEFILE to $DEVICE" log "Imaging $IMAGEFILE to $DEVICE"
# limit the memory usage for qemu-img to 1 GiB # limit the memory usage for qemu-img to 2 GiB
ulimit -v 1048576 ulimit -v 2097152
qemu-img convert -t directsync -O host_device $IMAGEFILE $DEVICE qemu-img convert -t directsync -O host_device $IMAGEFILE $DEVICE
sync sync

View File

@ -0,0 +1,7 @@
---
fixes:
- |
Increase memory usage limit for ``qemu-img convert`` command to 2 GiB.
See `Story 2008667
<https://storyboard.openstack.org/#!/story/2008667>`_
for details.