break
return done, metrics
- def _setup_fs(self, fs_name):
+ def _setup_fs(self, fs_name, client_id):
fs_a = self.mds_cluster.newfs(name=fs_name)
self.mds_cluster.mds_restart()
fs_a.wait_for_daemons()
# Reconfigure client auth caps
- for mount in self.mounts:
- self.get_ceph_cmd_result(
- 'auth', 'caps', f"client.{mount.client_id}",
- 'mds', 'allow',
- 'mon', 'allow r',
- 'osd', f'allow rw pool={fs_a.get_data_pool_name()}')
+ self.get_ceph_cmd_result(
+ 'auth', 'caps', f"client.{client_id}",
+ 'mds', 'allow',
+ 'mon', 'allow r',
+ 'osd', f'allow rw pool={fs_a.get_data_pool_name()}')
return fs_a
"true", "--yes-i-really-mean-it")
# creating filesystem
- fs_a = self._setup_fs(fs_name="fs1")
+ fs_a = self._setup_fs(fs_name="fs1", client_id=self.mount_a.client_id)
# Mount a client on fs_a
self.mount_a.mount_wait(cephfs_name=fs_a.name)
self.mount_a.create_files()
# creating another filesystem
- fs_b = self._setup_fs(fs_name="fs2")
+ fs_b = self._setup_fs(fs_name="fs2", client_id=self.mount_b.client_id)
# Mount a client on fs_b
self.mount_b.mount_wait(cephfs_name=fs_b.name)
def test_perf_stats_stale_metrics_with_multiple_filesystem(self):
self.mount_a.umount_wait()
self.mount_b.umount_wait()
+ self.fs.delete_all_filesystems()
self.run_ceph_cmd("fs", "flag", "set", "enable_multiple",
"true", "--yes-i-really-mean-it")
# creating filesystem
- fs_b = self._setup_fs(fs_name="fs2")
+ fs_b = self._setup_fs(fs_name="fs2", client_id=self.mount_b.client_id)
# Mount a client on fs_b
self.mount_b.mount_wait(cephfs_name=fs_b.name)
self.mount_b.create_files()
# creating another filesystem
- fs_a = self._setup_fs(fs_name="fs1")
+ fs_a = self._setup_fs(fs_name="fs1", client_id=self.mount_a.client_id)
# Mount a client on fs_a
self.mount_a.mount_wait(cephfs_name=fs_a.name)