Moodle 2 MSSQL External Database Enrolment

Moodle 2 MSSQL External Database Enrolment

by Marc Veenstra -
Number of replies: 6

Setting up a test server for Moodle 2 to get familiar with it before deciding whether to migrate from 1.9 over the summer.

Have followed the notes by Alex Pearce to install on Server 2008R2, IIS, MS PHP driver & MSSQL 2008R2.

Have successfully set up site. Have successfully set up LDAP auth.

Cannot get External Database Enrolment to work. My assumption is it is related to the database driver as the new native (sqlsrv) driver is not an option. I tried selecting mssql_n (basically copying settings from functioning 1.9 site).

Trying to login as a student generates an HTTP 500 error. Did some reading and gave it some thought. Installed the Freetds driver and added to php.ini. reboot etc and try again. Now the students login without error but the enrolment process does not occur.

Does anybody have notes on how to get external database enrolment working against MSSQL 2008 R2 when using Moodle 2.1 (build 20110701).

Cheers

 

Average of ratings: -
In reply to Marc Veenstra

Re: Moodle 2 MSSQL External Database Enrolment

by Judy Bartlett -

I had the same problem - I found I had to enable the external db enrolment plugin at course level. I can't find any way to enable it by default for all courses.

In reply to Judy Bartlett

Re: Moodle 2 MSSQL External Database Enrolment

by Wes Matchett -

I am in the process of setting up a test server to debug this problem.  I will post my results here.

In reply to Wes Matchett

Re: Moodle 2 MSSQL External Database Enrolment

by Judy Bartlett -

Just found that some courses do not have external db enrollment as an option??  It all works fine when external db is enabled on the course. I'm not sure why different courses have different enrollment plugins available in them - is this a bug? Should they all have the full list of the plugins enabled at site level? Or am I missing something?

In reply to Judy Bartlett

Re: Moodle 2 MSSQL External Database Enrolment

by Wes Matchett -

Interesting.  It is my understanding that the external DB enrole was system wide and applied to all classes.  None of my classes have it as an enrolment option.

In reply to Wes Matchett

Re: Moodle 2 MSSQL External Database Enrolment

by Chris Myers -

We ran into the same thing using an Oracle DB. It turns out that the enrolment type doesn't show up until you have someone in the course enrolled by that method. At least that's how it worked for our 1700 courses. We had the courses created through the DB enrolment process, and then added the user enrolment process afterwards. Before enrolling users in the courses through the db enrolment process, the db enrolment option wasn't available on the courses. But after syncing everything, then it became available.

In reply to Marc Veenstra

Re: Moodle 2 MSSQL External Database Enrolment

by Tony Barry -

Hi Marc,

Can I ask if you resolved this problem. I am running the same set up to you but using Moodle 2.4. If I set the external database enrolment connection string to mssql then I can login to Moodle, but it does not work and nor does the sync.php tool. If I change it to mssqlnative then the sync.php works but I get the HTTP 500 error when trying to login. Any ideas?