Unskip test_rx_tx_queue_size
Previously, this test was skipped because it depended on a compute host config that we did not set in CI. This patch adds a [whitebox]/rx_queue_size config option to indicate what queue size is configured on the compute hosts, gives it a sensible default in our devstack plugin, makes test_rx_tx_queue_size use its value in the test's assertion, and unskips the test. Woot. (The test itself also needs a small fix in how it accesses the XML attribute). Change-Id: I3cfe53dceb8801754b424ef7be71739a9b11c032
This commit is contained in:
parent
d7aa475dca
commit
62ad86bf4f
|
@ -88,6 +88,7 @@
|
|||
cpu_models: kvm64
|
||||
cpu_model_extra_flags: ssse3
|
||||
virt_type: kvm
|
||||
rx_queue_size: 1024
|
||||
group-vars:
|
||||
subnode:
|
||||
num_hugepages: 2048
|
||||
|
|
|
@ -15,6 +15,7 @@ function configure {
|
|||
iniset $TEMPEST_CONFIG whitebox file_backed_memory_size $WHITEBOX_FILE_BACKED_MEMORY_SIZE
|
||||
iniset $TEMPEST_CONFIG whitebox cpu_model $WHITEBOX_CPU_MODEL
|
||||
iniset $TEMPEST_CONFIG whitebox cpu_model_extra_flags $WHITEBOX_CPU_MODEL_EXTRA_FLAGS
|
||||
iniset $TEMPEST_CONFIG whitebox rx_queue_size $WHITEBOX_RX_QUEUE_SIZE
|
||||
|
||||
iniset $TEMPEST_CONFIG whitebox-nova-compute config_path "$WHITEBOX_NOVA_COMPUTE_CONFIG_PATH"
|
||||
iniset $TEMPEST_CONFIG whitebox-nova-compute stop_command "$WHITEBOX_NOVA_COMPUTE_STOP_COMMAND"
|
||||
|
|
|
@ -5,6 +5,7 @@ SMT_HOSTS=${SMT_HOSTS:-''}
|
|||
WHITEBOX_FILE_BACKED_MEMORY_SIZE=${WHITEBOX_FILE_BACKED_MEMORY_SIZE:-8192}
|
||||
WHITEBOX_CPU_MODEL=${WHITEBOX_CPU_MODEL:-kvm64}
|
||||
WHITEBOX_CPU_MODEL_EXTRA_FLAGS=${WHITEBOX_CPU_MODEL_EXTRA_FLAGS:-ssse3}
|
||||
WHITEBOX_RX_QUEUE_SIZE=${WHITEBOX_RX_QUEUE_SIZE:-1024}
|
||||
|
||||
WHITEBOX_NOVA_COMPUTE_CONFIG_PATH=${WHITEBOX_NOVA_COMPUTE_CONFIG_PATH:-/etc/nova/nova-cpu.conf}
|
||||
WHITEBOX_NOVA_COMPUTE_STOP_COMMAND=${WHITEBOX_NOVA_COMPUTE_STOP_COMMAND:-'systemctl stop devstack@n-cpu'}
|
||||
|
|
|
@ -12,13 +12,13 @@
|
|||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
#
|
||||
|
||||
import testtools
|
||||
|
||||
from oslo_log import log as logging
|
||||
from tempest.common import waiters
|
||||
from tempest import config
|
||||
from tempest.lib.common.utils import data_utils
|
||||
from tempest.lib import decorators
|
||||
|
||||
from whitebox_tempest_plugin.api.compute import base
|
||||
|
||||
|
@ -67,17 +67,12 @@ class RxTxQueueSizeTest(base.BaseWhiteboxComputeTest):
|
|||
cls.server_id, "ACTIVE")
|
||||
cls.addClassResourceCleanup(cls.delete_server, cls.server_id)
|
||||
|
||||
# Required in /etc/nova/nova.conf
|
||||
# [libvirt]
|
||||
# rx_queue_size = 1024
|
||||
# TODO(artom) We either need to refactor this to use the
|
||||
# ServiceManager.config_option context manager, or remove this test
|
||||
# altogether if it adds no value.
|
||||
@decorators.skip_because(bug='2006820', bug_type='storyboard')
|
||||
@testtools.skipUnless(CONF.whitebox.rx_queue_size,
|
||||
'`rx_queue_size` must be set')
|
||||
def test_rx_queue_size(self):
|
||||
domain = self.get_server_xml(self.server_id)
|
||||
driver = domain.find(
|
||||
"devices/interface[@type='bridge']/driver[@name='vhost']")
|
||||
self.assertEqual(
|
||||
driver.attrib('rx_queue_size'), '1024',
|
||||
driver.attrib['rx_queue_size'], str(CONF.whitebox.rx_queue_size),
|
||||
"Can't find interface with the proper rx_queue_size")
|
||||
|
|
|
@ -109,7 +109,11 @@ general_opts = [
|
|||
default=None,
|
||||
help='The expected pmem size allocated to the instance. It requires '
|
||||
'an IEC supported unit of measurement, i.e. Kb, Mb, KB, GB, KiB, '
|
||||
'GiB, etc. Example format 1GB, 4GiB, 100GB. ')
|
||||
'GiB, etc. Example format 1GB, 4GiB, 100GB. '),
|
||||
cfg.IntOpt(
|
||||
'rx_queue_size',
|
||||
help='The queue size set in the [libvirt]/rx_queue_size config option '
|
||||
'on the compute hosts.')
|
||||
]
|
||||
|
||||
nova_compute_group = cfg.OptGroup(
|
||||
|
|
Loading…
Reference in New Issue