8bf5651f82bd4921e46ef84ea919cbb7f0757dc7
289 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
Shuquan Huang
|
fac700c8e7 |
Change assertTrue(isinstance()) by optimal assert
Some of tests use different method of assertTrue(isinstance(A, B)) or assertEqual(type(A), B). The correct way is to use assertIsInstance(A, B) provided by testtools. Change-Id: I8e95e10fac4748b115838b6b480f1085da73f28a Closes-bug: #1268480 |
||
|
Jenkins
|
55239c2199 | Merge "Fix params order in assertEqual" | ||
|
Swapnil Kulkarni (coolsvap)
|
da900108d3 |
Update typos
Change-Id: Ia0992ebc7a9355d5ea99d0cde28e03fc0d2a1346 |
||
|
Kan
|
2b07976b94 |
Fix params order in assertEqual
Fix params order to correspond to real signature: assertEqual(expected, actual) Change-Id: I129aad5d8bb7ca0541c07913cb5edd8eef9e90ba Closes-Bug: #1277104 |
||
|
Jenkins
|
f9ad095aa6 | Merge "Remove unused logging" | ||
|
LiuNanke
|
8522a550c0 |
Remove unused logging
Change-Id: I4303b42d1d746635d5fe394e23f1a674fcc9fb03 Closes-bug: #1529541 |
||
|
Kan
|
dcdb06d812 |
Replace deprecated LOG.warn with LOG.warning
Change-Id: I0ca31eac70afaccda73e7819c582af0b226b8442 Closes-Bug: #1508442 |
||
|
Jenkins
|
475fe9e638 | Merge "Replace assertEqual(None, *) with assertIsNone in tests" | ||
|
Shuquan Huang
|
cfcef973e8 |
Replace assertEqual(None, *) with assertIsNone in tests
Replace assertEqual(None, *) with assertIsNone in tests to have more clear messages in case of failure. Change-Id: Iad3f8fbb23a8b0f9e5ae4f304799465724c1a433 Closes-bug: #1280522 |
||
|
Dmitry Tantsur
|
4cd64e28aa |
Delete the Linux-IO target before setting up local boot
Otherwise it fails with "device already mounted". Change-Id: If959ba5a10e97f84be2f7498bed7589d13fa30c2 Closes-Bug: #1526304 |
||
|
Dmitry Tantsur
|
5fa258b708 |
Fix "logs" inspection collector when logs contain non-ascii symbols
Somehow it didn't pop earlier. Updated tests to contain some creepy russian letters :) Closes-Bug: #1517913 Change-Id: I4c6712ea1e813d1f0f0d0aedaccfa1187526e0ec |
||
|
Jenkins
|
1720759fa7 | Merge "Support Linux-IO in addition to tgtd" | ||
|
Dmitry Tantsur
|
2fc6ce22f8 |
pyudev exception has changed for from_device_file
Now pyudev raises DeviceNotFoundByFileError which does not inherit from EnvironmentError, so our 'except' block in hardware.py no longer catch the exception. It broke unit tests, but it can also potentially break the deploy. This patch updates hardware.py to catch both old a new exceptions. Change-Id: Iaefd6089f6f766a241054d8e132b2f3098c8130d Closes-Bug: #1522756 |
||
|
Dmitry Tantsur
|
c474a5ac6c |
Support Linux-IO in addition to tgtd
The iSCSI extension now tries to use Linux-IO first (via rtslib) and falls back to tgtd if Linux-IO can't be used (e.g. in the CoreOS-based image which uses containers). Change-Id: I9cc7a30d9c93c445a66d183146e9260c2b096d33 Closes-Bug: #1504562 |
||
|
Jenkins
|
4ba04475ec | Merge "Add support for streaming raw images directly onto the disk" | ||
|
Jenkins
|
a2a71105c4 | Merge "Refactor the image download and checksum computation bits" | ||
|
Jenkins
|
b53bd28a20 | Merge "Create partition at max msdos limit for disks > 2TB" | ||
|
Lucas Alvares Gomes
|
e320bb8942 |
Add support for streaming raw images directly onto the disk
This patch adds support for streaming a raw image directly onto the disk, that means no more time spent writing the image to a tmpfs partition prior to copying it to the disk. Checksum computation is also done as the image is being streamed. Streaming raw images is disabled by default, however this behavior can be enabled by passing a key called "stream_raw_images" with the value of True to the prepare_image() command of IPA. For non-raw images this may not be possible, not sure about all image file formats, but common types such as qcow2 requires random access to the image file in order to be converted to raw. Closes-Bug: #1505685 Change-Id: Iddf67907bc9b54bbd3065a97064cb5a3602cfe18 |
||
|
Lucas Alvares Gomes
|
65053b7737 |
Refactor the image download and checksum computation bits
Prior to this patch downloading and computing the checksum of the image were done in different stages, after the download the file would need to be re-read and the checksum was computed. This patch is changing it by creating a ImageDownload class which computes the checksum at the same time the image is being downloaded, this saves time and also make the code more portable. Related-Bug: #1505685 Change-Id: I71f9f2bd9a62a6a6cc474d0ae519591cea6381d6 |
||
|
Lucas Alvares Gomes
|
c21409e98b |
Follow up patch for da9c3b0adc
This patch is a follow up patch fixing some nits left by the review
|
||
|
Yolanda Robla
|
a01c4c90eb |
Create partition at max msdos limit for disks > 2TB
Currently there is a problem on partition creation for MBR case. If disk exceeds 2TB, partition creation fails because we are hitting max msdos limit. Detect total disk size, and if it exceeds that limit, create the partition at the end of legal limits. Fixes-Bug: #1517077 Change-Id: I11dd3f11eaa6af764151b442768d10289ced6d3f |
||
|
Jenkins
|
39bdbdd357 | Merge "determine tgtd ready status through tgtadm" | ||
|
Jenkins
|
5dd57838d1 | Merge "Support proxies for image download" | ||
|
Vladyslav Drok
|
54c901e8d5 |
Support proxies for image download
This change adds proxies parameter to requests.get method when downloading images, and also sets no_proxy environment variable, as requests does not support such parameter directly. Implements: blueprint agent-image-proxy Change-Id: I000ff9d0d4f5bde4766d085dc5a1c6cea1949bc5 |
||
|
Lucas Alvares Gomes
|
da9c3b0adc |
Extend root device hints for different types of WWN
This patch is extending the root device hints to also look at ID_WWN_WITH_EXTENSION and ID_WWN_VENDOR_EXTENSION from udev. Prior to this patch the IPA ramdisk only cared about ID_WWN but in some systems in some platforms with a RAID controller, this ID can be same even if they are different disks (see bug 1516641). Closes-Bug: #1516641 Change-Id: Ic3e9a1111dfcc99702190c173562a0dccf5f94c4 |
||
|
Jenkins
|
2bce5f6065 | Merge "Use oslo.log instead of original logging" | ||
|
Jenkins
|
96e21042d8 | Merge "Replace deprecated LOG.warn with LOG.warning" | ||
|
ZhiQiang Fan
|
9e75ba5460 |
Use oslo.log instead of original logging
We are using oslo.log now, but some of the modules still use logging. We should use oslo.log to keep consistency, besides, oslo.log can provide fine wrapper for OpenStack projects. Change-Id: Ibe57e503b88b39e284a9e4b11a1886cd4e8d4ccf |
||
|
Jenkins
|
5a962e4ac7 | Merge "Use system random where applicable" | ||
|
Jenkins
|
64bdf16b68 | Merge "Refactor backoff looping call" | ||
|
Zhenguo Niu
|
18d5d6aba3 |
Replace deprecated LOG.warn with LOG.warning
Change-Id: Ib3d566f6e608ee453659e15cabcf8e9332aedc52 Closes-Bug: #1508442 |
||
|
dparalen
|
e51ccbe7c3 |
avoid duplicate text in ISCSIError message
The ISCSIError class defines a class-level message attribute with value: "Error starting iSCSI target". This attribute is further processed in RESTError.__init__ method, the ISCSIError super-class, to create an Exception message concatenating self.message with provided details argument. However, the ISCISError.__init__ method provides a details attribute prefixed with the same text to the super(ISCSIError, self).__init__ method. As a result, the text appears twice: "ISCSIError: Error starting iSCSI target: Error starting iSCSI target: ISCSI daemon didn't initialize. Failed with exit code 107. stdout: . stderr: tgtadm: failed to send request hdr to tgt daemon, Transport endpoint is not connected" The patch purpose is to remove the details prefix to avoid duplicate text in the exception text while honouring ISCSIError.message. Change-Id: I9e1434ae17da5112527a841ac069ed2285566cca |
||
|
dparalen
|
fb920f41ed |
determine tgtd ready status through tgtadm
The intention of the iscsi extension _wait_for_iscsi_daemon function is to wait till the tgtd process boots completely before running any iscsi commands through the tgtadm command line utility. The tgtd process utilises a unix socket for communication with the user and the _wait_for_iscsi_daemon function asserts the tgtd process status based on the socket presence. The socket name/path to use is not specified by iscsi extension configuration but rather falls-back to a (system-wide) default value[1]. Since tgtd version 1.0.60, this path changed from /var/run/tgtd.ipc_abstract_namespace to /var/run/tgtd/socket[2] and now causes a false-negative while waiting for the tgtd process to boot[3]. This patch follows implementation suggestion from the bug report[3] to avoid relying on the socket presence but rather to check the tgtd status by trying to communicate through the tgtadm tool. [1] https://github.com/openstack/ironic-python-agent/blob/ 5bbb9ded082f2cfde5e8877e9f33294eb93a5fb7/ ironic_python_agent/extensions/iscsi.py#L47 [2] https://github.com/fujita/tgt/commit/ d1aa4dcfd691c9409dbad5db49ce6754ce9c1b5a [3] https://bugs.launchpad.net/ironic-python-agent/+bug/1505923 Closes-Bug: #1505923 Change-Id: If3284e0b441fe6c2da507640c08a4bbefd9dad2b |
||
|
Jenkins
|
90b4d15b41 | Merge "Make calling arguments easier to understand" | ||
|
Naohiro Tamura
|
f013333949 |
Add param docstring into the normalize func
This patch adds a missing param docstring into the normalize function in util.py. Change-Id: I91ecc0970fc386163657ab521d8cdd898694a426 Partial-bug: 1367915 |
||
|
John L. Villalovos
|
06d34ae5d7 |
Make calling arguments easier to understand
Use keyword= when doing the call so easier for reader of code to know what all the arguments are. Change-Id: I4d781b533b15c6855a3d8ad95bb17bf9d153f1eb |
||
|
Jenkins
|
b6c2eb6ca6 | Merge "Ensure all methods in utils.py have docstrings" | ||
|
Jenkins
|
ef57379342 | Merge "Add LOG.debug() if requested device type not found" | ||
|
Jay Faulkner
|
6131b2e405 |
Ensure all methods in utils.py have docstrings
Previous some of these methods were not well documented. Hopefully they now are. Change-Id: If73987a2dd234b71a1c2af9b764becc34aee4496 Partial-bug: 1367915 |
||
|
Jenkins
|
4a248f3ea0 | Merge "Use mount -t sysfs to avoid host /sys dependencies" | ||
|
John L. Villalovos
|
deb50ac5a8 |
Add LOG.debug() if requested device type not found
This is a follow-up patch for commit
|
||
|
Jenkins
|
2c0ebdea09 | Merge "Adds more functional tests for commands" | ||
|
Dan Prince
|
ebd7b076a5 |
Use mount -t sysfs to avoid host /sys dependencies
This patch updates the _install_grub2 function in image.py so that we use 'mount -t sysfs' instead of bind mounting the hosts /sys into the chroot. This resolves issues which can occur with unmounting the chroot mounts where 'target is busy' errors may occur when you are debugging things with a serial console. Change-Id: I5c9a6546d048cbf54695329d9744fda55127bd30 Closes-bug: #1503385 |
||
|
Jenkins
|
aa908205c6 | Merge "Refactor list_all_block_devices & add block_type param" | ||
|
Dan Prince
|
5bbb9ded08 |
Fix log formatting error in iscsi.py
This fixes a ValueError exception that would occur if log debug was enabled in IPA. Change-Id: Id95f291dd77d69e7d4dd4f945c6c151db7a0646b Closes-bug: #1503354 |
||
|
Mario Villaplana
|
4a7b954d14 |
Adds more functional tests for commands
This adds additional functional tests for the commands API. It also restructures the current functional test to run in sequence as a monolithic test to preserve IPA state and test order between test runs. The time to wait for IPA to start was increased due to an intermittent race condition that occurs with the larger test suite. Partial-Bug: 1492036 Change-Id: Iff9b41fb531d34225d702b9bfd39826e3c7195ad |
||
|
John L. Villalovos
|
dcbba2b121 |
Enforce all flake8 rules except E129
Bring ironic-python-agent in line with the other ironic projects. Stop ignoring all E12* errors except E129 Stop ignoring E711 Change-Id: Icb9bc198473d1b5e807c20869eb2af7f4d7ac360 |
||
|
Dmitry Tantsur
|
9d6b0864e3 |
Add "logs" and "extra-hardware" inspection collectors
This is a port of downstream inspector ramdisk plugins we found helpful. * logs - sends journald logs with inspection data. * extra-hardware - uses hardware-detect utility to collect bigger hardware inventory and to run benchmarks. Change-Id: If05402606c45185d618279eef46e68c51209f82b |
||
|
Jenkins
|
378197caee | Merge "Make the erase_devices clean step abortable" | ||
|
Lucas Alvares Gomes
|
cd70f514d6 |
Make the erase_devices clean step abortable
This patches updates the get_clean_steps() method to make the erase_devices step abortable. Erasing devices is something that can be cancelled without damaging the machine. When a clean step is aborted the provision state of the Ironic node will go to CLEANFAIL state. The operator can then do what is needed to fix the problem (i.e network booting issues) and restart the cleaning later on. Partial-Bug: #1455825 Change-Id: Ic181ac3712810c6f6925e8b627ee79e77ecf4d83 |