381 Commits

Author SHA1 Message Date
Vasyl Saienko
be6f34c338 Disable placement-api by default
With placement-api enablement Ironic jobs got into regression due to
[0]. The fix in Nova stuck at the decision phase [1]. Until Nova fix
issue permanently disable it in ironic to unblock CI.

[0] https://bugs.launchpad.net/ironic/+bug/1651678
[1] https://review.openstack.org/#/c/414214/

Change-Id: I658ec963761dd4c5111a98e77298a8974553e857
Related-Bug: #1651678
2016-12-28 09:48:58 +00:00
Pavlo Shchelokovskyy
fd3c5e9e14 Fix bashate warning in devstack plugin
currently running bashate as part of pep8 check produces a warning

E043 - Arithmetic compound has inconsistent return semantics

This patch fixes that place.

Change-Id: Iae010d22740498ae78d45fcaa4e541c68b0a8b76
2016-12-20 14:42:11 +02:00
John L. Villalovos
88171fcebd Configure tempest for multitenancy/flat network
Configure some tempest settings depending on if running multitenant vs
flat-network.

Add setting of [compute]/fixed_network_name for the flat-network case,
as this is required to run tempest "smoke" test.

Starting with the Newton release, multitenancy is available with
Ironic. This patch sets tempest auth.create_isolated_networks=False and
network.shared_physical_network=True only when Ironic is deployed for
a flat-network.

Partial-Bug: #1646640
Change-Id: I9807014b739b7364502d403e7ce72763f5ea698a
2016-12-19 11:46:43 -08:00
Jenkins
840fde15d3 Merge "Remove grenade config workaround" 2016-12-19 13:33:16 +00:00
Jenkins
d0e1d5e1f8 Merge "Move CONF.service_available.ironic to our plugin" 2016-12-16 13:41:09 +00:00
Jenkins
d2a02881a7 Merge "DevStack: Make $IRONIC_IMAGE_NAME less dependent of the name in DevStack" 2016-12-16 13:40:58 +00:00
Jenkins
4c0653a98d Merge "Make CONF.debug also reflect on IPA" 2016-12-16 12:53:44 +00:00
Vasyl Saienko
318b7638d9 Remove grenade config workaround
Starting with Idede322190d57491d4f7e18090aa8c29b5b87353 base and target
releases has the same tempest config file. This patch drops setting
fixed_network_name in target tempest.conf workaround.

Change-Id: I661ace60bf9b4817f73aaccda9c18e24adfc4e56
2016-12-16 14:25:55 +02:00
Lucas Alvares Gomes
e6349f278c DevStack: Make $IRONIC_IMAGE_NAME less dependent of the name in DevStack
This patch is making the $IRONIC_IMAGE_NAME less dependent on the full
name of the image in DevStack. We will need different images for the
UEFI work and this would break it so, let's make it a bit more smart.

Change-Id: Iac8668e9470bc151c10ea145d4394ba7ff7041d8
2016-12-14 14:29:04 +00:00
zhangyanying
0f37379525 Fix error when system uses /usr/bin/qemu-kvm, as in CentOS 7.2.
Got "libvirt.libvirtError" error when using "/usr/bin/qemu-kvm" on CentOS7.2.
CentOS 7.2 uses "/usr/libexec/qemu-kvm", this patch fixes it.

Change-Id: Icf2951701fddfac8e2f0641f6f555adb8a3c185b
Closes-Bug: #1649449
2016-12-14 17:54:59 +08:00
Lucas Alvares Gomes
f13f1ed654 Make CONF.debug also reflect on IPA
Prior to this patch, setting the CONF.debug to True in the ironic.conf
doesn't enable the debug logs in IPA. The user had to also append
"ipa-debug=1" to the CONF.pxe.pxe_append_params configuration option.

This patch is changing this behavior by making the CONF.debug option
reflect on the IPA logs as well. As I understand, IPA is just an
extension of the Ironic code that runs in-band on the node allowing
Ironic to access the local hardware. This way, in order to enable debug
as a whole the user only needs to set one configuration option.

The code in this patch checks if CONF.debug is set to True and also
check if "ipa-debug" is not explicit set in CONF.pxe.pxe_append_params
configuration - to not overwrite the user configuration - and only then
will append "ipa-debug=1" to it.

The "ipa-debug=1" kernel parameter was also removed from the devstack
lib because CONF.debug is always set to True there.

Change-Id: I675fb11248d3789d45cf5905b7c15368f026b345
Closes-Bug: #1649561
2016-12-13 14:53:08 +00:00
Jim Rollenhagen
8ad0a424b3 Move CONF.service_available.ironic to our plugin
This is unwanted in tempest's plugin, bring it here instead.

