As we know that moodle is one of the powerful learning management platforms. As the community is growing the threat of exploiters also increase. In this blog I will discuss about the up-gradation of moodle from 1.9 to 2.2. This is a major version upgrade. I will give you a step by step guide to a clean upgrade. Please follow the steps below and make sure you don’t miss anything.
- Put your current moodle site on maintenance mode.
- Backup everything
- Database in this case we have MySQL database and the command you have to use for the backup is mysqldump –u username -ppassword dbname > dbname.sql
- Now backup the moodle data folder you can find the location form the config.php in the moodle root directory. Parameter is $CFG->dataroot = ‘/opt/moodledata’;
- Execute tar zcvf moodledata.tgz /opt/moodledata
- Copy the new moodle version 2.2
- If moodle url is changed please execute this command
sed -e 's/oldserver.com/newserver.com/g' dbname.sql > newdbname.sql - Restore the database and moodle data and change the configuration file
- Change the config file
$CFG->wwwroot Restore the databasemysql –u username -ppassword dbname < dbname.sql (newdbname.sql in case the url is changed)Open the urlhttp://servernameAn auto update script will run.
- Change the config file
That’s it you have successfully upgrade the moodle from version 1.9 to 2.2. Now you can enjoy the new features of moodle 2.2



