Upgrading from 2.0 to 2.5, simple?

Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -
Number of replies: 25
Good morning Folks,
I have a client's site which runs Moodle 2.0.  In order to offer a new Articulate Quiz which is Mobile friendly, I need Tin Can API support.
From my understanding, this can be done in Moodle via a plugin but Moodle requires 2.5.

If all above is correct, is the upgrade path from Moodle 2.0 to 2.5 a simple one?

Cheers,
Gilles
PS. Note that I'm not a Moodle expert, but a beginner.


Average of ratings: -
In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Albert Ramsbottom -

Hi


You can only upgrade from 2.2 to 2.5 so you will need to upgrade from 2.0 to 2.2 first

I believe

https://docs.moodle.org/25/en/Upgrading

Average of ratings: Useful (2)
In reply to Albert Ramsbottom

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -

Thanks Albert!

In this case, my question is...

Understanding I must firest upgrade from 2.0 to 2.2.... How big a task is it to upgrade a small Moodle 2.0 site to the latest 2.9 ?


In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Bret Miller -
Picture of Particularly helpful Moodlers

In either case, you must upgrade to 2.2 before you can upgrade past that. For a small site, it may not be that painful, but it depends more on the plugins and theme the site uses. There were major theme changes in 2.7 so you will almost certainly have to pick a new theme. Just make sure you read the upgrade instructions. And, even though you are skipping versions, you should read the instructions for each version in between. Sometimes there are steps that need to be performed after an upgrade. Many of us would say it is safer to upgrade one version at a time, but the official position is that you can upgrade from 2.2.x to 2.9.x.

And as Howard said. Backup and verify that you can restore your backup because if something goes wrong during an upgrade, your backup is the only way to fix it. Backups include three parts: the public html/php files, moodledata files, and the database. You need to have a backup of all three to successfully restore.

In reply to Bret Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -
Thanks Bret, this is very helpful.

  1. Do you know if a "Tin Can" quiz will provide the same features as a Scorm 1.2 quiz? That is, I need to allow only 2 attempts and the passing score is 90%.  Is this still possible? If not, there is no reason for us to go to 2.9 and we'll leave everything as is.

  2. Is there a backup procedure/plugin for Moodle? how do Peeps do it? I'm from the Joomla world where you install an extension and all is backed up in on task.

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Bret Miller -
Picture of Particularly helpful Moodlers

I do not know the answer to #1 as we use mostly native Moodle.

For backups, there is a documentation page:
https://docs.moodle.org/29/en/Site_backup

I use a script for updates, but many on here would advise you to use Git. So here is my normal backup procedure. This assumes Linux. If you have Windows, the commands could be different.

#Path to your moodle site files
site='/home/user/public_html'

#Path to your moodledata (uploaded files, temp and cache)
files='/home/user/moodledata'

#Database info:
sqlhost='localhost'
sqluser='dbuser'
sqlpass='password'
db='moodledb'

mydate=$(date +%F)

echo "Putting site in maintenance mode..."
cd $site
php admin/cli/maintenance.php --enable

echo "Purging caches..."
php admin/cli/purge_caches.php
cd ..

echo "Creating SQL backup of $db..."
mysqldump --add-drop-table -h$sqlhost -u$sqluser -p$sqlpass $db > $db-backup-$mydate.sql

echo "Backing up programs and files..."
tar -cpzf _backup/$site-backup-$mydate.tgz $site $files $db-backup-$mydate.sql
rm $db-backup-$mydate.sql

#Out of maintenance mode
php admin/cli/maintenance.php --disable

Average of ratings: Useful (1)
In reply to Bret Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -

Thanks. I don't think I'd be able to use this script as the site is on a shared host... no access to the "console" or command line.

I could be wrong.

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Three of my shared hosting companies all provide access via ssh.  If it doesn't appear that yours does, make sure to ask (or demand.)

Bret's script is very good, and I have learned from him. (Thanks Bret.)

Average of ratings: Useful (1)
In reply to Rick Jerz

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -
ok... Thanks. I've never used this feature of shared hosting.
Again, I'm used to Joomla (and Wordpress) where generating full backups is very simple and available via free easy-to-use extensions/plugins.
In reply to Bret Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Bret, help me understand a few things.

Does what you do in your script automatically make entries into the server's log file?  Or would it make sense to log the events is your own "backup.log" file, somewhere?  In particular, I would like to monitor when this script begins, and when it ends in order to know exactly how long my moodle is in Maintenance mode.  I could probably (somehow) subtract mydate from an ending date (after maintenance mode is disabled.)