Also add skip checks for our tests to skip the tests if ironic is not
enabled. This allows the plugin to be installed in a tempest
environment, without breaking if ironic isn't present.

Last, drop 'baremetal' from the test.services decorators used, as it is
no longer in tempest's service list, and we use the skip check mentioned
above instead.

Change-Id: I0b7e32dfad2ed63f9dd4d7cad130da39bc869a8a
Depends-On: Idede322190d57491d4f7e18090aa8c29b5b87353
2016-12-12 14:39:32 -08:00
Jenkins
51402bcaae Merge "devstack: add vnc listen address" 2016-12-12 10:51:10 +00:00
Eli Qiao
95da9dc0d2 devstack: add vnc listen address
Make virtual machine graphical console listen on 0.0.0.0.
This allows to access to VM VNC console from remote ('desktop' PC)
on devstack's HOST_IP.
VNC port may be found by using: virsh vncdisplay {vm_name}

Change-Id: I253899393c98c24d46710aa4ab78f1090bae00f4
2016-12-12 01:39:16 +00:00
Jim Rollenhagen
82d7c8c588 Allow setting dhcp_provider in devstack
Provide a variable IRONIC_DHCP_PROVIDER to set CONF.dhcp.dhcp_provider.
This is needed to properly configure ironicclient functional tests,
which don't deploy neutron.

Change-Id: If601934d0c59b5dd5556336e5644832dc7564548
Partial-Bug: #1648179
2016-12-09 09:50:46 -05:00
Jenkins
a14dcc56de Merge "Add virtualpdu to ironic devstack plugin" 2016-12-06 11:16:08 +00:00
Jenkins
2100aff478 Merge "Auto enable the deploy driver" 2016-12-05 11:20:30 +00:00
Jenkins
75b648489b Merge "Turn off tempest's multitenant network tests" 2016-12-05 10:41:56 +00:00
Félix Bouliane
1a4f34266f Add virtualpdu to ironic devstack plugin
This adds virtualpdu with a default pdu configuration to be able to test
snmp drivers in ironic.

Change-Id: I76e519920920dc702ac510ad312ab412960b2edd
Related-Bug: #1597793
2016-12-02 18:16:57 -05:00
Martin Roy
733e509bab Auto enable the deploy driver
This will reduce misconfiguration as if the user forgets to
include its driver in the enabled driver, the stack will fail.

Change-Id: If5275a93432ffcac350e8bffa1ad4a2b126eea56
Partial-bug: #1633567
2016-12-02 18:00:28 -05:00
Jenkins
170f7d1d1a Merge "Increase verbosity of devstack/lib/ironic" 2016-12-02 17:30:28 +00:00
Jenkins
ff3a8f1d7f Merge "Support names for {cleaning,provisioning}_network" 2016-12-02 16:54:14 +00:00
Jenkins
cd4d09846f Merge "Cleanup adding Ironic to cluster on upgrade case" 2016-12-02 15:34:36 +00:00
Dmitry Tantsur
b6a2919b61 Support names for {cleaning,provisioning}_network
Names are easier to use for humans, so let's allow them.
The actual name -> UUID convertion happens during validation and its
result is cached for each interface instance.

This change will allow recreating a network without changing Ironic
configuration or setting a network name in advance (e.g. by an installer).

Note that when names are used, an administrator is responsible for ensuring
that no other networks have the same name (names are not unique in Neutron).

Change-Id: I9905bdc3f778310ba191b2bed6eb11bad11a2846
Closes-Bug: #1614938
2016-12-02 13:29:29 +01:00
Vasyl Saienko
db0612f3b6 Allow use *_ipmitool with vbmc on multinode
This patch removes hardcode of ipmi_address to 127.0.0.1 when
*_ipmitool with VirtualBMC is used.
Now ipmi_address=${HOST_IP} which allows to use *_ipmitool with
multinode scenario.

Change-Id: I250167a7bdd2a9752e39c25f54d5d3f616abf16d
2016-12-02 11:43:50 +02:00
Vasyl Saienko
3cbe7202b7 Cleanup adding Ironic to cluster on upgrade case
Grenade is designed to upgrade services. We shouldn't add them during
upgrade. This patch removes case when we trying to add Ironic to cluster
on upgrade.

