Moodle to Moodle db authentication

Moodle to Moodle db authentication

by Ron Walker -
Number of replies: 4

I have set up and successfully connected Moodle external db authentication with another Moodle db. However the field mapping for firstname, lastname, and email do not populate the internal db automatically.

Each time I log in as a test user I must enter my firstname, lastname, and email... username and password work.

Even when I update my profile the internal db does not update the local database, leaving the firstname, lastname, and email fields empty.

Any help is much appreciated.

Average of ratings: -
In reply to Ron Walker

Re: Moodle to Moodle db authentication

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

Can you tell us (or attach a screenshot) the settings you have under Data mapping on the external database authentication plugin page:

Data mapping fields example

for the first name, last name and email address fields.

Also what are the versions of Moodle for the site you're configuring and the external database source? And are you running the sync script? And what types of database are these (e.g. MySQL, SQL Server).

In reply to Leon Stringer

Re: Moodle to Moodle db authentication

by Ron Walker -

I ran the sync script and it brought in all users but the firstname, lastname, and email where all blank.

I have set this up before with a non moodle database and everything works fine. 

Both Moodle databases are hosted on the sam server and are MySql databases.

In reply to Ron Walker

Re: Moodle to Moodle db authentication

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

Have you got any other authentication methods enabled under Site administrationPluginsAuthenticationManage authentication, other than:

Available authentication plugins

I'm just wondering if the user with empty firstname, lastname and email fields could be being authenticated by another source that doesn't have these fields populated?

You say that when the user's firstname, lastname and email in their profile are updated this information isn't saved. Does it appear for that user until they log out, does the firstname and lastname you enter appear in their profile menu that appears in the top right containing the Log out menu item?