Bug 42097 - sysvol-sync on other DCs fails when disabled on the master
sysvol-sync on other DCs fails when disabled on the master
Status: CLOSED WORKSFORME
Product: UCS
Classification: Unclassified
Component: Samba4
UCS 4.1
Other Linux
: P1 normal (vote)
: UCS 4.1-3-errata
Assigned To: Arvid Requate
Felix Botner
:
Depends on: 40186 40346
Blocks:
  Show dependency treegraph
 
Reported: 2016-08-23 14:47 CEST by Arvid Requate
Modified: 2016-11-28 14:51 CET (History)
4 users (show)

See Also:
What kind of report is it?: ---
What type of bug is this?: 5: Major Usability: Impairs usability in key scenarios
Who will be affected by this bug?: 2: Will only affect a few installed domains
How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain:
Enterprise Customer affected?:
School Customer affected?: Yes
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional): Troubleshooting
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Arvid Requate univentionstaff 2016-08-23 14:47:04 CEST
Ticket#: 2016082321000445

When the sysvol-sync cron job has been disabled on the master, other DCs may not be able to sync the sysvol from the master. This is the error message in /var/lock/univention/sysvol-sync.log from a DC that is failing to synchronize:

===========================================================================
bash: /var/lock/sysvol-sync-dir: Keine Berechtigung
14:11:32 ERROR [master] Could not aquire remote read lock after 30 seconds.
14:11:32 ERROR [master] Skipping sync to local sysvol!
===========================================================================

This happens because the sysvol-sync script on the master is responsible to set the permissions for /var/lock/sysvol-sync-dir to be writeable for "DC Slave Hosts".


+++ This bug was initially created as a clone of Bug #40346 +++

Please provide a 4.0-4-errata backport.

+++ This bug was initially created as a clone of Bug #40186 +++

There has been at least one report of broken fACLs in sysvol. The primary suspect is sysvol-sync. There might be issues coming from concurrent reads from and writes to /var/lib/samba/sysvol. There are at least threee ideas on how to improve this:

a) Lock the sysvol while operating on it (e.g. man flock)
b) First check with "rsync -au --dry-run" if copying is required at all
c) Generate a consistent sysvol copy for the reading rsync processes
Comment 1 Arvid Requate univentionstaff 2016-08-23 15:00:35 CEST
Looks like a local customer issue because we set the permissions in univention-samba4-sysvol-sync.postinst and the code block in question has been executed as witnessed by the fact the the UCR variable sshd/config/ClientAliveInterval is set to 60 on the master in the customer environment.
Comment 2 Felix Botner univentionstaff 2016-09-08 15:44:12 CEST
OK