Skip to contentSkip to conversation

nvmetcli: store DHCHAP attributes

PATCH Superseded Hannes Reinecke 3 participants 3 messages Jul 13 NVMe

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nvmetcli: store DHCHAP attributes

From: Hannes Reinecke <[email protected]>

The DHCHAP authentication is stored under hosts/, and are starting with 'dhchap_'. So add a 'dhchap' attribute group for the host object to correctly save and restore DHCHAP values.

---
 nvmet/nvme.py | 1 +
 1 file changed, 1 insertion(+)
nvmet/nvme.py +1 -0
index faf1eb2..80d3953 100644
@@ -1013,6 +1013,7 @@ class Host(CFSNode):
         '''
         super(Host, self).__init__()
 
+        self.attr_groups = ['dhchap']
         self.nqn = nqn
         self._path = "%s/hosts/%s" % (self.configfs_dir, nqn)
         self._create_in_cfs(mode)
Signature · 1 line
2.51.0
#1 lore raw

Hi Hannes,

Quoted 16 lines · Hannes Reinecke

From: Hannes Reinecke <[email protected]>

The DHCHAP authentication is stored under hosts/, and are starting with 'dhchap_'. So add a 'dhchap' attribute group for the host object to correctly save and restore DHCHAP values.

---
 nvmet/nvme.py | 1 +
 1 file changed, 1 insertion(+)
nvmet/nvme.py +0 -0
index faf1eb2..80d3953 100644

nvmet/nvme.py class Host(CFSNode): · line 1016

Quoted 4 lines
nvmet/nvme.py +1 -0
@@ -1013,6 +1013,7 @@ class Host(CFSNode):
         '''
         super(Host, self).__init__()
 
+        self.attr_groups = ['dhchap']

Would you mind also extend the test case?

Thanks,
Daniel

#2 lore raw
Quoted 22 lines · Daniel Wagner

Hi Hannes,

Quoted 19 lines · Hannes Reinecke

From: Hannes Reinecke <[email protected]>

The DHCHAP authentication is stored under hosts/, and are starting with 'dhchap_'. So add a 'dhchap' attribute group for the host object to correctly save and restore DHCHAP values.

---
  nvmet/nvme.py | 1 +
  1 file changed, 1 insertion(+)
nvmet/nvme.py +0 -0
index faf1eb2..80d3953 100644
@@ -1013,6 +1013,7 @@ class Host(CFSNode):
          '''
          super(Host, self).__init__()
 
Quoted 4 lines

nvmet/nvme.py class Host(CFSNode): · line 1016

Quoted 1 line
nvmet/nvme.py +1 -0
+        self.attr_groups = ['dhchap']

Would you mind also extend the test case?

Sure. Will be looking into it.

Cheers,

Hannes

Signature · 4 lines
Dr. Hannes Reinecke                  Kernel Storage Architect
[email protected]                                +49 911 74053 688
SUSE Software Solutions GmbH, Frankenstr. 146, 90461 Nürnberg
HRB 36809 (AG Nürnberg), GF: I. Totev, A. McDonald, W. Knoblich