Skip to content

Commit 88a553d

Browse files
committed
Change the default in the devel conf file to cluster_connections instead of bdevs_per_cluster.
Fixes: #1685 Signed-off-by: Gil Bregman <[email protected]>
1 parent 93879ed commit 88a553d

File tree

5 files changed

+11
-10
lines changed

5 files changed

+11
-10
lines changed

ceph-nvmeof.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,11 +83,11 @@ client_cert = ./client.crt
8383
[spdk]
8484
# Support multiple cluster allocation strategies
8585
# Legacy strategy, per ANA grp, max bdevs_per_cluster
86-
bdevs_per_cluster = 32
86+
# bdevs_per_cluster = 32
8787
# Flat bdevs per cluster, ignore ANA grp id
8888
# flat_bdevs_per_cluster = 32
8989
# Cluster pool
90-
# cluster_connections = 32
90+
cluster_connections = 32
9191
tgt_path = /usr/local/bin/nvmf_tgt
9292
#rpc_socket_dir = /var/tmp/
9393
#rpc_socket_name = spdk.sock

tests/ceph-nvmeof.no-huge.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ server_cert = ./server.crt
7171
client_cert = ./client.crt
7272

7373
[spdk]
74-
bdevs_per_cluster = 32
74+
cluster_connections = 32
7575
mem_size=4096
7676
tgt_path = /usr/local/bin/nvmf_tgt
7777
#rpc_socket_dir = /var/tmp/

tests/ceph-nvmeof.tls.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ server_cert = /etc/ceph/server.crt
7070
client_cert = /etc/ceph/client.crt
7171

7272
[spdk]
73-
bdevs_per_cluster = 32
73+
cluster_connections = 32
7474
tgt_path = /usr/local/bin/nvmf_tgt
7575
#rpc_socket_dir = /var/tmp/
7676
#rpc_socket_name = spdk.sock

tests/test_cli.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -518,8 +518,8 @@ def test_add_namespace(self, caplog, gateway):
518518
"--rbd-image", image2, "--uuid", uuid, "--size", "16MB", "--rbd-create-image",
519519
"--load-balancing-group", anagrpid, "--force"])
520520
assert f"Adding namespace 1 to {subsystem}: Successful" in caplog.text
521-
assert f"Allocated cluster name='cluster_context_{anagrpid}_0'" in caplog.text
522-
assert f"get_cluster cluster_name='cluster_context_{anagrpid}_0'" in caplog.text
521+
assert f"Allocated cluster name='cluster_{anagrpid}'" in caplog.text
522+
assert "get_cluster cluster_name" not in caplog.text
523523
assert "no_auto_visible: False" in caplog.text
524524
caplog.clear()
525525
cli(["namespace", "add", "--subsystem", subsystem, "--rbd-pool", pool,
@@ -1699,7 +1699,7 @@ def test_list_namespaces_all_subsystems(self, caplog):
16991699
cli(["--verbose", "namespace", "list", "--nsid", "1"])
17001700
assert "Cluster" in caplog.text
17011701
assert "(Configured)" in caplog.text
1702-
assert "cluster_context_1_0" in caplog.text
1702+
assert "cluster_1" in caplog.text
17031703
assert f"{image2}" in caplog.text
17041704
assert f"{image15}" in caplog.text
17051705
assert "1 (1)" in caplog.text
@@ -1926,7 +1926,8 @@ def test_add_namespace_ana(self, caplog, gateway):
19261926
cli(["namespace", "add", "--subsystem", subsystem, "--rbd-pool", pool,
19271927
"--rbd-image", image, "--load-balancing-group", anagrpid, "--force", "--nsid", "10"])
19281928
assert f"Adding namespace 10 to {subsystem}: Successful" in caplog.text
1929-
assert f"get_cluster cluster_name='cluster_context_{anagrpid}_0'" in caplog.text
1929+
assert f"Allocated cluster name='cluster_{anagrpid}'" in caplog.text
1930+
assert f"cluster_name cluster_{anagrpid}\n" in caplog.text
19301931
caplog.clear()
19311932
cli(["--format", "json", "namespace", "list", "--subsystem", subsystem, "--nsid", "10"])
19321933
assert f'"load_balancing_group": {anagrpid}' in caplog.text

tests/test_cli_change_lb.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ def test_change_namespace_lb_group(caplog, two_gateways):
186186
"--load-balancing-group", anagrpid, "--force"])
187187
time.sleep(15)
188188
assert f"Adding namespace 1 to {subsystem}: Successful" in caplog.text
189-
assert f"get_cluster cluster_name='cluster_context_{anagrpid}_0'" in caplog.text
189+
assert f"Allocated cluster name='cluster_{anagrpid}'" in caplog.text
190190
assert f"Received request to add namespace to {subsystem}, ana group {anagrpid}, " \
191191
f"no_auto_visible: False, disable_auto_resize: False, " \
192192
f"read_only: False, " \
@@ -276,7 +276,7 @@ def test_change_namespace_lb_group(caplog, two_gateways):
276276
"--load-balancing-group", anagrpid2, "--force"])
277277
time.sleep(15)
278278
assert f"Adding namespace 2 to {subsystem}: Successful" in caplog.text
279-
assert f"get_cluster cluster_name='cluster_context_{anagrpid2}_0'" in caplog.text
279+
assert f"Allocated cluster name='cluster_{anagrpid2}'" in caplog.text
280280
assert f"Received request to add namespace to {subsystem}, ana group {anagrpid2}, " \
281281
f"no_auto_visible: False, disable_auto_resize: False, " \
282282
f"read_only: False, " \

0 commit comments

Comments
 (0)