What is the best way to upgrade from Moodle v1.99+ to whatever the most current version?
If I perform a clean installation of v3.x, can v3.x import exported user and course data from v1.99?
I wouldn't do it at all.
Create a new, empty site and recreate your courses from scratch. When you've stopped reeling in horror I would suggest that it's much less bother and the end result will be better and more reliable
+20 to what Howard said ... this coming from one who has in the past 'marched' Moodles from old versions to 3's cause 'customer' insisted on keeping stuff. We ended up where 'customer' decided best to install fresh and rebuild courses in the new.
About the only things one can salvage from a 1.9.x site, are the files in the course ID's of the old moodledata. That will be the last time you see those docs/uploaded files by their humanly recognizable names in a moodledata directory.
Some special areas of concern in archiving *IF* you have some records retention concerns ... old certificates - if you used certificates mod with the 1.9 site. Does that 'fit' your situation?
'spirit of sharing', Ken
I tend to agree with Howard and Ken but I recently successfully marched two sites all the way through without much issue. It is a process though. You need to look at the upgrade instructions. In addition to the interim moodle versions, you will also run into some php and database changes. However, if you need your existing user data in the upgraded site, this is the only way to do it.
I don't mind stepping through several versions of Moodle doing upgrades and taking backups and such.
I'm much less fussed about doing the PHP upgrades that will also be required. What do you end up with? Moodle 3.5, while not exactly unrecognisable from 1.9, is a lot different. Will the content still hang together properly. Plus you'll have years worth of junk you could have taken the opportunity to get rid of. Worse... if the 1.9 site has itself been upgraded from previous versions the database isn't likely to be in a great condition which could cause problems in the upgrade. Quality control wasn't as good then as it is now and schema problems frequently appeared during upgrades. I remember frequently having to do schema checks and repairs in the "old days" (nowhere near as tragic as Mahara though!)
Also, while I know that 1.9 migration is still tested - how much is it tested? Are we really confident that data dragged screaming from 1.9 will be stable an who will care if it isn't.
If I was advising a client.... I would strongly recommend that we build a server that matches the requirements of Moodle 3.5 and run that on it. You know were you are then.
Just my $00.02
Well I have recently finished upgrading 1000 moodles from 1.9 to 3.3 with the help of Ken and a Moodle march.
No data was lost and we upgraded the LAMP as we went.
We upgraded 1.9 to 2.1 the on to 2.2 on the hardware, then moved a vm and upgraded on a VM, right up to 3.3 and then moved it to Azure
Cheers
Maybe we should be asking the original poster some questions ...
1. is your platform linux? If so, what flavor?
2. do you have access to ssh and command line on server?
3. can you install software via package manager?
4. do you avoid the command line at all cost?
5. how much storage do you have for backups of code and SQL dumps of database at each stage of the march? .... and initially, how much space do you have to make one full backup of moodledata ... there after minimal backup of moodledata/filedir.
Wouldn't do a 'march' unless one could do it with git.
Even that requires research on addons/plugins/themes etc. prior to beginning and planning/adjusting along the way. This march involves pulling the trigger on php upgrades at the right time as well as DB upgrades at the right time + changing character set/collation at an appropriate time as well.
So marches a year or so ago were less complicated than they are today. It can be done ... maybe not in a day though.
'spirit of sharing', Ken
Thank you all for your responses.
One question that no one answered was using the export/import feature of Moodle. It would seem the obvious method to export the old version's data, perform a clean installation of 3.x, and import the data.
Are the data so different among versions that v1.9 exports are incomprehensible to 3.x import?
I suppose a very general answer is 'yes'. There are SIGNIFICANT changes to Moodle from version 1.9 to version 2.0, most notably (to me anyway) being the change in file directory structure to something human readable and more like a typical directory structure of a web page to something that is no longer so (security related). Presumably this related to database structures. You could easily try this out by trying to import a 1.9 course into a MAMP/XAMP/Sandbox installation of 3.x and see what happens
These files are treated as 'legacy files' in 2.0 and onward and, depending on how many you have, add lots of extra size to courses. There also isn't a particularly easy way to remove them-you have to manually delete folders/files in each individual course should you not need them any more. Or rebuild the courses and the delete the ones with legacy files.
Importing a course with legacy files also duplicates the legacy files as well in newer version-so trying to eliminate them this way doesn't work either (or at least didn't in 3.0, 3.1).
My guess is that importing 1.9X courses into 3.X has a number of challenges but I'm not versed well enough in this to answer this part specifically.
A clean installation avoids any particular legacy headaches though. Our site has been running since 1.8 or 1.9 and now is at 3.5.1 and I just recently found some more legacy issues (and fixed ultimately) that I hadn't noticed related to missing question types from before my time (Ken's helped with some others in the past).