Hi all,
First time trying LDAP authentication.
Win Server 2008 & XAMPP 1.74.
I've entered all the LDAP details i believe are nessecary and get the following error.
C:\>c:\xampp\php\php.exe -f c:\xampp\htdocs\training\auth\ldap\cli\sync_users.ph
p
Connecting to LDAP server...
Creating temporary table tmp_extuser
................................................................................
................................................................................
................................................................................
................................................................................
................................................................................
................................................................................
................................................................................
...................Default exception handler: Error writing to database Debug: D
uplicate entry '1-user name' for key 'mdl_tmpextu_mneuse_uix'
INSERT INTO mdl_tmp_extuser (username,mnethostid) VALUES(?,?)
[array (
0 => 'user name',
1 => '1',
)]
* line 397 of \lib\dml\moodle_database.php: dml_write_exception thrown
* line 878 of \lib\dml\mysqli_native_moodle_database.php: call to moodle_databas
e->query_end()
* line 938 of \auth\ldap\auth.php: call to mysqli_native_moodle_database->insert
_record_raw()
* line 670 of \auth\ldap\auth.php: call to auth_plugin_ldap->ldap_bulk_insert()
* line 65 of \auth\ldap\cli\sync_users.php: call to auth_plugin_ldap->sync_users
()
!!! Error writing to database !!!
Potential coding error - existing temptables found when disposing database. Must
be dropped!
Can someone please help or offer any advice?
If i change subcontext to no then i get:
C:\>c:\xampp\php\php.exe -f c:\xampp\htdocs\training\auth\ldap\cli\sync_users.ph
p
Connecting to LDAP server...
Creating temporary table tmp_extuser
Did not get any users from LDAP -- error? -- exiting
Potential coding error - existing temptables found when disposing database. Must
be dropped!