I see that you "echo" some messages.  Are these really needed?  Are these only there for a person who might be watching, or do they serve some other purpose?

When I do my current backup, I don't put my Moodle into maintenance mode.  I can see the benefit - to keep the database and moodledata exactly in sync. 

Average of ratings: Useful (1)
In reply to Rick Jerz

Re: Upgrading from 2.0 to 2.5, simple?

by Bret Miller -
Picture of Particularly helpful Moodlers

Hi Rick,

Glad it was helpful. I don't make any log entries. This was actually chopped out of my upgrade script, so it's not what I generally use for daily site backup. But any time I upgrade our live site, a full site backup gets done first.

Certainly you could pipe a couple of echo's to a log file to see each time the backup script started and ended. I don't do it here because upgrades are always in me-watching mode.

The echos are not needed. For me, since this is my upgrade script, it gives me a sense of where in the process the script is. Otherwise it would sit there for a long time with no feedback.

I only do my pre-upgrade backup in maintenance mode since that guarantees I have a good backup. For daily backups I dump the database and use rsync to download it and all the files to a local server where it gets backed up and shipped offsite per our normal backup policy. Plus rsync only has to copy the files that changed which significantly reduces the bandwidth requirements.

I do the offsite because once we had a disk controller die on the VPS host at the hosting company corrupting all the data. Yeah, they restored it, but we lost a few weeks in the process. Apparently, their idea of backup is not the same as mine. So now I have yesterday's backup on my local server, disk and tape backup so the ability to restore is more "guaranteed".

In reply to Bret Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Thanks for your reply, Bret.  Every little bit helps.

In reply to Bret Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Doug Moody -

Bret and/or anyone else,

Seeing as the issue of backups came up, I have a fundamental backup question that I have never been able to properly answer...

I do backups regularly. However, should the need ever arise, and the site goes down, and I want to restore it, what do I do to ensure the latest backup is not corrupted in some way?

My nightmare scenario would be that I have been making regular backups, then the site crashes, and then I need to restore. However, I try backup #1, and it restores the site to something that doesn't work and/or s corrupt and won't restore properly. So I try backup #2, and since it was backing up my site that had a flaw in it that I never caught, it is corrupt also. And so and so on with all my backups.

Other than inspecting every backup I ever made, what can I do to ensure that if the site goes down I can restore it completely without error? I am looking for ideas on backup and restore procedures that will make my site bulletproof.

In reply to Doug Moody

Re: Upgrading from 2.0 to 2.5, simple?

by Bret Miller -
Picture of Particularly helpful Moodlers
Hi Doug,

There is no simple answer to your question. And there is no real way to insure the backup will work without restoring it to a test site and manually checking it. Even there, you're human and you might miss something. We've run Moodle since at least 2010. I've never had a problem restoring a backup. Maybe I'm just lucky. That said, best practice says we manually verify that we can restore from backup at least occasionally so we know the process is working.

As with any active system, there is a possibility of corruption if you don't stop activity while you back up. Putting the site into maintenance mode does that. Of course doing that basically takes the site offline so you have to be willing to tolerate some downtime to get that static backup that is most likely to work when you restore it. I only do it pre-upgrade and have never had an issue with the other backups. You just can't be too careful when you upgrade--you really need to be able the put the site back if something goes wrong.
In reply to Doug Moody

Re: Upgrading from 2.0 to 2.5, simple?

by Luis de Vasconcelos -

I regularly use the production backups to refresh my DEV and QA environments with the latest data from PROD. That confirms that the backups work.

In reply to Luis de Vasconcelos

Re: Upgrading from 2.0 to 2.5, simple?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Yes. There's no point taking backups if you don't use them to attempt to create a (working) copy of your Moodle site. 

On anything more than a trivial site the ability to create backups and use them to make a parallel "test" site should be considered a core skill wink

Average of ratings: Useful (1)
In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -

Does anyone have an answer on nunmber 1 above? The question about QuizMaker?

Cheers

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Take backups. Then check them. Then take more backups.

If you have backups then nothing bad can happen wink

Average of ratings: Useful (1)
In reply to Howard Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -

Yup.... Well aware of backups, I would not proceed without them.

But alas, this doesn't answer my question smile

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

TinCan does not replace Scorm in moodle. There is no player for them... you need to link to something external.

