Topic on Extension talk:LDAPAuthentication2

Jump to navigation Jump to search

autocreateaccount throwing no such table: ldap_domains

4
2601:46:C702:5634:6124:8B90:4DDC:DE67 (talkcontribs)

Hi,

I'm trying to setup ldap authentication on a mediawiki docker instance. I've gotten to the point where the ShowUserInfo.php and CheckLogin.php work correctly. I am also able to login to the wiki instance with an account that already existed, but using ldap instead of the local login. The problem I run into is when i try to login with an LDAP account that doesn't already exist. When i do that i get the following error:

/var/www/html/includes/libs/rdbms/database/Database.php: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?

Function: Mediawiki\Extension\LDAPProvider\UserDomainStore::getDomainForUser

Error: 1 no such table: ldap_domains


I have searched for how to solve this error but only find solutions for LDAPAuthenticator, not LDAPAuthenticator2 (the file they say to run does not exist in the new version)

I can't include logs because this is being spun up on a confidential system.


My question is: how do i create the table ldap_domains? i have LDAPProvider, PluggableAuth, and LDAPAuthenticator2 modules installed.

Osnard (talkcontribs)

Have you run <mediawiki>/maintenance/update.php after installation/activation?

2601:46:C702:5634:D016:26C8:684E:4744 (talkcontribs)

So this is running inside of a docker container. is this something that i should add in my LocalSettings.php file as require_once("maintenance/update.php"); ?


2601:46:C702:5634:D016:26C8:684E:4744 (talkcontribs)

For others: Osnard's solution worked, as long as you have a mounted volume holding the data files and the database files this only needs to be run once. You cannot make this a require_once() call, this makes it so that the webpage only displays an error. After running the update.php file, everything works (LDAP) and the changes persist over docker container failovers, if you're using a service like me.

Reply to "autocreateaccount throwing no such table: ldap_domains"