Change-Id: Id7159aac8c8a343e3d20561cedc4722d87d3e776
2016-12-01 13:42:16 +02:00
Jenkins
c9ddeec16d Merge "Install syslinux package only for Wheezy / Trusty" 2016-11-30 22:59:25 +00:00
Jim Rollenhagen
0da98dee34 Turn off tempest's multitenant network tests
This disables the multitenant networking tests that come from tempest's
tree, but not the ones in ironic's tempest plugin.

Change-Id: I62cc4ae3e9fe7dc63ec4373535fe6ae07084a381
2016-11-30 07:38:05 -05:00
Vasyl Saienko
c81b385843 Do not source old/localrc twise in grenade
By sourcing localrc second time we try to enable ironic plugin
one more time witch is not allowed by [0]

This patch checks if ironic was enabled or not in base environment
without sourcing localrc.

[0] https://review.openstack.org/#/c/396794/

Change-Id: I432c243c66c0d11adcf4c6568968fbeaaf9acdcd
2016-11-30 11:35:02 +02:00
Jenkins
8cc063173e Merge "Update iptables rules and services IPs for multinode" 2016-11-29 10:06:40 +00:00
Jenkins
24bc4cbd7a Merge "Add devstack setup_vxlan_network()" 2016-11-28 11:25:04 +00:00
Mauro S. M. Rodrigues
6aea2126d4 Install syslinux package only for Wheezy / Trusty
Syslinux package is not available on Ubuntu Xenial ppc64el (Power). And
as of Jessie/Xenial, syslinux package only provides DOS and NTFS
loaders, which are not required. Keep installing the package for
previous releases Wheezy and Trusty to provide some compatibility
instead of removing the dependency completely.

Change-Id: I899e77423ba86cb4de2a949a29b8573d2465b76a
2016-11-25 13:04:31 -06:00
Jenkins
1b9c1de984 Merge "Skip some steps for multinode case" 2016-11-24 18:12:57 +00:00
Pavlo Shchelokovskyy
d21564eaba Fix PXE setup for fresh Ubuntu Xenial
Since Ubuntu 15.04 the file 'pxelinux.0' is provided by different
package ('pxelinux') which is not being installed by DevStack.
Extra problem is that this package does not exsit for earlier Ubuntu
versions at all.

More over, while in Trusty 'syslinux' package depends on
'syslinux-common', it only recommends it in Xenial, but we need it
installed as it provides *.c32 modules required for syslinux.

This patch adds 'syslinux-common' and 'pxelinux' to required deb packages
list when distro is 'xenial' or 'jessie' (as this packaging change has
its origin in Debian) by using the distro pinning in the package lists
as supported by DevStack.

Change-Id: I473fc4eb52f28a456c3f6888d5c7b25e8e08be26
Closes-Bug: #1638940
2016-11-21 16:18:14 +02:00
Vasyl Saienko
ff4c11e71e Add route to Neutron private network
Neutron no longer provide access to private network.
We need to add route manually to have ability to contact
with VM during provisioning.

https://review.openstack.org/#/c/397987/

Closes-Bug: #1642986
Change-Id: If281a1d6bc0fdaf48c4cfb8d923f7b1761f8162c
2016-11-18 18:33:19 +02:00
Vasyl Saienko
1aaf219162 Update iptables rules and services IPs for multinode
Update IRONIC_TFTPSERVER_IP and IRONIC_HTTP_SERVER IPs to IP address
from provisioning network. Update firewall rules to accept connections
on those IPs. Configure missing glance_host and glance_port options.

Depends-On: I0812e16583dfd678c8f349724a159b412f4efb55

Related-Bug: #1622653
Change-Id: Ia08a8601494d82fdd82d568c154bbef89c3a7f40
2016-11-17 09:19:38 +02:00
Vasyl Saienko
5e50f3ad78 Add devstack setup_vxlan_network()
This patch adds devstack: setup_vxlan_network() function.
With multinode topology br_ironic_vxlan dridge is created by devstack-gate
that provides VXLAN connectivity between VMs on primary and subnode.

Related-Bug: #1622653
Change-Id: I7461a8eaab138ea6ec1deb276cab00d20ce3c9f0
2016-11-17 09:19:07 +02:00
Vasyl Saienko
4cb95b7dc0 Skip some steps for multinode case
This patch skip the following steps from executing on subnode:
  * Upload baremetal image
  * Create baremetal flavor

Related-Bug: #1622653
Change-Id: Iae2024922fe5e5ba014264c867b897e2b044b992
2016-11-17 09:17:45 +02:00
Jenkins
292b4295d9 Merge "Bring configurations from tempest to ironic_tempest_plugin" 2016-11-15 10:40:52 +00:00
Thiago Paiva
ab6f73f7a0 Bring configurations from tempest to ironic_tempest_plugin
To remove our tests from tempest first we need to bring the configurations that
we need to the tempest plugin.

