Bug 43932 - Migrate ucs-overview entries to new 4.2 portal entries
Migrate ucs-overview entries to new 4.2 portal entries
Product: UCS
Classification: Unclassified
Component: Portal
UCS 4.2
Other Linux
: P5 normal (vote)
: UCS 4.2
Assigned To: Stefan Gohmann
Erik Damrose
: interim-4
Depends on: 42231
Blocks: 42233 43579
  Show dependency treegraph
Reported: 2017-03-17 15:22 CET by Florian Best
Modified: 2017-04-04 18:29 CEST (History)
5 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):
Max CVSS v3 score:

join.log (172.89 KB, text/plain)
2017-03-17 15:25 CET, Florian Best
updater.log (2.95 MB, text/plain)
2017-03-17 15:26 CET, Florian Best

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Best univentionstaff 2017-03-17 15:22:35 CET
After upgrading to UCS 4.2 no portal entries exists. During the upgrade to UCS 4.2 I see in various places:

Unsetting ucs/web/overview/entries/admin/umc/label
Unsetting ucs/web/overview/entries/admin/umc/label/de
Unsetting ucs/web/overview/entries/admin/umc/description
Unsetting ucs/web/overview/entries/admin/umc/description/de
Script: /etc/univention/templates/scripts/ucs-school-ucr-l10n-fr
File: /var/www/univention/meta.json
Module: create_portal_entries
Traceback (most recent call last):
  File "/usr/share/univention-directory-manager-tools/univention-cli-server", line 222, in doit
    output = univention.admincli.admin.doit(arglist)
  File "/usr/lib/pymodules/python2.7/univention/admincli/admin.py", line 406, in doit
    out = _doit(arglist)
  File "/usr/lib/pymodules/python2.7/univention/admincli/admin.py", line 534, in _doit
    co = univention.admin.config.config(configRegistry['ldap/master'])
  File "/usr/lib/pymodules/python2.7/univention/admin/config.py", line 40, in __init__
    base = univention.admin.uldap.getBaseDN(host)
  File "/usr/lib/pymodules/python2.7/univention/admin/uldap.py", line 136, in getBaseDN
    result = lo.search_s('', ldap.SCOPE_BASE, 'objectClass=*', ['NamingContexts'])
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 559, in search_s
    return self.search_ext_s(base,scope,filterstr,attrlist,attrsonly,None,None,timeout=self.timeout)
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 920, in search_ext_s
    return self._apply_method_s(SimpleLDAPObject.search_ext_s,*args,**kwargs)
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 867, in _apply_method_s
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 832, in reconnect
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 805, in _apply_last_bind
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 214, in simple_bind_s
    msgid = self.simple_bind(who,cred,serverctrls,clientctrls)
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 208, in simple_bind
    return self._ldap_call(self._l.simple_bind,who,cred,RequestControlTuples(serverctrls),RequestControlTuples(clientctrls))
  File "/usr/lib/python2.7/dist-packages/ldap/ldapobject.py", line 106, in _ldap_call
    result = func(*args,**kwargs)
SERVER_DOWN: {'desc': "Can't contact LDAP server"}

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

We will need to migrate UCR variable entries for ucs-overview page to new UCS 4.2 portal entries.
Comment 1 Stefan Gohmann univentionstaff 2017-03-17 15:25:12 CET
Please attach join.log and updater.log.
Comment 2 Florian Best univentionstaff 2017-03-17 15:25:58 CET
Created attachment 8573 [details]
Comment 3 Florian Best univentionstaff 2017-03-17 15:26:18 CET
Created attachment 8574 [details]
Comment 4 Stefan Gohmann univentionstaff 2017-03-19 13:08:51 CET
With the fixes for Bug #43887, the entries are created after the upgrade.
Comment 5 Stefan Gohmann univentionstaff 2017-03-20 08:50:35 CET
* create_portal_entries.py: Write an error message if the LDAP server
  is not available (Bug #43932)

* 35univention-portal.inst: Check if LDAP on DC master is available
  and abort if not. This prevents error messages from the updater.log
  (Bug #43932)

r77951 + r77952:
 Added Bug #43932 to existing entry

The main cause has been fixed with Bug #43887, I've only removed the traceback from the updater log to prevent support questions.

I've created Bug #43975 for a more general approach.
Comment 6 Erik Damrose univentionstaff 2017-03-20 17:29:18 CET
OK: exit joinscript early if LDAP server could not be contacted
OK: changelog
OK: In my update test the overview variables were migrated
Comment 7 Stefan Gohmann univentionstaff 2017-04-04 18:29:14 CEST
UCS 4.2 has been released:

If this error occurs again, please use "Clone This Bug".