Actions
Bug #40927
closedmgr/volumes: unable to create subvolumegroups/subvolumes when ceph-mgr is run as non-root user
% Done:
0%
Source:
Development
Tags:
Backport:
nautilus
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
mgr/volumes
Labels (FS):
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
$ ./bin/ceph fs subvolumegroup create a csi Error EINVAL: Traceback (most recent call last): File "/home/rraja/git/ceph/src/pybind/mgr/volumes/fs/subvolume.py", line 53, in _mkdir_p self.fs.stat(subpath) File "cephfs.pyx", line 1071, in cephfs.LibCephFS.stat cephfs.ObjectNotFound: [Errno 2] error in stat: b'volumes' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/rraja/git/ceph/src/pybind/mgr/mgr_module.py", line 889, in _handle_command return self.handle_command(inbuf, cmd) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/module.py", line 188, in handle_command return handler(inbuf, cmd) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/module.py", line 211, in _cmd_fs_subvolumegroup_create pool_layout=cmd.get('pool_layout', None), mode=cmd.get('mode', '755')) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/fs/volume.py", line 361, in conn_wrapper result = func(self, fs_h, **kwargs) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/fs/volume.py", line 501, in create_subvolume_group sv.create_group(spec, pool=pool, mode=self.octal_str_to_decimal_int(mode)) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/fs/subvolume.py", line 206, in create_group self._mkdir_p(path, mode) File "/home/rraja/git/ceph/src/pybind/mgr/volumes/fs/subvolume.py", line 55, in _mkdir_p self.fs.mkdir(subpath, mode) File "cephfs.pyx", line 765, in cephfs.LibCephFS.mkdir cephfs.Error: (13, "error in mkdir 'b'volumes'': error code 13")
Solution: Inside the ceph-mgr's volumes module, have the filesystem client have uid/gid as 0/0 by using `conf_set` interface, before mounting the ceph filesystem and creating directories.
Updated by Patrick Donnelly over 4 years ago
- Description updated (diff)
- Assignee set to Ramana Raja
- Priority changed from Normal to Immediate
- Target version set to v15.0.0
- Source set to Development
- Backport set to nautilus
Also need a ticket to allow setting the uid/gid of the subvolume (Feature).
Updated by Ramana Raja over 4 years ago
- Description updated (diff)
- Assignee deleted (
Ramana Raja) - Priority changed from Immediate to Normal
- Target version deleted (
v15.0.0) - Source deleted (
Development)
Updated by Ramana Raja over 4 years ago
Patrick Donnelly wrote:
Also need a ticket to allow setting the uid/gid of the subvolume (Feature).
Updated by Ramana Raja over 4 years ago
- Priority changed from Normal to Immediate
- Target version set to v15.0.0
Updated by Patrick Donnelly over 4 years ago
- Status changed from New to Fix Under Review
- Start date deleted (
07/24/2019) - Source set to Development
- Pull request ID set to 29355
Updated by Patrick Donnelly over 4 years ago
- Status changed from Fix Under Review to Pending Backport
Updated by Ramana Raja over 4 years ago
- Copied to Backport #41071: nautilus: mgr/volumes: unable to create subvolumegroups/subvolumes when ceph-mgr is run as non-root user added
Updated by Patrick Donnelly over 4 years ago
- Status changed from Pending Backport to Resolved
Actions