Bug 43555

Summary: Mail related services incorrectly reported as stopped in UMC
Product: UCS Reporter: Craig Tosi <craig>
Component: UMC - System servicesAssignee: Daniel Tröder <troeder>
Status: CLOSED FIXED QA Contact: Sönke Schwardt-Krummrich <schwardt>
Severity: normal    
Priority: P5 CC: craig, gohmann, grandjean, schwardt, stoeckigt, troeder
Version: UCS 4.2   
Target Milestone: UCS 4.2-3-errata   
Hardware: amd64   
OS: Linux   
What kind of report is it?: Bug Report What type of bug is this?: 4: Minor Usability: Impairs usability in secondary scenarios
Who will be affected by this bug?: 4: Will affect most installed domains How will those affected feel about the bug?: 2: A Pain – users won’t like this once they notice it
User Pain: 0.183 Enterprise Customer affected?: Yes
School Customer affected?: ISV affected?:
Waiting Support: Flags outvoted (downgraded) after PO Review:
Ticket number: 2017050421000172, 2017081121000724, 2018011821000713 Bug group (optional): External feedback, Troubleshooting
Max CVSS v3 score:

Description Craig Tosi 2017-02-15 23:43:53 CET
When I look at the "System Services" page in the UMC it reports the following services as stopped:-

Amavis
Postgrey
Spamassassin

Yet, at a terminal prompt if I check the service status they report as started.

root@UCS4Master:/var/log# service spamassassin status
[ ok ] spamd is running.
root@UCS4Master:/var/log# service amavis status
[ ok ] amavisd is running.
root@UCS4Master:/var/log# service postgrey status
[ ok ] postgrey is running.

I have only noticed this behaviour following a Zarafa4UCS to Kopano4UCS upgrade, though can't be 100% sure it wasn't apparent before the upgrade.

My instance has the following properties:-

- UCS Version:  4.1-4 errata396 (Vahr)
- UMC Version:  8.0.28-21.926.201611091130
- Kopano Core:  8.1.1-10 (upgraded from Zarafa4UCS 7.2.x)

I created a post in the English UCS - Mail forum:-

http://forum.univention.de/viewtopic.php?f=62&t=6501

Felix Bartels confirmed he was seeing same behaviour on a fresh UCS instance.

Many Thanks
Comment 1 Craig Tosi 2017-04-20 22:11:11 CEST
System has now been upgraded to UCS 4.2 & same behaviour remains. Is it possible to get a response from maintainers as to whether any fix or workaround is in the works for this issue please ?
Comment 3 Daniel Tröder univentionstaff 2017-11-06 12:09:01 CET
Fixed in commit 07161b34 in branch dtroeder/43555_mail_services_detection.
Will add changelog, mrge and build when QA is assigned.
Comment 4 Daniel Tröder univentionstaff 2017-11-08 11:03:51 CET
ii  python-univention-config- 12.0.1-7A~4.2.0.2 all
ii  univention-postgrey       5.0.0-2A~4.2.0.20 all
-------------------------------------------------------------------------
root@ucs26:~# systemctl status amavis.service | grep Active
   Active: active (running) since Mo 2017-11-06 08:37:37 CET; 2 days ago
root@ucs26:~# systemctl status spamassassin.service | grep Active
   Active: active (running) since Mo 2017-11-06 11:29:52 CET; 1 day 22h ago
root@ucs26:~# systemctl status postgrey.service  | grep Active
   Active: active (running) since Mo 2017-11-06 11:04:43 CET; 1 day 22h ago

root@ucs26:~# python -c 'from univention.service_info import ServiceInfo; open("/tmp/before", "wb").write("\n".join(["{}: {}".format(k, v.running) for k, v in ServiceInfo().services.items()]))'

root@ucs26:~# python -c 'import json; from univention.service_info import ServiceInfo; json.dump(ServiceInfo().services, open("/tmp/before.json", "wb"), indent=4)'
-------------------------------------------------------------------------
ii  python-univention-config- 12.0.1-8A~4.2.0.2 all
ii  univention-postgrey       5.0.0-3A~4.2.0.20 all
-------------------------------------------------------------------------
root@ucs26:~# python -c 'from univention.service_info import ServiceInfo; open("/tmp/after", "wb").write("\n".join(["{}: {}".format(k, v.running) for k, v in ServiceInfo().services.items()]))'

root@ucs26:~# python -c 'import json; from univention.service_info import ServiceInfo; json.dump(ServiceInfo().services, open("/tmp/after.json", "wb"), indent=4)'

root@ucs26:~# diff /tmp/before /tmp/after 
8c8
< spamassassin: False
---
> spamassassin: True
17c17
< postgrey: False
---
> postgrey: True
27c27
< amavis: False
---
> amavis: True

root@ucs26:~# diff /tmp/before.json /tmp/after.json 
# no output
-------------------------------------------------------------------------
7034b4ac: fix Mail related services incorrectly reported as stopped
e8a88d52: changelog, yaml
6fc08d68: update advisory

univention-config-registry 12.0.1-8A~4.2.0.201711081048
univention-postgrey 5.0.0-3A~4.2.0.201711081051
Comment 5 Daniel Tröder univentionstaff 2018-01-22 09:14:30 CET
*** Bug 46101 has been marked as a duplicate of this bug. ***
Comment 6 Sönke Schwardt-Krummrich univentionstaff 2018-02-06 18:08:47 CET
OK: code change
OK: functional test
OK: built for UCS 4.2-3 (cherrypicked and rebuilt)
OK: advisory (updated for errata4.2-3)