Univention Bugzilla – Bug 31389
Exam user accounts cannot be created
Last modified: 2013-06-07 21:39:51 CEST
Not quite sure why I cannot create exam user accounts... > 17.05.13 12:16:18.733 MODULE ( INFO ) : Executing ['schoolexam-master/create-exam-user'] > 17.05.13 12:16:18.741 ADMIN ( INFO ) : LOCK acquireUnique scope = domain > 17.05.13 12:16:18.751 ADMIN ( INFO ) : ALLOCATE return exam-marlene7 > 17.05.13 12:16:18.751 ADMIN ( INFO ) : ALLOCATE: Start allocation for type = uidNumber > 17.05.13 12:16:18.751 ADMIN ( INFO ) : ALLOCATE: Start ID = ['2932'] > 17.05.13 12:16:18.751 ADMIN ( INFO ) : ALLOCATE: Set Start ID 2933 > 17.05.13 12:16:18.751 ADMIN ( INFO ) : ALLOCATE: Lock ID 2933 > 17.05.13 12:16:18.761 ADMIN ( INFO ) : ALLOCATE: searchfor uidNumber=2933 > 17.05.13 12:16:18.762 ADMIN ( INFO ) : ALLOCATE: Return ID 2933 > 17.05.13 12:16:18.763 ADMIN ( INFO ) : ALLOCATE: request user sid. SID = S-1-5-21-1546627211-3112513479-1411413579-6866 > 17.05.13 12:16:18.763 ADMIN ( INFO ) : LOCK acquireUnique scope = base > 17.05.13 12:16:18.763 ADMIN ( INFO ) : LOCK univention.admin.locking.lock scope = base > 17.05.13 12:16:18.785 MODULE ( PROCESS ) : The command has failed: ERROR: Creation of exam user account failed > Traceback (most recent call last): > File "/usr/lib/pymodules/python2.6/univention/management/console/modules/schoolexam-master/__init__.py", line 209, in create_exam_user > raise UMC_CommandError( message ) > UMC_CommandError: Failed to allocate userSid > Traceback (most recent call last): > File "/usr/lib/pymodules/python2.6/univention/management/console/modules/schoolexam-master/__init__.py", line 206, in create_exam_user > userSid = univention.admin.allocators.requestUserSid(ldap_admin_write, ldap_position, uidNum) > File "/usr/lib/pymodules/python2.6/univention/admin/allocators.py", line 75, in requestUserSid > return request(lo, position, 'sid', sid) > File "/usr/lib/pymodules/python2.6/univention/admin/allocators.py", line 166, in request > return acquireUnique(lo, position, type, value, _type2attr[type], scope = _type2scope[type]) > File "/usr/lib/pymodules/python2.6/univention/admin/allocators.py", line 155, in acquireUnique > univention.admin.locking.lock(lo, position, type, value, scope=scope) > File "/usr/lib/pymodules/python2.6/univention/admin/locking.py", line 93, in lock > raise univention.admin.uexceptions.noLock > noLock >
The SID S-1-5-21-1546627211-3112513479-1411413579-6866 seems to be already in use. univention-ldapsearch -x \ sambaSID=S-1-5-21-1546627211-3112513479-1411413579-6866
The rid allocation code in schoolexam-master bailed out if rid allocation according to the default UDM algorithm failed. This was triggered by bug 31416. The module now employs the retry logic of users/user.
22.05.13 17:30:03.575 MODULE ( PROCESS ) : Das Kommando ist fehlgeschlagen: FEHLER: Anlegen des Klassenarbeitsbenutzerkontos fehlgeschlagen Traceback (most recent call last): File "/usr/lib/pymodules/python2.6/univention/management/console/modules/schoolexam-master/__init__.py", line 209, in create_exam_user if not userSid or userSid == 'None': UnboundLocalError: local variable 'userSid' referenced before assignment
fixed.
QA: Ok, the problem did not occur again in my tests, the code is identical to the one in users/user.py. Changelog OK. → VERIFIED
UCS@school 3.1 R2 has been released: http://download.univention.de/doc/release-notes-ucsschool-3.1-rev2.pdf If this error occurs again, please use "Clone This Bug".