Upgrade from 2.9.7 to 3.1.1 confuses

Re: Upgrade from 2.9.7 to 3.1.1 confuses

by Ken Task -
Number of replies: 0
Picture of Particularly helpful Moodlers

After re-reading ... it has dawned on me that maybe you ran just a git pull.   That will update current version to the highest in that series.

In order to 'upgrade' (which is different than 'update'), one has to issue the following commands *in the moodle code* directory:

git branch --track MOODLE_31_STABLE origin/MOODLE_31_STABLE
git checkout MOODLE_31_STABLE

While you at the command line, may as well finish the upgrade via command line:

git branch -a

should show the tracked branch is now the one you desire to upgrade to.

IF that's true:

php admin/cli/maintenance.php --enable (enables maintenance mode)

php admin/cli/upgrade.php --non-interactive

That will upgrade the DB.

Then take site out of maintenance mode:

php admin/cli/maintenance.php --disable

Make sure the files/folders belong to apache user group ... or however you set setup (ugh, jail user).

One could also purge the caches ... might need to do this ..

php admin/cli/purge_caches.php (takes no parameters/swtches)

Then hit the site with a browser, login and check things.

'spirit of sharing', Ken