Closes-Bug: #1614516
Change-Id: Iad6e16c28cf2a35cc6bf040f57224d32c085b7bc
2016-11-14 10:50:04 -05:00
Jenkins
c73b5d0d3c Merge "Update ironic node names for multinode case" 2016-11-14 00:09:09 +00:00
Jenkins
cffaa47343 Merge "Update devstack provision net config for multihost" 2016-11-14 00:09:01 +00:00
Vasyl Saienko
2cf50d4d1d Update ironic node names for multinode case
Ironic node name is unique. This patch updates _ironic_bm_names()
function to generate uniq name for primary and subnodes.
On primary node node name is node-{id}.
On subnode node name is subnode-{id}. Where {id} is the node
number from 0 to $IRONIC_VM_COUNT

Related-Bug: #1622653
Change-Id: I7898426982b9fd89ac654a32e5d0b46d2a83dfcb
2016-11-11 11:46:59 +02:00
Vasyl Saienko
485259c808 Update devstack provision net config for multihost
This patch update devstack: configure_provision_network() function to work
with multinode case:

 * Ignore creating a new provision_network on subnode, just get an uuid for
   existed provision network.
 * Update IRONIC_PROVISION_ALLOCATION_POOL default value to left first 10 IPs
   for internal usage, exclude them from Neutron.
 * Add IRONIC_PROVISION_SUBNET_SUBNODE_IP variable, by default is 10.0.5.2.
   The IP address from provisioning network that is assigned to subnode.

Related-Bug: #1622653

Change-Id: I6c3ed6901ce5c5c94b6ad63a01d2875979a38ad5
2016-11-11 11:46:49 +02:00
Jenkins
edd10d6736 Merge "DevStack: Fix standard PXE on Ubuntu Xenial" 2016-11-09 19:03:43 +00:00
Jenkins
5cb06385f2 Merge "DevStack: Support for creating UEFI VMs" 2016-11-09 11:28:17 +00:00
John L. Villalovos
a788fd72b4 Increase verbosity of devstack/lib/ironic
Increase the verbosity of devstack/lib/ironic by enabling xtrace for
when sourcing devstack/lib/ironic. This information is useful to be able
to see what variables are set to along with other information.  This
will increase the devstack log size by about 1%.

Also print which stage the ironic devstack plugin is being called for.

Change-Id: Ibd2530720f21c0b0c03af5c7ed2a6d7aa68eda65
2016-11-08 18:15:12 -08:00
John L. Villalovos
a78097bf3f Add PS4 for better logfile information of devstack runs
The scripts
    tools/ironic/scripts/cleanup-node.sh
    tools/ironic/scripts/create-node.sh
    tools/ironic/scripts/setup-network.sh

are executed by sudo and the PS4 value disappears during sudo. Add a
PS4 value so that we get better logs during their execution.

PS4 is used to prefix the tracing output when using:
    'set -x' or 'set -o xtrace'

From the bash manpage:
PS4     The  value  of this parameter is expanded as with PS1 and the
        value is printed before each command bash displays during an
        execution trace.  The first character of PS4 is replicated
        multiple times, as necessary, to indicate multiple levels of
        indirection.  The default is ``+ ''.

Change-Id: If06f079bed16d9c84569594aa64259bf06f91a1e
2016-11-08 04:35:53 -08:00
Lucas Alvares Gomes
2f201d0c4e DevStack: Fix standard PXE on Ubuntu Xenial
The pxelinux.0 file in Ubuntu Xenial is now distributed by the
"pxelinux" package and lives at /usr/lib/PXELINUX/pxelinux.0 instead
of /usr/lib/syslinux/pxelinux.0.

This patch refactors the get_pxe_boot_file() function to accommodate to
be able to find the pxelinux.0 binary in the new path and also creates a
new setup_syslinux_modules() function to place the *.c32 modules in the
TFTP root dir (which in Xenial doesn't live at the same directory as the
PXE image anymore).

Change-Id: I9bd412f10f2235f1979a12dd3004fc60d4aa922f
Closes-Bug: #1638940
2016-11-03 17:46:58 +00:00
Vasyl Saienko
98596ca2c0 Skip db configuration on subnodes
This patch skip ironic db configuration on subnode when multinode
topology is used.

Change-Id: Ic260b4f8b5f1508ff517bcf71354905f84f0a342
2016-11-03 16:54:16 +02:00