Migrating from 2.9.1 to current version

Migrating from 2.9.1 to current version

by Jeremy DeStefano -
Number of replies: 13
I've inherited an ancient install running on a hosting provider.  Currently running 2.9.1.  Running into issues with insecure content and pages not displaying properly.  I want to move the site inhouse.  Looking for the best course of action to get my database from the old version to a more supported current version.  My instructors who use Moodle are deathly afraid of having to retype all of their question data into a new instance, so I'm hoping at the very least, I can get that migrated over.  The old instance is running on a linux server and I'm planning to move to something Windows based, likely with XAMPP as that's what I'm most familiar with, its just the data migration that I'm concerned about.  It looks like I might at least be able to get upgraded to a low 3.x version without much issue if that would help with migration.  Any advice is appreciated.
Average of ratings: -
In reply to Jeremy DeStefano

Re: Migrating from 2.9.1 to current version

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Marching a Moodle site and what platform(s) to use are two different things:

- March route: Where you want to go? Get it from https://moodledev.io/general/releases. The the planer is here http://www.syndrega.ch/blog/#php-and-dbms-compatibility-of-major-moodle-releases.

Pay attention to the maximum(!) versions of the compatible system software.

- Platform: Yes, people take what they are familiar with. I have a full series of (some historical) Debian Linux VMs to march Moodle. If you know XAMPP well, then take XAMPP.

Not counted are the additional plug-ins. After such a long time the probability is high that some of the plug-ins have been abandoned.

"deathly afraid" Take all kind of backups, Site_backup, Course_backup, Question_bank backups, ... And don't burn your bridges. ;)
In reply to Jeremy DeStefano

Re: Migrating from 2.9.1 to current version

by Ken Task -
Picture of Particularly helpful Moodlers
Hmmmm ... this is a re-hash of:

So the advice given there was of no use, I guess. sad

Ok, so what's changed in 2 years plus (if the dates in forum are accurate)?    Uhhh ... a bunch.

It's one thing to migrate a site ... it's yet another to migrate a site and upgrade at the same time (not advisable) + move to another platform!!!!

Plus there is this ... are ya 'jumping out of the pan into the fire'?   Assuming your govt entity is to continue to use Moodle, what of future ... from 3.9 to latest/greatest 4.3 or better yet might be LTS 4.1.

Are ya gonna run the new server in a Virtual Environment where you have 'flexibilty' in memory/space one can allocate to the moodle?

'SoS', Ken
In reply to Jeremy DeStefano

Re: Migrating from 2.9.1 to current version

by Ken Task -
Picture of Particularly helpful Moodlers
Ok, many things aside ... 2 cent suggestion for path of least resistance.

Stand up a 4.1 highest on whatever platform you like.   Don't install using localhost.   Do get a valid cert for it so site can run https.

Install the same plugins you have on old server into new server.
That includes theme (if you can).   And any addon question types you might have installed in the old server.

Once you have that sorted, make 1 full course backup ... includes users and their work (includes quizzes).

Restore that course backup to the Miscellaneous category ... that will be the only cat on a new fresh 4.1.

The quizzes and test bank for that course should be restored with that course.

Have the Teacher of that course check it out ... if all ok ... you then have your plan.   Just a matter of how quickly you can do that process then with X number of courses.

Good luck!
'SoS', Ken

Average of ratings: Useful (1)
In reply to Jeremy DeStefano

Re: Migrating from 2.9.1 to current version

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Just to add my five cents worth - I would think twice about switching to Windows...the main reason being that the vast majority of us who assist on these forums are running on Linux and if you run into trouble, you are going to get very little help with a Windows setup...I originally learned linux during my first Moodle install  - it is not that hard and there are all sorts of guides to get you started.
From 2.9.1, it is not a hard path to get upgraded - just make sure you have the right march path and the correct prereqs for each step..data migration is just a matter of getting the moodledata folder and the database and your config file from the current moodle folder moved over (new code and current plugins can be redownloaded from moodle).  
Average of ratings: Useful (1)
In reply to Emma Richardson

Re: Migrating from 2.9.1 to current version

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
I don't know whether this is new people want to hear, but there they are: https://moodle.org/mod/forum/discuss.php?d=401983#p1778616.
In reply to Visvanath Ratnaweera

Re: Migrating from 2.9.1 to current version

by Ken Task -
Picture of Particularly helpful Moodlers
@ Mr. V ...
From OP's original posting in this thread:

