Merge "Fixed Share server migration test related to CIFS."
diff --git a/manila_tempest_tests/config.py b/manila_tempest_tests/config.py
index 0cd07d3..4d36944 100644
--- a/manila_tempest_tests/config.py
+++ b/manila_tempest_tests/config.py
@@ -336,4 +336,17 @@
"attempt to create an IPv6 subnet on the project network "
"they create for ping and SSH to the client test VM "
"where data path testing is performed."),
+ cfg.StrOpt("dd_input_file",
+ default="/dev/zero",
+ help="The input file (if) in the dd command specifies the "
+ "source of data that dd will read and process, which can "
+ "be a device, a regular file, or even standard input "
+ "(stdin). dd copies, transforms, or performs actions on "
+ "this data based on provided options and then writes it "
+ "to an output file or device (of). When using /dev/zero "
+ "in storage systems with default compression, although "
+ "it generates highly compressible null bytes (zeros), "
+ "writing data from /dev/zero might not yield significant "
+ "space savings as these systems are already optimized for "
+ "efficient compression."),
]
diff --git a/manila_tempest_tests/tests/api/test_shares_actions_negative.py b/manila_tempest_tests/tests/api/test_shares_actions_negative.py
index 977d9a1..da85f2e 100644
--- a/manila_tempest_tests/tests/api/test_shares_actions_negative.py
+++ b/manila_tempest_tests/tests/api/test_shares_actions_negative.py
@@ -288,7 +288,6 @@
self.assertEqual(0, len(shares))
- @decorators.skip_because(bug='1914363')
@decorators.idempotent_id('e8f857f1-ec32-4f81-9e09-26065891dc93')
@tc.attr(base.TAG_NEGATIVE, base.TAG_API_WITH_BACKEND)
def test_get_share_from_other_project(self):
diff --git a/manila_tempest_tests/tests/rbac/test_shares.py b/manila_tempest_tests/tests/rbac/test_shares.py
index 2ca3c92..b5ea7d9 100644
--- a/manila_tempest_tests/tests/rbac/test_shares.py
+++ b/manila_tempest_tests/tests/rbac/test_shares.py
@@ -420,7 +420,7 @@
alt_share = self.create_share(
self.alt_project_share_v2_client, self.share_type['id'])
self.do_request(
- 'reset_state', expected_status=lib_exc.NotFound,
+ 'reset_state', expected_status=lib_exc.Forbidden,
s_id=alt_share['id'], status="error")
@decorators.idempotent_id('56a07567-d0a9-460a-9267-fcd82306a371')
@@ -465,7 +465,7 @@
alt_share = self.create_share(
self.alt_project_share_v2_client, self.share_type['id'])
self.do_request(
- 'set_metadata', expected_status=lib_exc.Forbidden,
+ 'set_metadata', expected_status=lib_exc.NotFound,
resource_id=alt_share['id'], metadata={'key': 'value'})
@decorators.idempotent_id('a69a2b85-3374-4621-83a9-89937ddb520b')
@@ -482,7 +482,7 @@
self.alt_project_share_v2_client, self.share_type['id'],
metadata=metadata)
self.do_request(
- 'get_metadata', expected_status=lib_exc.Forbidden,
+ 'get_metadata', expected_status=lib_exc.NotFound,
resource_id=alt_share['id'])
@decorators.idempotent_id('bea5518a-338e-494d-9034-1d03658ed58b')
@@ -498,7 +498,7 @@
self.alt_project_share_v2_client, self.share_type['id'],
metadata={'key': 'value'})
self.do_request(
- 'delete_metadata', expected_status=lib_exc.Forbidden,
+ 'delete_metadata', expected_status=lib_exc.NotFound,
resource_id=alt_share['id'], key='key')
@@ -551,7 +551,7 @@
alt_share = self.create_share(
self.alt_project_share_v2_client, self.share_type['id'])
self.do_request(
- 'delete_share', expected_status=lib_exc.NotFound,
+ 'delete_share', expected_status=lib_exc.Forbidden,
share_id=alt_share['id'])
@decorators.idempotent_id('cb040955-5897-409f-aea0-84b6ae16b77e')
@@ -596,7 +596,7 @@
self.alt_project_share_v2_client, self.share_type['id'],
size=CONF.share.share_size + 1)
self.do_request(
- 'shrink_share', expected_status=lib_exc.NotFound,
+ 'shrink_share', expected_status=lib_exc.Forbidden,
share_id=alt_share['id'], new_size=CONF.share.share_size)
@decorators.idempotent_id('0b57aedb-6b68-498f-814e-173c47e6c307')
@@ -612,7 +612,7 @@
alt_share = self.create_share(
self.alt_project_share_v2_client, self.share_type['id'])
self.do_request(
- 'extend_share', expected_status=lib_exc.NotFound,
+ 'extend_share', expected_status=lib_exc.Forbidden,
share_id=alt_share['id'], new_size=CONF.share.share_size + 1)
@decorators.idempotent_id('3def3f4e-33fc-4726-8818-6cffbc2cab51')
diff --git a/manila_tempest_tests/tests/rbac/test_snapshots.py b/manila_tempest_tests/tests/rbac/test_snapshots.py
index 810ba9b..1978415 100644
--- a/manila_tempest_tests/tests/rbac/test_snapshots.py
+++ b/manila_tempest_tests/tests/rbac/test_snapshots.py
@@ -497,7 +497,7 @@
alt_snap = self.create_snapshot(
self.alt_project_share_v2_client, self.alt_share['id'])
self.do_request(
- 'delete_snapshot', expected_status=lib_exc.NotFound,
+ 'delete_snapshot', expected_status=lib_exc.Forbidden,
snap_id=alt_snap['id'])
@decorators.idempotent_id('ed0af390-e3d0-432b-9147-c0d569181b92')
@@ -517,7 +517,7 @@
alt_snap = self.create_snapshot(
self.alt_project_share_v2_client, self.alt_share['id'])
self.do_request(
- 'rename_snapshot', expected_status=lib_exc.NotFound,
+ 'rename_snapshot', expected_status=lib_exc.Forbidden,
snapshot_id=alt_snap['id'], name=name)
@decorators.idempotent_id('b8c9c9a4-3b2a-4b1c-80d8-2ec87d708111')
diff --git a/manila_tempest_tests/tests/scenario/manager_share.py b/manila_tempest_tests/tests/scenario/manager_share.py
index 6d6efc0..3e06323 100644
--- a/manila_tempest_tests/tests/scenario/manager_share.py
+++ b/manila_tempest_tests/tests/scenario/manager_share.py
@@ -229,8 +229,7 @@
def write_data_to_mounted_share_using_dd(self, remote_client,
output_file,
block_size,
- block_count,
- input_file='/dev/zero'):
+ block_count):
"""Writes data to mounted share using dd command
Example Usage for writing 512Mb to a file on /mnt/
@@ -243,13 +242,12 @@
:param block_size: The size of an individual block in bytes
:param block_count: The number of blocks to write
:param output_file: Path to the file to be written
- :param input_file: Path to the file to read from
"""
block_count = int(block_count)
remote_client.exec_command(
- "sudo sh -c \"dd bs={} count={} if={} of={} conv=fsync"
- " iflag=fullblock\""
- .format(block_size, block_count, input_file, output_file))
+ "sudo sh -c \"dd bs={} count={} if={} of={} iflag=fullblock\""
+ .format(block_size, block_count, CONF.share.dd_input_file,
+ output_file))
def read_data_from_mounted_share(self,
remote_client,
diff --git a/manila_tempest_tests/tests/scenario/test_share_extend.py b/manila_tempest_tests/tests/scenario/test_share_extend.py
index 595ddd4..450d2d4 100644
--- a/manila_tempest_tests/tests/scenario/test_share_extend.py
+++ b/manila_tempest_tests/tests/scenario/test_share_extend.py
@@ -76,8 +76,7 @@
.format(three_quarter_blocks))
self.write_data_to_mounted_share_using_dd(remote_client,
'/mnt/t1', '64M',
- three_quarter_blocks,
- '/dev/urandom')
+ three_quarter_blocks)
ls_result = remote_client.exec_command("sudo ls -lAh /mnt/")
LOG.debug(ls_result)
@@ -86,8 +85,7 @@
self.assertRaises(
exceptions.SSHExecCommandFailed,
self.write_data_to_mounted_share_using_dd,
- remote_client, '/mnt/t2', '64M', over_one_quarter_blocks,
- '/dev/urandom')
+ remote_client, '/mnt/t2', '64M', over_one_quarter_blocks)
ls_result = remote_client.exec_command("sudo ls -lAh /mnt/")
LOG.debug(ls_result)
@@ -129,8 +127,7 @@
self.write_data_to_mounted_share_using_dd(remote_client,
output_file,
block_size,
- block_count,
- '/dev/urandom')
+ block_count)
except exceptions.SSHExecCommandFailed as e:
if 'stale file handle' in str(e).lower():
LOG.warning("Client was disconnected during extend process")
@@ -139,8 +136,7 @@
self.write_data_to_mounted_share_using_dd(remote_client,
output_file,
block_size,
- block_count,
- '/dev/urandom')
+ block_count)
else:
raise
diff --git a/manila_tempest_tests/tests/scenario/test_share_manage_unmanage.py b/manila_tempest_tests/tests/scenario/test_share_manage_unmanage.py
index ef2a6af..bbf5ba6 100644
--- a/manila_tempest_tests/tests/scenario/test_share_manage_unmanage.py
+++ b/manila_tempest_tests/tests/scenario/test_share_manage_unmanage.py
@@ -105,7 +105,7 @@
LOG.debug('Step 6b - writing 640mb')
self.write_data_to_mounted_share_using_dd(remote_client,
'/mnt/t1', 1024,
- 2048, '/dev/zero')
+ 2048)
ls_result = remote_client.exec_command("sudo ls -lA /mnt/")
LOG.debug(ls_result)
diff --git a/manila_tempest_tests/tests/scenario/test_share_shrink.py b/manila_tempest_tests/tests/scenario/test_share_shrink.py
index a4e59e8..fab7e0a 100644
--- a/manila_tempest_tests/tests/scenario/test_share_shrink.py
+++ b/manila_tempest_tests/tests/scenario/test_share_shrink.py
@@ -79,7 +79,7 @@
LOG.debug('Step 6 - writing {} * 64MB blocks'.format(blocks))
self.write_data_to_mounted_share_using_dd(remote_client,
'/mnt/t1', '64M',
- blocks, '/dev/urandom')
+ blocks)
ls_result = remote_client.exec_command("sudo ls -lAh /mnt/")
LOG.debug(ls_result)
@@ -120,7 +120,7 @@
self.assertRaises(
exceptions.SSHExecCommandFailed,
self.write_data_to_mounted_share_using_dd,
- remote_client, '/mnt/t1', '64M', blocks, '/dev/urandom')
+ remote_client, '/mnt/t1', '64M', blocks)
LOG.debug('Step 12 - unmount')
self.unmount_share(remote_client)
diff --git a/zuul.d/manila-tempest-jobs.yaml b/zuul.d/manila-tempest-jobs.yaml
index 3a48147..c23801e 100644
--- a/zuul.d/manila-tempest-jobs.yaml
+++ b/zuul.d/manila-tempest-jobs.yaml
@@ -157,6 +157,7 @@
backend_names: LONDON,PARIS
multi_backend: true
image_password: manila
+ dd_input_file: /dev/urandom
- job:
name: manila-tempest-plugin-zfsonlinux
@@ -177,7 +178,6 @@
- openstack/neutron-dynamic-routing
vars:
tempest_test_regex: '(^manila_tempest_tests.tests)(?=.*\[.*\bbackend\b.*\])'
- tempest_exclude_regex: "(^manila_tempest_tests.tests.scenario.*)"
devstack_services: &devstack-with-ovs
# NOTE(gouthamr): LP#1940324 prevents bgp usage with OVN, disable OVN
br-ex-tcpdump: false
@@ -232,25 +232,21 @@
multi_backend: true
image_password: manila
-# NOTE(carloss): Nova bumped libvirt to a version available only on Ubuntu
-# Jammy. We are then forced to migrate this job to use Jammy. When LP Bug
-#1998489 is fixed, we will be able to unify the job above with this.
- job:
name: manila-tempest-plugin-lvm
description: |
- Test LVM multibackend (DHSS=False) in a IPv4 environment.
- branches:
- regex: ^stable/(2023.1|zed|yoga|xena|wallaby|victoria|ussuri)$
- negate: true
+ Test LVM multibackend (DHSS=False) in a 4+6 (dual-stack) devstack
+ environment with IPv6 control plane endpoints.
+ branches: *ubuntu_jammy_test_image_branches
parent: manila-tempest-plugin-lvm-base
vars:
+ # TODO(gouthamr): some tests are disabled due to bugs
+ # IPv6 Tests: https://bugs.launchpad.net/manila/+bug/1998489
+ # drop these overrides once we address that bug.
+ tempest_exclude_regex: '(^manila_tempest_tests.tests.scenario.*IPv6.*)'
devstack_localrc:
MANILA_SETUP_IPV6: false
- devstack_local_conf:
- test-config:
- $TEMPEST_CONFIG:
- share:
- run_ipv6_tests: false
+ NEUTRON_CREATE_INITIAL_NETWORKS: true
- job:
name: manila-tempest-plugin-container
@@ -422,7 +418,6 @@
tempest_exclude_regex: '(^manila_tempest_tests.tests.scenario.*ceph_fuse.*)'
devstack_localrc:
ENABLE_CEPH_NOVA: false
- CONTAINER_IMAGE: 'quay.io/ceph/ceph:v17.2.5'
CEPHADM_DEPLOY: true
CEPHADM_DEV_OSD: true
TARGET_DEV_OSD_DIR: /opt/stack
@@ -495,10 +490,7 @@
vars:
# TODO(gouthamr): some tests are disabled due to bugs
# IPv6 Tests: https://bugs.launchpad.net/manila/+bug/1998489
- # snapshot clone fs sync: https://bugs.launchpad.net/manila/+bug/1989273
- tempest_exclude_regex: "\
- (^manila_tempest_tests.tests.scenario.*IPv6.*)|\
- (^manila_tempest_tests.tests.scenario.test_share_basic_ops.TestShareBasicOpsNFS.test_write_data_to_share_created_from_snapshot)"
+ tempest_exclude_regex: "(^manila_tempest_tests.tests.scenario.*IPv6.*)"
devstack_localrc:
MANILA_OPTGROUP_cephfsnfs_cephfs_ganesha_server_ip: "{{ hostvars[inventory_hostname]['nodepool']['private_ipv4'] }}"
CEPH_RELEASE: "quincy"
@@ -558,10 +550,7 @@
tempest_concurrency: 2
# TODO(gouthamr): some tests are disabled due to bugs
# IPv6 Tests: https://bugs.launchpad.net/manila/+bug/1998489
- # snapshot clone fs sync: https://bugs.launchpad.net/manila/+bug/1989273
- tempest_exclude_regex: "\
- (^manila_tempest_tests.tests.scenario.*IPv6.*)|\
- (^manila_tempest_tests.tests.scenario.test_share_basic_ops.TestShareBasicOpsNFS.test_write_data_to_share_created_from_snapshot)"
+ tempest_exclude_regex: "(^manila_tempest_tests.tests.scenario.*IPv6.*)"
devstack_localrc:
MYSQL_REDUCE_MEMORY: True
CEPHADM_DEPLOY: True