<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/ironic-python-agent.git/ironic_python_agent/shell, branch stable/ussuri</title>
<subtitle>opendev.org: openstack/ironic-python-agent.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/'/>
<entry>
<title>Limit qemu-img execution arenas</title>
<updated>2021-06-01T19:33:23+00:00</updated>
<author>
<name>Julia Kreger</name>
<email>juliaashleykreger@gmail.com</email>
</author>
<published>2021-05-26T18:55:44+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=bc849e2f68fd40fe76515293e4157e94ebd5bf7b'/>
<id>bc849e2f68fd40fe76515293e4157e94ebd5bf7b</id>
<content type='text'>
qemu-img attempts to launch multiple threads by default *and*
attempts to have multiple memory allocation arenas to operate
from. While multithreading can be good for performance, this
pattern and the memory footprint for process launch and
dependencies can turn the memory footprint for a cirros image
conversion (16MB) into 1.2GB of memory being asked for by the
qemu-img tool.

In order to limit this impact, as the default number of arenas
is governed by the number of CPUs times the number 8, it seems
reasonable to lower this to a more reasonable number which
also helps keep our possible memory footprint from being exceeded.

NOTE: This change is largely different than the original change
as an intermediate change converted write_image.sh to python.
As it is unlikely for us to backport the intermediate change,
it is logical for us to just modify the original script.
Otherwise the release note is ultimately what is backported for
release note tooling continutity.

Change-Id: I71a28ec59ec31c691205eb34d9fcab63a2ccb682
Story: 2008928
Task: 42528
(cherry picked from commit 9e4c7052a2fd9aac03858db696bf1ea9487f15e6)
(cherry picked from commit 9c20cca36284a2a17aa535bef92c828096c7d926)
(cherry picked from commit ee8118423b88f61ed58b0420356ceaed2fa53a40)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
qemu-img attempts to launch multiple threads by default *and*
attempts to have multiple memory allocation arenas to operate
from. While multithreading can be good for performance, this
pattern and the memory footprint for process launch and
dependencies can turn the memory footprint for a cirros image
conversion (16MB) into 1.2GB of memory being asked for by the
qemu-img tool.

In order to limit this impact, as the default number of arenas
is governed by the number of CPUs times the number 8, it seems
reasonable to lower this to a more reasonable number which
also helps keep our possible memory footprint from being exceeded.

NOTE: This change is largely different than the original change
as an intermediate change converted write_image.sh to python.
As it is unlikely for us to backport the intermediate change,
it is logical for us to just modify the original script.
Otherwise the release note is ultimately what is backported for
release note tooling continutity.

Change-Id: I71a28ec59ec31c691205eb34d9fcab63a2ccb682
Story: 2008928
Task: 42528
(cherry picked from commit 9e4c7052a2fd9aac03858db696bf1ea9487f15e6)
(cherry picked from commit 9c20cca36284a2a17aa535bef92c828096c7d926)
(cherry picked from commit ee8118423b88f61ed58b0420356ceaed2fa53a40)
</pre>
</div>
</content>
</entry>
<entry>
<title>Increase the memory limit for qemu-img</title>
<updated>2021-06-01T19:30:45+00:00</updated>
<author>
<name>Derek Higgins</name>
<email>derekh@redhat.com</email>
</author>
<published>2021-03-01T15:14:46+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=d8c116aa7bd0e47199cc89ffdae4612915ab2447'/>
<id>d8c116aa7bd0e47199cc89ffdae4612915ab2447</id>
<content type='text'>
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
(cherry picked from commit 5492ad7da59571581e9f70fd054efafb39e12593)
(cherry picked from commit de1e75126a09db9d27bfb4d77a3d2eab99c66c0c)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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
(cherry picked from commit 5492ad7da59571581e9f70fd054efafb39e12593)
(cherry picked from commit de1e75126a09db9d27bfb4d77a3d2eab99c66c0c)
</pre>
</div>
</content>
</entry>
<entry>
<title>Clear GPT and MBR headers with dd to avoid sgdisk CRC errors</title>
<updated>2018-08-08T16:40:22+00:00</updated>
<author>
<name>Giulio Fidente</name>
<email>gfidente@redhat.com</email>
</author>
<published>2018-08-08T10:16:19+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=bc21b5b1404c269d000e1de6f9dce9c046f7d15d'/>
<id>bc21b5b1404c269d000e1de6f9dce9c046f7d15d</id>
<content type='text'>
This change adds a dd before the existing sgdisk -Z command to
workaround CRC verification errors.

