Google Apps Integration Issues with upgrade to Moodle 2.4.5

Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Matt Ladwig -
Number of replies: 11

Our hosting company (Remote Learner) recently upgraded us to Moodle 2.4.5 (this is the latest version that they support), but now we are having issues with our Google Apps integration. I was trying wait to let them fix the issue, but 4 days have passed, so I figured it is time to reach out to the amazing people in the forums for help... or at least some info. smile

First of all, does the Google Apps integration work with Moodle 2.4.5? And in that integration (when working properly), are Google Apps accounts automatically created for users when you create a new Moodle user? One of the techs at Remote Learner was telling me that there may not be an option to sync when using Google Integration with Moodle 2.4.5. 

Here is the error that we are getting. A user can log into Moodle just fine and even the individual gmail messages show up in the gmail block. However, when a user tries to click on a message, which would normally log them into their gmail, they are taken to a page that says "You are already logged in as XXXXXXXX, you need to log out before logginin as different user."

Any suggestions?

Thanks!

Average of ratings: -
In reply to Matt Ladwig

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Rob Johnson -

I will be upgrading to 2.4.5 tomorrow.  I will post back what happens with GApps.  Do you know if your host used the Google integration package for 2.4?

Average of ratings: Useful (1)
In reply to Rob Johnson

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Matt Ladwig -

Thanks Rob, I appreciate it. I am not sure if our host used the Google Integration package for 2.4. I will check.

Best of luck on your upgrade process today.

-Matt

In reply to Rob Johnson

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Matt Ladwig -

Update: Our host did use the 2.4 code for the Google integration. The problem they are reporting to me is; that the code has changed a lot since 2.2, but the documentation to reflect that or how to set it up now is not up to date.

I am going to keep researching the issue and will keep you updated on what I find. Thanks!

In reply to Matt Ladwig

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Rob Johnson -

Hi Matt,

I have upgraded from 2.3+ to the most recent 2.4.5. I am in the middle of adding back plugins, but I do have Google Apps working.  At first, I saw the behavior you describe where the user is redirected to the "You are already logged in as..." page.  I looked at the auth plugin settings, and Gsaml had the eye closed.  After I opened it, the SSO worked.

As far as user sync, that is something that has been inconsistent for me since upgrading from 1.9.  I do not use the GData cron for user sync.  It has deleted users that were not supposed to be deleted in the past.  I have events enabled in the Google User Sync block settings.  In 1.9, this worked flawlessly.  Users created or deleted in Moodle were created/deleted in Google at the same time.  The user creation has not worked for me in Moodle 2.x without the code change mentioned here.  That change creates users in 2.4, but in my initial testing, users do not seem to be deleted in Google if deleted in Moodle.

I will post back if I find anything else of value.

Rob

In reply to Rob Johnson

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Matt Ladwig -

Hi Rob,

We had some issues with Google Apps integration as well when we upgraded to 2.x, but they were slightly different. Everything worked fine, but we figured out that Google accounts were not automatically created for users until a user went into their Moodle and updated their profile (or an admin could update each users profile individually). This could be them updating their password, adding info to their profile, etc (or you could just press update without updating anything and it triggered the creation of the Google Apps Account).

It looks like our Moodle is no longer using Gsaml and there is no longer a Google User Sync Block. Our host is using Google OpenId Authentication. I wonder if using Google OpenId Authentication will fix issues or cause more... Any thoughts?

Thanks for keeping me updated on your results. I really appreciate it!
-Matt

In reply to Rob Johnson

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Matt Ladwig -

More info: A tech from my hosting company is telling me this documentation is out of date and the code no longer has the gsaml authentication plugin or the user sync block... this seems odd considering that you are using the gsaml just fine.

Rob, it is impressive that you were able to upgrade your own Moodle with Google Apps integration in a day while our hosting company who specializes in Moodle and is a Moodle Partner can't get ours working in 6 days... and they still seem lost.

My hands are tied at the moment. I would love to attempt to fix it myself, but our host no longer lets their clients have full access. We are not even allowed to upload a plugin. It is one of the frustrating things with going with a Google Partner. 

In reply to Matt Ladwig

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Rob Johnson -

I am curious what code your host is referring to.  I am using the integration maintained here at the Moodle for New Zealand schools site (I run a Moodle for a school district in Southern California).  They even have a release for 2.5.  It uses gsaml for authentication.  For this integration package, most of the documentation you linked to is still valid.

Please post back with how this turns out for you.  I am sure other Moodle admins will run into a similar situation.

In reply to Rob Johnson

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Sam Norman -

Hi all,

I too had this issue where after upgrading my Moodle was not able to use the gsaml authentication plugin or sync users to google. This was after searching for updated code on the moodle.org site.

Taking a lead from Rob's post, I downloaded the Moodle for NZ Schools package for 2.5 and copied the auth/gsaml and the blocks over to my moodle. I found once I had run the notifications, my moodle updated with the new code but had retained all the settings (including the rsa details) and worked straight away. 

Thank you Rob for your post and the point in the right direction. It has certainly saved me a lot of hassles.

 

Cheers,

 

Sam.

In reply to Sam Norman

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Kunihiko Harada -

Hi everyone in this thread.

I tried to download Moodle for NZ Schools 2.5, but it is gone. I cannot find any instructions for Moodle for NZ Schools 2.5 either. What is going on? Please help. I just would like to do a better job as a teacher using Moodle and Google Apps combined.

In reply to Matt Ladwig

Re: Google Apps Integration Issues with upgrade to Moodle 2.4.5

by Mike Feist -

If you're still running Moodle 2.4.x then that should continue to work well with Google Apps.

If you upgrade to Moodle 2.5 or newer and your PHP version is 5.3.7 or newer then changes to the password hashing methods will break the Google User Sync.

 

I have detailed a workaround to get it working for Moodle 2.5.x here: https://moodle.org/mod/forum/discuss.php?d=233070 although I haven't tested on Moodle 2.6 yet.