When re-stacking locally, my restack failed because .hushlogin already
existed in the folder. :\
Change-Id: I45b5d676d7f008cf8c4f110cfa22a7c96d4db7e1
Signed-off-by: Julia Kreger <juliaashleykreger@gmail.com>
This makes sure that developers perform a good default set of checks when
simply running "tox": unit tests, pep8, code spelling.
Fix the two small spelling issues in current codebase.
Signed-off-by: Julia Kreger <juliaashleykreger@gmail.com>
Signed-off-by: Baptiste Jonglez <baptiste.jonglez@inria.fr>
Change-Id: I1e128c395530dab7b12701d3c3dd6a31d4f1dd73
... because it can be now automatically discovered.
Change-Id: I4e36e242a80f4dbe45607e1369ff8b4d237c9db7
Signed-off-by: Takashi Kajinami <kajinamit@oss.nttdata.com>
This eliminates one of the two implied ordering things we're relying on.
We should now be OK if networking_generic_switch is configured before
neutron. We are still relying on implied behavior of neutron services
restarting sometime after our work in the post-config phase.
Change-Id: I5a763b74ea349a74c66feca38ded46cda91d82a4
When neutron changed to using uwsgi only, it automatically excluded
configuration parameters needed to supply configuration to launch ML2
plugins in the standard style of devstack, because the pattern only
allowed for auto-configuration which only loads two files, or from
a files in a single directory pattern, or a list of files supplied
by environment variable.
Ideally, we'd be able to restart neutron as well. We can't due to when
things happen upstream; the post-config phase is not always late enough
since neutron does some configuration there, the extra phase is too late
as Ironic will be setting up nodes there. For now, we're relying on a
race condition that we reliably win.
Change-Id: I5cfd1fc247043ede9b71252ee681ce2ca413ede6
Signed-off-by: Jay Faulkner <jay@jvf.cc>
use_keys needs to be True for netmiko to attempt public key
authentication with the specified key_file.
Change-Id: Ic0b2c921af91e667dd95fa174a3e47ddaf37f438
Cardoe reported that networking-baremetal jobs were failing regardless
of the change. Upon investigation, we could see that n-g-s's devstack
plugin was automatically turning on the the test feature flag.
By default, this should be assumed to be false, and as such the
developer has moved to using a setting flag, I'll take a similar
approach with the the ngs devstack plugin so we don't inadvertently
turn on the feature flag for tempest.
see: https://review.opendev.org/c/openstack/ironic/+/940611
Change-Id: I7f80a33382e163478a65e6acb1f478f610f6b488
To enable switch testing with NGS, we need to be able to configure
something *aside* from the OVS support in NGS.
This functionally disables some of the plugin's interactions, so
devstack can be used to help facilitate the complex network
integration testing.
Change-Id: I61d7e80fddac7d046bd461d4487f0e3e233ffd2d
In [1] we finally got rid of the unfinished lib/neutron module and kept
only lib/neutron-legacy. It's renamed to lib/neutron now and it's the
only neutron related module in Devstack.
So this patch removes leftovers related to the old lib/neutron-legacy.
[1] https://review.opendev.org/c/openstack/devstack/+/865014
Change-Id: I1c61f2184bf3485e985b0165ea472816a7a7c097
In initially fixing the multinode key access to the
subnode, we inadvertently now broke ssh access
post-upgrade to the controller local host as it is
attempting to generate and leverage an ssh key locally
which can't really work. So instead, used the provided
keys if present.
Change-Id: I930f034c47bd1d2729ce43cd07c28cc7c1126402
For some reason, the conditional is not matching... and because these
jobs require the change to be merged for it to be tested in grenade,
this is difficult to spot. Hopefully this works...
What was happening as reported in job logs:
configure_generic_switch:151 : '[' -f /opt/stack/.ssh/id_rsa ']'
configure_generic_switch:154 : local cnt=0
configure_generic_switch:155 : local section
Change-Id: I34c33bb5b67561eb90997549317f0fd5333e18db
++ [TRIM]/devstack/plugin.sh:source:26 : enable_python3_package networking-generic-switch
It is no longer necessary to call enable_python3_package().
Removes entry according to the notice the logging output.
Change-Id: Id271c5f3d122b9f7486f675c8995512a8f682913
In multinode, the devstack plugin for networking-generic-switch can't
really work as intended. But, the authorized keys is copied on all
nodes, and zuul puts a consistent key in place, so it doesn't
really need to do what it is doing, but we need to use the stack
user's pre-existing keys to access the remote host.
This will allow Ironic's multinode grenade job to work without
errors about accessing the key file, which is a red herring for
when the connection fails.
Additionally, the underlying ngs code is suseptible to a race on
configuration loading as configuration is loaded separately.
We can't really force it to load the option. We also can't
explicitly add it, so the best thing to do is to wrap it and
rely upon a mock to facilitate the unit test.
Change-Id: Ia8550c124f2ef1cce620a4fb28c35700d34aa027
paramiko complains if the key doesn't start with
`-----BEGIN RSA PRIVATE KEY-----`, the key we generate starts
with `-----BEGIN OPENSSH PRIVATE KEY-----`.
The need for this is only in our multinode grenade job since we
do the upgrade.
Change-Id: I4aa760c013a1b15d3339cf7b2ff5823e45d404f1
Fixed the netmiko exception `Timed-out reading channel, data not available.`
Change ngs config to use `::1` instead of `localhost` so instances can
boot without problems.
Change ironic-tempest-ipa-wholedisk-direct-tinyipa-multinode to voting.
Co-Authored-By: Harald Jensås <hjensas@redhat.com>
Change-Id: If5aa586a41c51a996ed0c27b4edf67a30de939ee
Story: #2007500
Task: #39272
Adds new configuration option to enable netmiko session
logging.
Also disable the login banner for the ovs user.
Change-Id: I20d8d1d184cabaf276c345d7d567caf9eab9613c
Source the plugin so we can directly invoke the ml2 helper methods
without loading neutron-legacy devstack code which we do by using
the q-* service names.
This enables migration to the neutron-* service names to occur.
Change-Id: Ia10839f36a240a503eb4b673a4e39105f1c6abb5
Sets up jobs for Zuulv3, and marks the python3 jobs as n-g-s's
use of tooz seems to be incompatible with python3.
Change-Id: Ic3f4980125a2be8e63a3596c28979b8df015afd5
Required now for the grenade jobs as they have switched
over to using this script since rocky has been released.
Task: #26593
Story: #2003808
Change-Id: Ib7d68d1360e3cdbfdc2ff185a9760461e75ac8c4
doing this currently fails ironic multinode partial grenade job
as restarted 'old' n-cpu picks up new, incompatible dependencies
installed by other, upgraded services.
To somewhat guard against such failures, this patch also adds
ironic's multinode partial grenade job as voting to n-g-s too,
which is fair given ironic depends on n-g-s on upgrade testing.
Change-Id: I0acf834e2ea5b5ac0271762178662eb129b492bd
Closes-Bug: #1733604
This patch set nomulitcell flag when starting nova-compute because
multi-cell rabbit setup is not supported in Grenade.
Closes-Bug: 1700548
Change-Id: I4462b88dde778f316896013d4098936cdeec6b76
If configured in the devstack plugin, will:
- setup 2x extra ports as max allowed session for n-g-s user
- configure tempest plugin to use that number of extra ports to
concurrently run the new test below
- execute a test that cuncurrently run the ngs basic ops test
with the same 2x max sessions
Test is using futurist.ThreadPoll in a single test method to not depend
on concurrency of the test runner itself.
If ngs.port_dlm_concurrency is not set in tempest.conf,
this new test is skipped.
Change-Id: Ib28a4c803fca06bab16c233d98434dc4b3f97a02
Related-Bug: #1674324
This patch allows to set up n-g-s under DevStack to use and enforce DLM
for netmiko connections.
A new devstack variable GENERIC_SWITCH_USER_MAX_SESSIONS is added
(default 0).
If it is non-zero:
- a new system user 'ngs_ovs_manager' with password-less sudo permissions
and appropriate authorized SSH keys will be created by devstack plugin,
and maximum number of sessions for this user will be hard-limited to
the value of GENERIC_SWITCH_USER_MAX_SESSIONS in /etc/security/limits.d/
to simulate a switch with limited number of allowed SSH connections;
- n-g-s will be configured to use this user for SSH connections, and
netmiko OVS switches will be configured with ngs_netmiko_max_sessions
set accordingly.
- n-g-s will be configured to use DLM via etcd3 that is now generally
installed in DevStack by default (and fail if etcd3 is not enabled)
Change-Id: I53971e613c3804de255dda5fc0fb164f9bc335ff
Related-Bug: #1674324
The rase between starting n-cpu and neutron is possible. That will cause
n-cpu to stuck on start. This patch restart n-cpu after neutron has been started.
Change-Id: I171f0209ede85b3405e58f46640ee74c2cddfd22
switch_info key in local_link_information is optional, and ironic-inspector
doesn't set this field by default. Whith this patch it is possible to
pick device based on 'switch_id' key. For this device in ngs config must
have option 'ngs_mac_address' set. If 'switch_id' is set it will take
precedence over switch_info.
Change-Id: I0a03501701d2fd199af1df570e36a6d2a9df1250
We don't want to 'enable_plugin networking-generic-switch' in grenade as
it won't work for multi-node jobs.
Change-Id: I30b2088e8e50f697157dcff2841925b75e3f3672
Initial setup of grenade plugin for networking-generic-switch as we
are going to have ironic + multitenancy job.
Change-Id: Ic880baecc12d13cf1ea7c7810585b63eecd2fc04
When multinode topology is used we need to add information about all
subnode switches to the neutron config on the primary node.
Change-Id: I7187f190d7a8fb39aa151dc2d3174ae5d6d04ca6
After we added networking-generic-switch key, ensure that authorized
file doesn't contain duplicate keys.
Change-Id: Ieb06bea8227bf02411bad03c9b91963be8fc94ea
When authorized_file doesn't contain new-line character at the end,
configure_generic_switch_ssh_keypair() just append new key to the
existed line, as result both keys becomes corrupted. The patch adds
a check for last character in the authorized_key file, if new-line
is missed add it.
Change-Id: I20e84c13db1db65e37b9be35991bd42792be5636
Sometimes neutron opnwsitch agent can't start in time.
As result port can't be bound because of missing agent.
This patch adds wait_for_openwswitch_agent function that
allows to wait for openvswitch agent to start before
executing actual test.
Change-Id: Id99157a1db4f134b45eb68bbfeb1708ba5df9ddc
Closes-Bug: #1572531