Change-Id: Ia1ac4e1c0faf14ad4bb11c2a1c796c93ca8cb5e3
Closes-Bug: #1737556
Story: 1737556
Task: 11496
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This change adds a dd before the existing sgdisk -Z command to
workaround CRC verification errors.

Change-Id: Ia1ac4e1c0faf14ad4bb11c2a1c796c93ca8cb5e3
Closes-Bug: #1737556
Story: 1737556
Task: 11496
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix for fatal error when GPT was used and only MBR was cleaned</title>
<updated>2018-05-17T10:51:55+00:00</updated>
<author>
<name>Olivier Bourdon</name>
<email>obourdon@opennext.io</email>
</author>
<published>2018-05-17T10:50:41+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=5fcf3f066ccdbcc081ae35ab25f1c18737b94778'/>
<id>5fcf3f066ccdbcc081ae35ab25f1c18737b94778</id>
<content type='text'>
You can generate this error if after having provisioned a node
using GPT partitioning, you clean its MBR using say
dd if=/dev/zero bs=1024 count=1 of=/dev/sda
and then cleanup all Ironic/Bifrost informations to get it
reprovisioned.
In this case sgdisk -Z returns an error and last_error field
in Ironic contains:
Error writing image to device: Writing image to device
        /dev/sda failed with exit code 2
Caution: invalid main GPT header, but valid backup;
        regenerating main header\nfrom backup!\n
        \nInvalid partition data!\

Change-Id: Ib617737fff5e40cb376edda0232e0726d9c71231
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
You can generate this error if after having provisioned a node
using GPT partitioning, you clean its MBR using say
dd if=/dev/zero bs=1024 count=1 of=/dev/sda
and then cleanup all Ironic/Bifrost informations to get it
reprovisioned.
In this case sgdisk -Z returns an error and last_error field
in Ironic contains:
Error writing image to device: Writing image to device
        /dev/sda failed with exit code 2
Caution: invalid main GPT header, but valid backup;
        regenerating main header\nfrom backup!\n
        \nInvalid partition data!\

