nvmetcli: ANA configuration support
PATCH 1/1 nvmetcli: ANA configuration support
Add support for ANA configuration.
--- nvmet/__init__.py | 2 +- nvmet/nvme.py | 99 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ nvmetcli | 61 +++++++++++++++++++++++++++++++++- 3 files changed, 160 insertions(+), 2 deletions(-)
nvmet/__init__.py +1 -1
@@ -1 +1 @@ -from .nvme import Root, Subsystem, Namespace, Port, Host, Referral +from .nvme import Root, Subsystem, Namespace, Port, Host, Referral, ANAGroup
nvmet/nvme.py +99 -0
145 lines not on this page · raw message
nvmetcli +60 -1
88 lines not on this page · raw message
Signature · 1 line
2.13.7
Christoph Hellwig
maintainerPATCH 1/1 nvmetcli: ANA configuration support
I just wanted to apply this in preparation of a new nvmetcli release once Linux 4.19 is released with ANA support, but the code does not seem to work well on kernel without multipath support. E.g.:
Traceback (most recent call last):
File "./nvmetcli", line 735, in <module>
main()
File "./nvmetcli", line 717, in main
funcs[sys.argv[1]](savefile)
File "./nvmetcli", line 684, in clear
nvme.Root().clear_existing()
File "/root/nvmetcli/nvmet/nvme.py", line 315, in clear_existing
p.delete()
File "/root/nvmetcli/nvmet/nvme.py", line 676, in delete
a.delete() File "/root/nvmetcli/nvmet/nvme.py", line 200, in delete
os.rmdir(self.path)
PermissionError: [Errno 1] Operation not permitted: '/sys/kernel/config/nvmet/ports/2/ana_groups/1'
The new ANA code will probably need similar exception handling as the inline_data_size attribute.
PATCH 1/1 nvmetcli: ANA configuration support
Quoted 15 lines · Christoph Hellwig
I just wanted to apply this in preparation of a new nvmetcli release once Linux 4.19 is released with ANA support, but the code does not seem to work well on kernel without multipath support. E.g.:
Traceback (most recent call last):
File "./nvmetcli", line 735, in <module>main() File "./nvmetcli", line 717, in main funcs[sys.argv[1]](savefile) File "./nvmetcli", line 684, in clear nvme.Root().clear_existing() File "/root/nvmetcli/nvmet/nvme.py", line 315, in clear_existing p.delete() File "/root/nvmetcli/nvmet/nvme.py", line 676, in delete a.delete()
Quoted 7 lines
File "
/root/nvmetcli/nvmet/nvme.py", line 200, in delete
os.rmdir(self.path)
PermissionError: [Errno 1] Operation not permitted: '/sys/kernel/config/nvmet/ports/2/ana_groups/1'The new ANA code will probably need similar exception handling as the
inline_data_sizeattribute.
Okay, will be fixing it up.
Cheers,
Hannes
Christoph Hellwig
maintainerPATCH 1/1 nvmetcli: ANA configuration support
Quoted 4 lines · Hannes Reinecke
Quoted 3 lines
The new ANA code will probably need similar exception handling as the
inline_data_sizeattribute.Okay, will be fixing it up.
Any chance to get a fixed version in the next days? I'd like to cut a new release with it not too long after the 4.19 release so that people can easily use the ANA code.
Christoph Hellwig
maintainerPATCH 1/1 nvmetcli: ANA configuration support
Quoted 9 lines · Christoph Hellwig
Quoted 4 lines · Hannes Reinecke
Quoted 3 lines
The new ANA code will probably need similar exception handling as the
inline_data_sizeattribute.Okay, will be fixing it up.
Any chance to get a fixed version in the next days? I'd like to cut a new release with it not too long after the 4.19 release so that people can easily use the ANA code.
Do you still plan to resubmit this code?
PATCH 1/1 nvmetcli: ANA configuration support
Quoted 5 lines · Christoph Hellwig
Quoted 4 lines · Christoph Hellwig
Quoted 3 lines · Hannes Reinecke
Quoted 3 lines
The new ANA code will probably need similar exception handling as the
inline_data_sizeattribute.
Quoted 8 lines
Quoted 5 lines
Quoted 1 line
Okay, will be fixing it up.
Any chance to get a fixed version in the next days? I'd like to cut a new release with it not too long after the 4.19 release so that people can easily use the ANA code.
Do you still plan to resubmit this code?
Yes, I'm just testing the changes.
Should be ready by the end of the week.
Cheers,
Hannes