]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mgr/dashboard: Allow adding all listeners unders a subsystems 59978/head
authorAfreen Misbah <afreen23.git@gmail.com>
Wed, 25 Sep 2024 11:15:10 +0000 (16:45 +0530)
committerAfreen Misbah <afreen23.git@gmail.com>
Tue, 1 Oct 2024 08:32:58 +0000 (14:02 +0530)
commit287ff3b3603291763b3cd08f9b1543fe60d5f3b9
tree1a48cbb17987b953a2dd0bb8e40f683a424b29c1
parent48d1517b417ae2b21ca2e7fac9e76afc394659dc
mgr/dashboard: Allow adding all listeners unders a subsystems

Issue:

- Currently a user cannot add all listeners under a subsystem
- This results into an error: `Failure adding nqn.2001-07.com.ceph:1725013182540 listener at 10.70.44.140:4420: Gateway's host name must match current host (dhcp47-54)`

Reason:

- The gateway address used while creating listener is random now in nvmeof client
- After checking the gateway logs of each node, its is found that no grpc request recieved for adding listener on the respective node rather going to the node that is chosen by default in nvmeof client.
- But nvmeof backend check that current gateway matches the one with sent in request for adding listener (ref: https://github.com/ceph/ceph-nvmeof/blob/devel/control/grpc.py#L2104)

Fix:

- Using `traddr` from listener API to set the current gateway address
- Since `traddr` gives only IP address, without port therefore extracting full address from `NvmeofGatewaysConfig.get_gateways_config()`
- This ensures correct path usage

Fixes https://tracker.ceph.com/issues/68229
Signed-off-by: Afreen Misbah <afreen23.git@gmail.com>
src/pybind/mgr/dashboard/controllers/nvmeof.py
src/pybind/mgr/dashboard/services/nvmeof_client.py