Bug 35865 - Connector rejected check
Connector rejected check
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: UMC - System diagnostic
UCS 4.0
Other Linux
: P5 enhancement (vote)
: UCS 4.2-2-errata
Assigned To: Lukas Oyen
Arvid Requate
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-09-10 08:33 CEST by Stefan Gohmann
Modified: 2017-09-20 15:03 CEST (History)
3 users (show)

See Also:
What kind of report is it?: ---
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):
Max CVSS v3 score:
oyen: Patch_Available+


Attachments
35865-diagnostic-s4rejects-420.tar (20.00 KB, application/x-tar)
2017-05-17 18:24 CEST, Lukas Oyen
Details
35865-diagnostic-s4rejects.png (43.49 KB, image/png)
2017-05-17 18:25 CEST, Lukas Oyen
Details
8859: 35865-diagnostic-s4rejects-420.tar (20.00 KB, application/x-tar)
2017-05-18 15:31 CEST, Lukas Oyen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Gohmann univentionstaff 2014-09-10 08:33:36 CEST
We should add a system diagnostic plugin which checks the connector rejects. If rejected objects are available, the module should link to an SDB article which describes how to deal with these objects.
Comment 1 Lukas Oyen univentionstaff 2017-05-17 18:24:34 CEST
Created attachment 8859 [details]
35865-diagnostic-s4rejects-420.tar

The attached patches implement the S4 Connector rejected checked similar to `univention-s4connector-list-rejected`. It does not use this tool directly to avoid string parsing.

If the S4 Connector is not an active service, this simply skips the checks. It might be better to implement a module-level callback `is_disabled()` or something, that lets the `Instance` class filter the active checks.

- If the service is running, but `univention.s4connector.s4` fails to import, a CRITICAL error is raised.
- If any of the necessary UCR variables to instantiate the `s4()` class are not set, a CRITICAL error is raised.
- If any rejects are found a WARNING is raised.
Comment 2 Lukas Oyen univentionstaff 2017-05-17 18:25:04 CEST
Created attachment 8860 [details]
35865-diagnostic-s4rejects.png

Example reject report.
Comment 3 Florian Best univentionstaff 2017-05-18 15:17:59 CEST
1. load_mapping() should use try-finally.
2. an empty '%(configbase)s/s4/ldap/bindpw' file will cause an exception. Better:
s4_ldap_bindpw = fob.read().rstrip()
3. leading white space in visible string: 'label': _(' Univention Support Database
Comment 4 Lukas Oyen univentionstaff 2017-05-18 15:31:48 CEST
Created attachment 8864 [details]
8859: 35865-diagnostic-s4rejects-420.tar

Updated patches.
Comment 5 Lukas Oyen univentionstaff 2017-08-01 16:26:28 CEST
Committed in r81607 - r81608 (advisory r81649).
Comment 6 Arvid Requate univentionstaff 2017-08-24 21:36:25 CEST
Ok, works.
Comment 7 Erik Damrose univentionstaff 2017-09-20 15:03:37 CEST
<http://errata.software-univention.de/ucs/4.2/166.html>