Upgrading an old version of Moodle

Re: Upgrading an old version of Moodle

by Emma Richardson -
Number of replies: 2
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Ok, the easiest way I can think of is this:
1. Create a new VM with current Ubuntu build and PHP 5.6.
2. Migrate your Moodle installation to the new VM.
3. Get it up and running (follow migration instructions)
4. Then start the upgrade process.
Average of ratings: Useful (3)
In reply to Emma Richardson

Re: Upgrading an old version of Moodle

by Aurélie Merckx -

Hi everyone!

I'm picking this up from Feb since I've finally found how to complete this upgrade (& the time to do it).

So here's how I proceeded - if this may help anyone in the future.

1) Backup the old Moodle 3.0 (see backup & restore moodle documentation)

2) setup a new server (in my case a VM but that's not very relevant here, could juts as well be a physical server, dedicated one...) with the latest version of Ubuntu (I took 18.04 Bionic Beaver, will have to update to 20.04 soon... ) 

3) Restore the backed up moodle on the new server

4) Install PHP: That's where it got a little tricky since php 5.6 wouldn't come out of the box with ubuntu 18.04 so I've followed this link https://askubuntu.com/questions/1048581/install-php5-on-ubuntu-18-04
I've also had to specify php5.6 when installing the php extensions required for Moodle (ex: apt install php5.6-curl)

5) Start the upgrade process.

The upgrade process wasn't super straight forward due to the change in php versions. So I've proceeded in steps, and here's what I ended up doing, which worked well:

  1. Upgrade Moodle 3.0 -> 3.2
  2. Upgrade php 5.6 -> 7.1
  3. Upgrade moodle 3.2 -> 3.8
  4. Upgrade php 7.1 -> 7.4

Tada!! Moodle 3.8 running on ubuntu 18.04 with php 7.4 !😁😁😁😁😁

I have to admit I was super pleased by how smoothly moodle upgrade ran, as I didn't have any problems during the process, once I figured out how to tell apache which  version of php to use (see here https://stackoverflow.com/questions/42619312/switch-php-versions-on-commandline-ubuntu-16-04)

Great job done by the moodle comunity!

Thanks to all of you for your comments and very helpful pointers!

Aurélie

Average of ratings: Useful (1)