This patch is adding a new command called sync to the standby module of
IPA. The new command runs synchronously and it's responsible for
flushing file system buffers to the disks.
The initial intention for this command is to use it as part of the fix
for the bug #1512492 where some hardware/firmwares do have problems to
come back online after a soft ACPI power off, therefore we need to call
sync() to make sure all file system buffers have been synced and then
issue a hard power off (e.g via the BMC).
Partial-Bug: #1512492
Change-Id: I5cd1d1b821426e995dc584452494b93ab23917e0
This patch is fixing a programmatic error in the heartbeat() method of
the APIClient() class. When 409 (Conflict) was returned from the the
Ironic API the code wasn't parsing the content of the response
correctly.
Change-Id: I01fbb8d866b2f94fe128d0bc40b69d05b5add1a3
Closes-Bug: #1556199
Logging the whole journalctl output is not the best idea. Fortunately,
it does not work right now and fails with a traceback :)
This change adds a new log_stdout argument to utils.execute() and uses it in
the "logs" inspection collector.
Also do not log the logs while logging the collected data.
Change-Id: Ibc726ac2c4f5eb06c73ac4765bb400077b84a6cc
This patch is masking the services that are started when the Ironic
Python Agent ramdisk boots up but are not needed. Consequently, this may
save us some seconds at startup time.
The list of services disabled are: update-engine, update-engine-stub,
resize-btrfs, locksmithd, fleet and etcd.
Change-Id: Ib91ec2d0c69b1724170d38dea5d38248145c5d9f
It's normal that ironic returns 409 Conflict from time to time, so
it's a bit confusing that we report this with Exception level and
traceback.
Change-Id: I1627c61facc3fadd0f5d9d324150e7d2833c7fbc
Closes-Bug: #1533113
This patch is making the list_all_block_devices() method to wait for
udev to settle it's event queue prior to listing the devices.
Sometimes the ironic-python-agent service may start before all devices
were detected and end up erroring out because it couldn't find a
suitable disk for deployment.
Closes-Bug: #1551300
Change-Id: I1ae2062a711115a1ea14b79ae9ace7ddd2fff9d5
Changed implementation to strip tokens up until the first 'Size: '
string. This will allow for less parsing errors in the first
six lines of the following output:
"dmidecode --type 17 | grep Size" returns:
Maximum Memory Module Size: 4096 MB
Maximum Total Memory Size: 8192 MB
Size: 2048 MB
Size: 2048 MB
Added a condition in the exception handling to address the
issue of the bug on other outputs like:
Installed Size: Not Installed
Enabled Size: Not Installed
Size: No Module Installed
Size: 1024 MB
Common strings like "No Module Installed" and "Not Installed" are
normal. These two strings are hard coded in the before mentioned
comparison and when found are logged as warnings instead of errors.
Change-Id: If3475afcebfc7af7e9256b99924919557c4d909c
Closes-Bug: #1521202
When neither tgt nor linux-io are available, we only get error
message like 'No such file or directory', this situation should
be detected and return a better error instead.
Change-Id: I334717a1a8a728aa6da6024ff9fc6d817399a41f
Closes-Bug: #1540958
We want to install the dev version of IPA but we don't want pre-release
versions of IPA's dependencies, this patch ensures that only released
deps are installed.
Change-Id: I6187fbbd0bdd80503861d3760248f3f23c1c6388
We need to explicitly use /bin/bash for the {build, finalise}-tinyipa.sh
scripts because the script relies on a bash extension to get the current
working directory.
Depends-On: I4690514803dd91d4bda0d38df4fd792f31a51421
Change-Id: Ic1ed66c8fa8936a822e112199844a869106751dc
This patch set add hardware vendor information to data.
By using this data, we can get hints to detect driver.
Change-Id: I39385fd5d616edfad719c255f22642f215bfb532
This patch clears all GPT and MBR data structures on the disk.
GPT maintains its data structures at start and at end of the
disk.
Change-Id: I8d0b367755b568cb44f02f62b873659b4bea0f14
Closes-Bug: #1543339
This patch enables virtual media deploy even if the expected virtual
floppy device name "/dev/disk/by-label/ir-vfd-dev" is capitalized to
"/dev/disk/by-label/IR-VFD-DEV".
This change is necessary because some bare metal hardware such as
FUJITSU RX1330 series create the capitalized virtual floppy device
name.
Change-Id: I436b3f9524a83814e082f8dd421df3e53b33f792
Closes-Bug: #1541167
When building the docker image, the 'apt-get' and 'pip install' that are
run inside the docker image will fail in a an environment that uses
proxy servers.
Support environments with proxy servers by dynamically propagating
'http_proxy', 'https_proxy', and 'no_proxy' into the docker environment
when running 'apt-get' and 'pip install'
This can not be done with either --env-file or --env as those are
arguments to 'docker run'. The command being run here is 'docker build'
Once Docker 1.9 is widely deployed, we should switch to using the 'ARG'
command which was added in Docker 1.9. Currently Ubuntu 14.04 uses
Docker 1.6. Using the ARG command will be a much cleaner solution.
Change-Id: Idd994cd58b9fb75bae13a43fc8363c36f113527d
Closes-Bug: #1533796
The code that comprises the backoff looping call moved to
oslo.service in 0.10.0 and IPA can use that version so remove
the local backoff code and just prefer the oslo.service maintained
and supported version instead.
Change-Id: Ifec3490f9e5c68859deff4a951dcdf59caa7ca3a
Downstream agent builders that inherit from this Dockerfile will often
need git installed to be able to install hardware managers and such.
Removing git and reinstalling it can cause weird apt dependency issues
down the line, so leave it installed.
Change-Id: I8d5f35d0c8c6a231144a7b0a5b5c8f6d051ab0b1
This patch is extending the root device hints to also look at the device
name. This patch also refactors the tests for root device hints making
it easier to test a different hint per test.
Change-Id: I48d6456c75bbe6ddf16ac6561e5461ca51eb9c37
Partial-Bug: #1526732
TinyCoreLinux is a small 10mb base linux distribution which can easily
be built into a ramdisk for PXE and ISO booting. This patch adds scripts
and other required files to build a TinyCore based ramdisk which runs
the Ironic Python Agent.
Change-Id: I79fbec75de19b3d6feb19f87a3a0f662eae42bf3