Univention Bugzilla – Bug 54039
Prevent duplicate share definitions (samba and nfs)
Last modified: 2021-11-09 16:14:17 CET
Prevent duplicate share definitions (samba and nfs) Shares with the same configuration create problems for samba and nfs. I think we should check if a duplicate share already exists and throw an error to prevent broken samba and/or nfs configurations Problems for samba: The share configuration in /etc/samba/shares.conf.d/ will be overwritten with the new share. Problems for nfs: The nfs server doesn't start and throws an error "exportfs: duplicated export entries". Duplicate key for samba: univentionShareHost + univentionShareSambaName Duplicate key for nfs: univentionShareHost + univentionSharePath + univentionShareNFSAllowed This needs to be checked for each "univentionShareNFSAllowed" entry separately. This broke the test "90_ucsschool/22_computerroom_module_settings.py", because an earlier test overwrote the "Marktplatz" share.
I think we already have basic logic which prevents to create a share underneath of pathes which are already a share.
(In reply to Florian Best from comment #1) > I think we already have basic logic which prevents to create a share > underneath of pathes which are already a share. I got no error creating two shares with the same path or a subpath. Tested on UCS5 with UCS@school. I created the shares using the umc shares module.
OK, then I confused it with a bug which is not implemented yet. Duplicate of Bug #44495 ?
(In reply to Florian Best from comment #3) > OK, then I confused it with a bug which is not implemented yet. Duplicate of > Bug #44495 ? Thanks! I hadn't searched for "nested". I think we should keep the bugs separate for now. As far as I understand it, bug #44495 is about how ACL are handled for shares on the same path as another share. The solution to that might need some more discussion (should we only warn about it? add some ACL inheritance mechanism? etc). Though I can imagine the solution for bug #44495 including a fix for this as well and this bug becoming a duplicate.