In reply to Howard Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -
Thanks Howard.
My quiz appears to be created with a player (Articulate QuizMaker).
What then, is the best way for me to offer this new mobile-friendly version of the quiz?
My client needs to track quiz users and their scores.
I'm open to any suggestions, including non-Moodle.  Hosting on Articulate for $200/month is cost prohibitive for my client.
Cheers,


In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Moodle quiz?

In reply to Howard Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -

Hi Howard,

As mentioned it is an Articulate QuizMaker quiz. includes videos, etc.

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

If you intend to use SCORM (and I understand why you would) then you only have a very thin interface to Moodle. Presently this is just the way it works - and I don't see it changing soon. TinCan is in many respects even worse - you need to set up the TinCan resource outside of Moodle and then use an optional plugin to link to it and access the grades. Basically, it's still quite limited. 

Either way, you are just using Moodle as a 'player' for the resource and having Moodle handle your users. 

If you want a richer experience - in Moodle - then you should convert to using Moodle activities. It really comes down to what you need and where you are prepared to compromise. 

Average of ratings: Useful (1)
In reply to Howard Miller

Re: Upgrading from 2.0 to 2.5, simple?

by Gilles Gagnon -
Thanks Howard. Some of this lingo is beyond me.
So.... all I want is to be able to offer my QuizMaker quiz to students and have the scores recorded. I also need to limit the tries to two. The student must get 90% to "pass".

All this was working splendidly in Moodle. I was publishing the QuizMaker quiz as "scorm" and away I went.
Now, in order to make the quiz mobile friendly, I had to upgarde QuizMaker as they have new publishing options. TiNCan and html5. Html5 doesn't work on android devices...so... I'm left with using TinCan. 

Is there no other very simple / free way of offering the QuizMaker Tin Can quiz?
I'm open to all suggestions.

In reply to Gilles Gagnon

Re: Upgrading from 2.0 to 2.5, simple?

by Andrew Downes -
Hi Giles!


I'm glad I spotted this thread. I sent an email to info@tincanapi.com with a related question, but the email address you provided (and the one published on your websites) doesn't work; the emails bounce. 

Here's the response I wrote to the question you asked via email. It seems you've already figured out that upgrading your Moodle is a good idea, which is great. 

"Thanks for your questions. I'm going to split your overall problem into two different questions rather than the three you asked, but I will covered your three questions in answering them.

1. Does Quizmaker generate the data that you need? 
2. If it does, can you get it into Moodle? 

I'm not familiar with Quizmaker at all, but if Articulate who make the product have told you that you need to use Tin Can in order for it to work on mobiles, I'll trust that. There's no reason why you can't send pass/fail information via Tin Can, but I don't know whether or not Quizmaker does, so that's another question to ask Articulate. Let's assume for now that you can get the data. 

On the Moodle side, it's worth mentioning that Moodle 2.0 is now very old, having been released in November 2010 and support ending in July 2012. I recommend keeping your Moodle version updated; the current version is 2.9, though 2.7 is a long support release so may be a better option if your client is adverse to upgrades. You will find that the second plugin I'm about to mention doesn't work in Moodle 2.0 without some development work. That work might be as simple as editing the minimum required version setting or might be more involved. 

Like many Moodle features, Tin Can support can be added via a plugin. There's two options:

  • There is a SCORM Cloud Moodle plugin: http://scorm.com/scorm-solved/scorm-cloud-features/app-integrations/moodle-integration/ This allows you to upload SCORM 1.2, SCORM 2004, AICC or Tin Can packages in Moodle that are played in SCORM Cloud. Tracking data is sent back to Moodle. This is likely to be the easiest way of achieving what you want. It requires a SCORM Cloud license. 
  • The is another Tin Cab launch plugin that will work with any Learning Record Store, including the free LRS features incorporated into SCORM Cloud: https://github.com/garemoko/moodle-mod_tincanlaunch This does not require a SCORM Cloud license but is more likely to need you to do development work. In addition to the Moodle version issues, the plugin only pulls completion/non-completion information from the Learning Record Store and not pass/fail or score (you could use Moodle's completion to indicate pass/not-yet-passed though). 
Does that answer your question? Do you have any follow up questions?"

Hope that helps! Please feel free to mail andrew.downes@tincanapi.com for any follow up questions; I don't subscribe to Moodle forums because of the volume of emails on unrelated threads it generates so may not see a response here. 

Average of ratings: Useful (1)