Change-Id: Ib617737fff5e40cb376edda0232e0726d9c71231
</pre>
</div>
</content>
</entry>
<entry>
<title>Limit memory usage when running qemu-img convert</title>
<updated>2017-01-19T18:01:30+00:00</updated>
<author>
<name>Lucas Alvares Gomes</name>
<email>lucasagomes@gmail.com</email>
</author>
<published>2017-01-19T17:16:38+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=449cda4fed51250992446c83a4b50bc45fd10c6d'/>
<id>449cda4fed51250992446c83a4b50bc45fd10c6d</id>
<content type='text'>
This patch is limiting the memory address space to 1 GiB when invoking
qemu-img convert. The qemu-img command can be exploited so we better
play on the safe side (See: bug #1449062).

Change-Id: I2088f74b32d1392310c569cfaa7fd368cb737421
Closes-Bug: #1657808
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch is limiting the memory address space to 1 GiB when invoking
qemu-img convert. The qemu-img command can be exploited so we better
play on the safe side (See: bug #1449062).

Change-Id: I2088f74b32d1392310c569cfaa7fd368cb737421
Closes-Bug: #1657808
</pre>
</div>
</content>
</entry>
<entry>
<title>Moving Reboot bashscript to python</title>
<updated>2016-12-15T00:05:03+00:00</updated>
<author>
<name>Bharath kumar</name>
<email>shettybharath4@gmail.com</email>
</author>
<published>2016-09-19T12:41:04+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=9948349b10b6bb694f92813243598a7a7c84d3f8'/>
<id>9948349b10b6bb694f92813243598a7a7c84d3f8</id>
<content type='text'>
Currently a reboot bash script file is used to call reboot and
poweroff operation. Deleting this file and moving the code to
python file using utils.execute()

Partial-Bug: #1557542

Change-Id: Iad9cd9d15417e9a954d108d2759e6303452fca27
Author: Bharath kumar &lt;shettybharath4@gmail.com&gt;
Co-Authored-By: Annie Lezil &lt;annie.lezil@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently a reboot bash script file is used to call reboot and
poweroff operation. Deleting this file and moving the code to
python file using utils.execute()

Partial-Bug: #1557542

Change-Id: Iad9cd9d15417e9a954d108d2759e6303452fca27
Author: Bharath kumar &lt;shettybharath4@gmail.com&gt;
Co-Authored-By: Annie Lezil &lt;annie.lezil@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add bash scripts style checking for IPA</title>
<updated>2016-11-09T22:14:40+00:00</updated>
<author>
<name>OpenStack Proposal Bot</name>
<email>openstack-infra@lists.openstack.org</email>
</author>
<published>2016-11-04T14:08:31+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=c40575e4e046904d5dbd28826bf5308915093f15'/>
<id>c40575e4e046904d5dbd28826bf5308915093f15</id>
<content type='text'>
Updated file tox.ini allows to check code style in all ".sh" files
included in Ironic Python Agent. Checking can be invoked by calling either
"tox" or "tox -e pep8".

Change-Id: Ie76605737c7db10a064f2aebfda388372a4c0591
Closes-Bug: #1625215
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Updated file tox.ini allows to check code style in all ".sh" files
included in Ironic Python Agent. Checking can be invoked by calling either
"tox" or "tox -e pep8".

Change-Id: Ie76605737c7db10a064f2aebfda388372a4c0591
Closes-Bug: #1625215
</pre>
</div>
</content>
</entry>
<entry>
<title>Use ironic-lib to create configdrive</title>
<updated>2016-10-21T03:39:06+00:00</updated>
<author>
<name>Shivanand Tendulker</name>
<email>stendulker@gmail.com</email>
</author>
<published>2016-03-23T14:26:32+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=3665306dfbf9afadf06fc669b75a74e1c08b6b01'/>
<id>3665306dfbf9afadf06fc669b75a74e1c08b6b01</id>
<content type='text'>
Shell script to create config drive being replaced with python
code in ironic-lib.

Closes-Bug: #1493328

Change-Id: I31108f1173db3fb585386b2949ec880a95305fb6
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Shell script to create config drive being replaced with python
code in ironic-lib.

Closes-Bug: #1493328

Change-Id: I31108f1173db3fb585386b2949ec880a95305fb6
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix config drive writing script</title>
<updated>2016-10-17T21:28:04+00:00</updated>
<author>
<name>Vladyslav Drok</name>
<email>vdrok@mirantis.com</email>
</author>
<published>2016-10-13T12:28:04+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=7bda3408f5bef4349c4e3537f3c8c0826a5dead8'/>
<id>7bda3408f5bef4349c4e3537f3c8c0826a5dead8</id>
<content type='text'>
When the deployment happens on a GPT disk with config drive, writing
it to disk fails. Three reasons for that:

* parted should be used instead of partprobe to determine the type of
  the disk;
* gdisk -l sorts the partitions by their number, sort them by start
  sector instead;
* after sgdisk completion, the configdrive device is not immediately
  visible in the /dev folder, udevadm settle needed here too.

Closes-Bug: #1633063
Change-Id: Ifed89e343f9db4cf303baf7f8823342f6041f202
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When the deployment happens on a GPT disk with config drive, writing
it to disk fails. Three reasons for that:

* parted should be used instead of partprobe to determine the type of
  the disk;
* gdisk -l sorts the partitions by their number, sort them by start
  sector instead;
* after sgdisk completion, the configdrive device is not immediately
  visible in the /dev folder, udevadm settle needed here too.

Closes-Bug: #1633063
Change-Id: Ifed89e343f9db4cf303baf7f8823342f6041f202
</pre>
</div>
</content>
</entry>
<entry>
<title>Prevent failure on 'copy_configdrive_to_disk.sh'</title>
<updated>2016-05-17T21:09:03+00:00</updated>
<author>
<name>Ricardo Araújo Santos</name>
<email>ricardo@lsd.ufcg.edu.br</email>
</author>
<published>2016-05-16T19:10:08+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/ironic-python-agent.git/commit/?id=a90ee859a2c641c9461e918213c9816f53358548'/>
<id>a90ee859a2c641c9461e918213c9816f53358548</id>
<content type='text'>
The script splits 'sfdisk' output wrongly in blank spaces leading to
failures when partition id is greater than 10, e.g.:
"/dev/sda10: start= ...".

This fix splits the output on ":" and trims trailing space when
partition id is less than 10, e.g.: "/dev/sda1 : start= ...".

Change-Id: I23f4b747fc0a86713cb912afc5d193398e6a597b
Closes-Bug: 1581699
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The script splits 'sfdisk' output wrongly in blank spaces leading to
failures when partition id is greater than 10, e.g.:
"/dev/sda10: start= ...".

This fix splits the output on ":" and trims trailing space when
partition id is less than 10, e.g.: "/dev/sda1 : start= ...".

Change-Id: I23f4b747fc0a86713cb912afc5d193398e6a597b
Closes-Bug: 1581699
</pre>
</div>
</content>
</entry>
</feed>
