Moodle 5.2 available now! Start enjoying the cool features of the latest and greatest version of Moodle in four easy steps...
Step 1: Make sure that your server can run Moodle 5.2
| Warning: The directory structure of Moodle files has changed in 5.1. A new "public" folder has been introduced to contain all web accessible files. Configuration and other sensitive files are now stored below this folder for better security. You will need to reconfigure your web server to accommodate this change as part of the upgrade process. See Upgrading - Code directories restructure. |
Go to Site administration > Server > Environment.
Status OK for everything? Great! Go to step 2...
Any problems? You probably need to upgrade your server software (such as PHP) to a more recent version.
Step 2: Be prepared!
As usual with any large upgrade, you should always be prepared to "roll back" if there's an issue with your data or some custom code you've added.
- A test install
- We highly advise you make a copy of your production site to practice the upgrade on first. That way, if you run into any problems that need fixing you won't affect your main site.
- Always make backups
- When upgrading your production instance, make sure you have copies of everything, just in case. Full instructions are here: Site backup.
Step 3: Replace your Moodle code
At this point you can replace the Moodle code on your server with the version you downloaded.
- Check plugins
- Any plugins you have installed will also to be replaced with a version for your new Moodle version. If there is not yet an updated version of the plugin available, it will need to be uninstalled before upgrading your site.
- Check your web server configuration
- A new
publicdirectory has been introduced to separate web accessible files from configuration and other sensitive files. Your web server must be configured to serve content only from this folder. The upgrade to Moodle 5.1 cannot proceed until this configuration is in place. For more information, see Upgrading - Code directories restructure.
Step 4: Perform the upgrade!
Trigger the upgrade by visiting the admin page.
If you have a large site this may take hours, so we recommend upgrading via command line.
Step 5: Check where your third party plugins are located
If you upgraded through git, then existing third party plugins are still located in their original locations, and will need to be shifted over to their respective areas in the /public directory structure.
How did you go?
- Yes - it worked!
- Great! Repeat the process for Moodle 5.2, and please post in the Installation help forum and share your success with the Moodle community!
- No - I had an error
- Don't worry, help is at hand. Post in the Installation help forum where our experts are waiting to explain any errors you obtain.
See also
- Upgrading for full details of the process
- Upgrading FAQ