"My instructors who use Moodle are deathly afraid of having to retype all of their question data into a new instance, so I'm hoping at the very least, I can get that migrated over."

Attempting to get just a piece of the whole (question bank and data) is, IMHO, wrong approach and even more so with change of platform.   Guess that would depend on how well OP can 'McGyver' (sp?)  things + time + cost (after all, the OP's time is worth something!)

OP hasn't said what package is leased with provider - shared/VPS etc.

Do know this ... for a fact ... using git for a 'march' is the best way to do a march.  While git is available on Windows, I would imagine that would be yet another challenge.

Haven't heard if courses can be backed up or not.

Guess this will be a mystery until OP replies! smile

'SoS', Ken

In reply to Ken Task

Re: Migrating from 2.9.1 to current version

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Ken, my reply to OP was this https://moodle.org/mod/forum/discuss.php?d=452593#p1818916. The one you are referring to is a general comment chiming in with Emma https://moodle.org/mod/forum/discuss.php?d=452593#p1819264.

In reply to Visvanath Ratnaweera

Re: Migrating from 2.9.1 to current version

by Ken Task -
Picture of Particularly helpful Moodlers
@ Mr. V - yes ... all good points from both you and Emma.

Kinda sad to see hosting providers not warn or nag customers about upgrading their sites.   SiteGround, a few years ago, got itself into a pickle with Joomla 1.5's - support desk nightmare and a danger to other customers on shared hosting.   They finally had to put their foot down and told customers upgrade or we'll take your site down.    They did! smile

Granted folks still seem to follow 'if it ain't broke, don't fix it' ... but one would think that, in this day an age, that get's one in trouble. :|

Anyhoo ...
'SoS', Ken

In reply to Ken Task

Re: "Moodle ain't broke, why fix it?" [RANT]

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
From different angle one could see countless users who would be happy with Moodle they have - unless they are forced to the box stop to "release".
In reply to Visvanath Ratnaweera

Re: "Moodle ain't broke, why fix it?" [RANT]

by Ken Task -
Picture of Particularly helpful Moodlers
Danged if you do ... and danged if you don't!

Question is ... which is the lesser of the 2? smile

Think this does illustrate a need for a 'better way' to update/upgrade a moodle.

'SoS', Ken

In reply to Emma Richardson

Re: Migrating from 2.9.1 to current version

by Jeremy DeStefano -
Sorry all, didn't mean to go dark. Other work related issues kept me from getting back to this. After some careful thought, I opted to stick with Linux. Current setup is on Hostgator, just plain old shared hosting. The new server is Ubuntu in my own data center running Server 22.04. I can manage with Linux, just not my forte. Moodle 4.1 is installed via the Howto I found on the Moodle support pages. I got logged into the new system, but that's about it. I did figure out how to backup a course....definitely a bit confusing, but I've got it. Also setup the automatic backup for all the courses. Unfortunately, my training group is starting a new class on 11/20, so I'm hoping Moodle holds it together for the length of this class as I work on the new one and post class, I'll get them migrated over properly.

Ken, as for what happened to the old 2yr posting, its literally the same issue, just never got upgraded then and now changes with how Chrome handles certain content is forcing my hand. I've found workarounds by allowing insecure content for now, but I know its a stopgap measure at best. I'm going to try to import some of the backed up courses and see how things go. Does importing a course also bring over the user accounts? or is it just bringing over the data and I still need to recreate the accounts?
In reply to Jeremy DeStefano

Re: Migrating from 2.9.1 to current version

by Ken Task -
Picture of Particularly helpful Moodlers
Must say you are not helping us help you much!   Vague, but ... since you are a .gov guess that's the norm ... so ... we'll start simple:

In answering:

"Does importing a course also bring over the user accounts?"

If you make the course backup with all options for what to backup checked that will include users - and their work in that course.
Assuming users accounts were created manually, the users accounts will be created - same logins/passwords - if manual.

Automated backups on shared hosting ... might be an issue ... sounds like the easiest way ... so guess we'll see!

One recommendation there ... set auto backups to go to a designated directory outside of moodledata - you have to create the designated directory and it must be writable by web server.

Why?   So you can see their file names and sizes of backup files and acquire them to xfer to your internal Linux box.

Check current servers backup preferences as well as autobackup preferences.

Wonder if you could provide at least a generic answer to this question:

What's in a typical course?   Videos/audios, quizzes, PDF docs, Word Docs, Forums, mostly SCORM's?   What?

'SoS', Ken