Bug 56187 - Regression: Samba services (smbd, winbind?) not masked properly any longer in UCS 5.0-4
Regression: Samba services (smbd, winbind?) not masked properly any longer in...
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Samba
UCS 5.0
Other Linux
: P5 normal (vote)
: UCS 5.0-4-errata
Assigned To: Arvid Requate
Julia Bremer
:
Depends on: 55907
Blocks:
  Show dependency treegraph
 
Reported: 2023-06-21 17:55 CEST by Arvid Requate
Modified: 2023-06-28 13:52 CEST (History)
3 users (show)

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional): Regression
Max CVSS v3 score:


Attachments
05_dont_install_systemd_service_files.patch (7.18 KB, patch)
2023-06-21 18:04 CEST, Arvid Requate
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Arvid Requate univentionstaff 2023-06-21 17:55:17 CEST
After updating a Samba/AD DC from ucs5.0-3 to ucs5.0-4 the service "smbd" is not masked any longer. This causes problems e.g. during later updates, because samba.postinst then attempts to restart the service (which e.g. currently stalls test updates to 5.2):

Before update:
root@primary20:~# systemctl -p LoadState --value show smbd.service
masked

After update:
root@primary20:~# systemctl -p LoadState --value show smbd.service
loaded

Looks like this change is one of the issues:
https://salsa.debian.org/samba-team/samba/-/commit/49f59ddfbaeb9f53a28b031e432c5e869d4915a0

And subsequently some UCS patches have been adjusted to the removed mask_services too: https://git.knut.univention.de/univention/ucs-patches/-/commit/921c4680978cc7937311ff38b08ed35d86f23cc4#1d03c0b5193249cc0e2c0c23f54289a9d94adad3_70_73
Comment 1 Arvid Requate univentionstaff 2023-06-21 18:04:28 CEST
Created attachment 11075 [details]
05_dont_install_systemd_service_files.patch

The attached version of `05_dont_install_systemd_service_files.patch` now includes a reversed version of the upstream Debian maintainer change.
Comment 2 Arvid Requate univentionstaff 2023-06-21 18:34:42 CEST
e2c7c2ccd | Add service masking dropped upstream
570d4d8df | fixup: adjust context of subsequent patch
0471dd723 | Also add masking for winbind back

2a50017f22 | Advisory
Comment 3 Arvid Requate univentionstaff 2023-06-22 20:17:52 CEST
Just some thoughts about the way forward in UCS 5.2 and Bug 44137:
* If we would want to follow Debian upstream and not mask the services
  then we would probably also need to remove that patch fully
  to install the service files which are generated from
  packaging/systemd/*.service.in
* In the upstream proposed structure the samba.service would only work
  on Samba AD/DCs (univention-samba4) but not on UCS Managed Nodes,
  where smbd.service would need to be used. This would at least
  require adjustment on documentation (and user behavior)
  and some locations in listener modules etc.
* There would not be "one service" to restart all of Samba
  on UCS Managed Nodes (smbd, winbind, nmbd). I'm unsure
  how to implement something like that with systemd units.
Comment 4 Julia Bremer univentionstaff 2023-06-27 09:59:31 CEST
OK: Old behaviour was restored: smbd is masked while updating samba
OK: yaml
Verified