Upgrading when you have plugin

Upgrading when you have plugin

by M. Degrange -
Number of replies: 7

Hi,

How are we supposed to do major upgrade when we have plugin (installed directly from moodle) ?

As written in docs, just copying new file in the moodle folder doesn't work because it will not remove old file (and this will raise the mixed moodle version error).

The docs say « If you have Automatic updates deployment enabled, you will be able to update installed plugins automatically during the upgrade. » and « If you are updating plugins manually, it is a good moment now to check in the Moodle Plugins directory whether there is a 3.9 version available for any plugins (including themes) that you have previously installed on your site. If so, download the plugin package. In the next step, you will copy it to the appropriate location in your Moodle code (see Installing plugins). »

As I am using automatic install, I shouldn't be concerned by the manual part, right ?

But after we can found : "As mentioned above, if you had installed any plugins on your site you should add them to the new code tree". So is the part about getting plugin code also true for people installing plugin automatically ?

I tried deleting all moodle file except config.php, moving new moodle file, and putting back config.php but during the install moodle tell me plugin are missing from disk.

Does this means that even if you install plugin automatically, you have to do it manually when you update moodle ?

I also tried moving the mod folder from old moodle to new moodle but I am still having the missing plugin issue.

So am I forced to download each of my installed plugin to paste them manually in the new moodle (which will take me lots of time) ? Or am I missing something ?

Thanks.

Ps : I am just training myself to upgrade my local moodle (wamp server) to the moodle dev channel (v4) in order to be ready for doing the v3.9 upgrade on my real website.

Average of ratings: -
In reply to M. Degrange

Re: Upgrading when you have plugin

by Ken Task -
Picture of Particularly helpful Moodlers

Re-read:

https://docs.moodle.org/38/en/Upgrading

Standard install package section, where it says:
"Move your old Moodle software program files to another location. Do NOT copy new files over the old files.
Unzip or unpack the upgrade file so that all the new Moodle software program files are in the location the old files used to be in on the server. Moodle will adjust SQL and moodledata if it needs to in the upgrade.
Copy your old config.php file back to the new Moodle directory.
As mentioned above, if you had installed any plugins on your site you should add them to the new code tree (Moodle directory structure) now. It is important to check that you get the correct version for your new version of Moodle
."

'SoS', Ken


In reply to Ken Task

Re: Upgrading when you have plugin

by M. Degrange -
The thing is "as mentioned above", which refer to something under the "if you update plugin manually". So if this doesn't depend of way we update plugin, it need to be rewritten.

So if I understand, I need to manually redownload all plugin ? This means it's easier to always install plugin manually and not use the automatic tool because that way we can keep every plugin downloaded in a folder to just copy it when we upgrade.
In reply to M. Degrange

Re: Upgrading when you have plugin

by Ken Task -
Picture of Particularly helpful Moodlers

If Doc is wrong re-write it ... but make sure what you say covers it all.   By that I mean this ... I don't use Windows nor the doc for upgrading.

I do host using Linux.   Install and maintain moodles with git.

https://docs.moodle.org/38/en/Git_for_Administrators

Core code doesn't move ... config.php file isn't moved.   A simple git pull or a couple of git commands to set branch and acquire new branch code and then using other cli scripts in admin/cli/ of code does updates or upgrades ... less prone to mis-understanding docs and human error.

Also have a command line utility called moosh where I can run a listing of my plugins through a looping bash shell script to check and acquire any updates to the addons I've installed.

I prefer to do that manually, but since you are Windows you can use the plugins check and upgrade just the plugins after your core has been upgraded (assuming there is an update for your plugins) in the Admin GUI.

You got 'missing from disk' cause you misunderstood the directions.   All is not lost ... just re-install the plugins ... with versions that are now compat with core.

Next time ... plan your work ... work your plan.

We pick our poisons  and learn our antedotes! smile

'SoS', Ken

In reply to Ken Task

Re: Upgrading when you have plugin

by M. Degrange -
Well I lost nothing because I have backup. In fact, it's the third time I try to update moodle to try to find the best way to do it.

I already have read the git page, but as I don't have installed moodle with git I can't do git command. But there is probably a git command to make it like if I installed moodle with git, I just have to find it :D
In reply to M. Degrange

Re: Upgrading when you have plugin

by Ken Task -
Picture of Particularly helpful Moodlers

Somewhere in a sea of documentation there is a recommendation that one clones production server and on the clone practice updates/upgrades.

So your production server is WAMP?

"I am just training myself to upgrade my local moodle (wamp server) to the moodle dev channel (v4) in order to be ready for doing the v3.9 upgrade on my real website."

Huh?

dev channel v4?   What is that?  It's on TV!!!!!  Channel 'v4'? and playing with that for doing a 3.9 upgrade from what current production version?    Got me there ... that's your 'plan'?!!!???

So you are 'playing' ...  a lot ... and learning ... the hard way? 

Lessons learned from what doesn't work do seem to make better synapse connections, don't they?   (question for thought, not answer)

Git on Windows, from what I hear, isn't good.   But ... tip for ya if ya wanna play some more ... 'side load'.  To add to your reading ... to do list ...

https://moodle.org/mod/forum/discuss.php?d=339683

Enjoy the 'journey'! smile

'SoS', Ken

In reply to Ken Task

Re: Upgrading when you have plugin

by Ken Task -
Picture of Particularly helpful Moodlers

Follow up ... yep, 3.9.0 released (and no RC's!!!!) so there is a 4.0dev branch now in moodle git repos.

Was there some discussion on 4.x that influenced your investigating  upgrading (changing forth coming in 4)?  Or are you just getting on leading edge?

'SoS', Ken

In reply to Ken Task

Re: Upgrading when you have plugin

by M. Degrange -

I wanted to install 3.9 but when I got on dev channel, it was already switched on v4 and normal channel was still 3.8. So I took v4 because I supposed that it was still mostly 3.9.