Update to version 4.1.4 not possible

Update to version 4.1.4 not possible

by Robin Köhler -
Number of replies: 10
Hello!
I have the problem that I can not upgrade Moodle 4.1.3 to 4.1.4 via Linux/SSH?
Command:
" $ sudo -u apache /usr/bin/php admin/cli/upgrade.php --non-interactive"
-> "No upgrade is necessary for the installed version 4.1.3 (build: 20230424) (2022112803). Thanks for trying!"

Does anyone have any ideas?
Thanks Robin
Average of ratings: -
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
You need to change the code for the 4.1.4 version, first. The upgrade script doesn't do that for up.

See Upgrading

Setting up Moodle with Git makes this very easy. It's then just 'git pull' followed by the above command. 
In reply to Howard Miller

Re: Update to version 4.1.4 not possible

by Robin Köhler -
Thanks very much for your help.
I'm new with Moodle.
What do you mean with "change the code for the 4.1.4 version" ?
I did a backup of the important files.
Which command do I have to run now?
Thanks Robin
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Did you "See Upgrading"?

You need to download 4.1.4 and replace your existing code with the new code. Keep the existing config.php. THEN run that command.

The upgrade script does all the database migrations and suchlike for the upgrade. It *does not* download the new code. You have to do that manually.

But please read the upgrading instructions for lots more detail.
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
I never use these "wonder scripts". Are you sure that it fetches the 4.1.4 source?

The conventional routine is Upgrading#Install_the_new_Moodle_software.
In reply to Visvanath Ratnaweera

Re: Update to version 4.1.4 not possible

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
That's the core upgrade script. It definitely *does not* fetch the source.
Average of ratings:Useful (1)
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Ken Task -
Picture of Particularly helpful Moodlers
+1 to Howard's suggestion about using git ... I'd call 'scripted' updates 'wonderous'!

Following is a 'plug for using Git' ...

Using Git there are no human (prone to error) 'moving parts' ... folks do forget or don't know what plugins they have installed!

Git changes files that need changing, removes files no longer needed, and acquires new files that are needed.

It shows all that.

The one thing Git lacks, moosh provides ... checking version of plugins - and if there is a plugin that is compat with core version.   That still has to be handled by a human.

My 2 cents!

'SoS', Ken

In reply to Ken Task

Re: Update to version 4.1.4 not possible

by Robin Köhler -
how is the command to update Moodle via moosh?
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
I must admit - I didn't think there was anything in Moosh to update Moodle.

What it does have is a bunch of commands to work with additional plugins. I'm not sure they are entirely useful to you. More if you are scripting upgrades for multiple sites.
In reply to Robin Köhler

Re: Update to version 4.1.4 not possible

by Ken Task -
Picture of Particularly helpful Moodlers
Again, + 1 to Howard's response.
Additional ... if you change into the code directory (moosh commands have to be issued in the code directory), and issue:

moosh -n --list-commands

You will be provided with all the moosh commands one could issue ... upgrading is not one of them.

Since we are talking about a point release to your production server, might be wise to install another 4.0 version instance of moodle in a subdomain of your site via git (dev.sametopleveldomain.whatever - or something like that).  Once dev site is running you could then practice upgrading to 4.1.highest via git to acquire code and then command line scripts in /admin/cli/ of that code to do the upgrade.

'SoS', Ken