Re: Can't update Moodle Database
Re: Trouble Migrating Moodle v3.10.3
https://moodle.org/mod/forum/discuss.php?d=425811#p1714817
Re: Can't update Moodle Database
Upgrade Trouble Igbinary version
Performed all of the plugin updates. Checked the Environment one last time, and got this:
As yet, the link for more info is empty. Please advise.
Re: Upgrade Trouble Igbinary version
What versions of PHP/Moodle do you have and on what platform (planet)?
Is there an environment.xml file in /admin/ of your moodle code?
You should have php extensions for xml and xmlreader as well as libxml.
php -m |grep xml
'SoS', Ken
Re: Upgrade Trouble Igbinary version
Follow up ...
using command line and in the code directory, execute:
fgrep igbinary admin/environment.xml
That should return the following:
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_igbinary322_version" level="optional">
<ON_CHECK message="igbinary322buggyversion" />
<CUSTOM_CHECK file="lib/upgradelib.php" function="check_igbinary322_version" level="optional">
<ON_CHECK message="igbinary322buggyversion" />
One more command from same location:
fgrep '$release' version.php
That will/should show with the code you have:
$release = '4.0dev (Build: 20210827)'; // Human-friendly version name
Note the 'bolded' above.
So if your intent is to upgrade whatever version you have of moodle to a 4.0dev version, that igbinary322 version check is right on target but see 'buggy' in there .... uhhh ... not good!
Maybe there will be a new requirement for 4.0 when released for igbinary, but if you are just trying to upgrade code to a supported version ... like 3.11.highest ... you need to acquire the 3.11.highest code.
'SoS', Ken
Warning message during installation
I had almost completed the installation of Moodle on my PC Localhost after quite a long process and this Warning message came up and stopped. I managed to continue but I am wondering what should be done if anythging? Any help would be appreciated. I am sure it something simple but I can't find any information on it.
I looked in the 1340 line of the setuplib.php file but that offered me no insights.
Warning: preg_match(): Allocation of JIT memory failed, PCRE JIT will be disabled. This is likely caused by security restrictions. Either grant PHP permission to allocate executable memory, or set pcre.jit=0 in C:\xampp\htdocs\moodle\lib\setuplib.php on line 1340
Thanks in advance. Rob Beckett
Re: Warning message during installation
pcre.jit=0
in your php.ini file and restart. I have never used XAMPP so I can't tell you how to find php.ini but I assume Google will know.
'Unable to connect to the download server' and r'eason code: remoteunavailable' errors
Using Moodle v3.9.9, OpenSuse Linux Leap 15.3, Apache/2.4.43.
I get "Unable to connect to the downloadserver" for both language pack:
"Unable to connect to the download server. It is not possible to install or update the language packs automatically.
Please download the appropriate ZIP file(s) from https://download.moodle.org/langpack/3.9/
and unzip them manually to your data directory /moodledata/lang/"
Also error when installing plugins automatically from repo:
"However, the plugin installation pre-check failed (reason code: remoteunavailable)."
I checked this page:
https://docs.moodle.org/39/en/SSL_certificate_for_moodle.org
but I was not able to fix the problem.
Any idea what may be the problem? How can I debug it?
Re: Can't update Moodle Database
Re: Upgrade Trouble Igbinary version
I’m @ 3.9.4, trying to get to 3.11 Stable. The error I received occurred from an ‘update component’ on the environment page with 3.11 selected. I had previously gone through several rounds of plugin updates, and was doing one last environment check/plug-in check. So I’m not understanding where 4.0dev comes into this. I am a greenhorn with Moodle/Git though.
3.4.9 Apache/Cent 7
Yes to the environment.xml
Yes to the xml files
fgrep returned nothing
3.9.4 for the $release
Re: Upgrade Trouble Igbinary version
Hope you began this update/upgrade by making a minimal site backup of code and DB dump. 'Under the gun' sounds like you did this on production server without first testing on a dev instance/clone of your production. :|
Have a 3.9.highest and just now did environment check and updated component. No such error nor recommendation for igbinary in the check for 3.11.
The only place I can find such a check is in the case of having 4.0Dev code. The environment check updated in my 3.9.highest does list a 4.0 version, but when selecting that, no igbinary check or warning. None for the drop down set to 3.11 either.
Since you are using git, mind describing how you are trying to upgrade from your 3.9.x to 3.11.highest using git? And was the 3.9.x you have originally installed via git?
The actual git commands (hint: command line 'history' command might help you re-call).
Do these commands however ... and share back what you see ...
cd /path/to/moodlecode/
fgrep '$release' version.php
That will show us what version of code you have.
git branch -a |grep '*'
will show what branch your git is currently tracking.
'SoS', Ken
Re: Upgrade Trouble Igbinary version
I'm not sure if it was originally updated/installed through Git, this is a project I inherited. As for my process: I go to plugins overview and choose to install updates on all, select 'update moodle database', keep checking until no more updates. Move to Environment check, and select 3.11 in dropdown (4.0 dev was not there until this morning). I stop here because of the error I posted up top. However, before I knew about the 'update component' on the env. check page I thought all items were good, so I proceeded to the CLI upgrade:
$ cd /path/to/your/webroot
$ git clone git://git.moodle.org/moodle.git
$ cd moodle
$ git branch -a
$ git branch --track MOODLE_311_STABLE origin/MOODLE_311_STABLE
$ git checkout MOODLE_311_STABLE
$git pull - which gives me:
remote: Counting objects: 664, done.
remote: Compressing objects: 100% (146/146), done.
remote: Total 664 (delta 479), reused 663 (delta 478)
Receiving objects: 100% (664/664), 142.65 KiB | 0 bytes/s, done.
Resolving deltas: 100% (479/479), completed with 140 local objects.
From git://git.moodle.org/moodle
$release = '3.9.4 (Build: 20210118)'; // Human-friendly version name
git branch -a | grep '*'
* MOODLE_39_STABLE
Re: Upgrade Trouble Igbinary version
If the site was already installed using git and a 3.9.something, one would NOT need to use the following:
$ git clone git://git.moodle.org/moodle.git
$ cd moodle
You've already the code and just need to update or upgrade.
To update
cd /path/to/moodlecode/
git branch -a
php admin/cli/cron.php;
php admin/cli/maintenance.php --enable;
git pull;
php admin/cli/upgrade.php --non-interactive;
php admin/cli/maintenance.php --disable;
The git pull above should show something like (just did this a minute ago):
remote: Counting objects: 4475, done.
remote: Compressing objects: 100% (1900/1900), done.
remote: Total 4475 (delta 2628), reused 3581 (delta 2405)
Receiving objects: 100% (4475/4475), 3.73 MiB | 2.89 MiB/s, done.
Resolving deltas: 100% (2628/2628), done.
From git://git.moodle.org/moodle
c66c1a0..089f5bb MOODLE_39_STABLE -> origin/MOODLE_39_STABLE
3a3060a..3e69001 MOODLE_310_STABLE -> origin/MOODLE_310_STABLE
605ce278..7fdf72a MOODLE_311_STABLE -> origin/MOODLE_311_STABLE
0d0e66d..443a980 master -> origin/master
Updating c66c1a0..089f5bb
Fast-forward
.github/workflows/push.yml | 8 +
admin/environment.xml | 10 +
admin/tests/behat/behat_admin.php | 7 +-
admin/tool/dataprivacy/tests/behat/manage_data_requests.feature | 6 +-
admin/tool/log/stores.php | 2 +
admin/tool/log/tests/behat/logstore_store_visibility_change.feature | 19 +
auth/tests/behat/login.feature | 4 +-
backup/controller/backup_controller.class.php | 9 +
backup/controller/restore_controller.class.php | 9 +
backup/moodle2/restore_stepslib.php | 5 +-
backup/tests/roles_backup_restore_test.php | 179 +++++
backup/util/plan/base_plan.class.php | 13 +
backup/util/ui/tests/behat/duplicate_activities.feature | 6 +-
blocks/site_main_menu/tests/behat/edit_activities.feature | 4 +-
blocks/social_activities/tests/behat/edit_activities.feature | 4 +-
course/tests/behat/activities_visibility_icons.feature | 4 +-
course/tests/behat/activity_navigation.feature | 4 +-
course/tests/behat/add_activities.feature | 19 +-
course/tests/behat/course_relativedatesmode.feature | 13 +-
course/tests/behat/course_request.feature | 6 +-
install/lang/es/install.php | 12 +-
install/lang/fi/admin.php | 1 +
install/lang/pt/admin.php | 4 +-
install/lang/sl/install.php | 1 +
lang/en/admin.php | 1 +
lib/db/access.php | 3 +
lib/tests/behat/behat_general.php | 11 +-
lib/upgradelib.php | 53 ++
mod/feedback/tests/behat/anonymous.feature | 8 +-
mod/h5pactivity/tests/behat/result_fillin.feature | 6 +-
mod/h5pactivity/tests/behat/result_longfillin.feature | 6 +-
npm-shrinkwrap.json | 1422 ++++++++++++++++++++--------------
package.json | 6 +-
report/participation/tests/behat/message_participants.feature | 23 +-
user/tests/behat/user_grade_navigation.feature | 8 +-
version.php | 4 +-
36 files changed, 1224 insertions(+), 676 deletions(-)
create mode 100644 admin/tool/log/tests/behat/logstore_store_visibility_change.feature
create mode 100644 backup/tests/roles_backup_restore_test.php
Note 2 things ... second line of git pull shows it acquired a new environment.xml
admin/environment.xml
and the last line shows an update to version.php
The summary:
36 files changed, 1224 insertions(+), 676 deletions(-)
create mode 100644 admin/tool/log/tests/behat/logstore_store_visibility_change.feature
create mode 100644 backup/tests/roles_backup_restore_test.php
If you did this for a 3.9 site, you should be getting the highest available 3.9 which is $release = '3.9.9+ (Build: 20210902)'
To upgrade an existing 3.9 ... the following shows just one hop up to 310.
php admin/cli/maintenance.php --enable;
git branch --track MOODLE_310_STABLE origin/MOODLE_310_STABLE
git checkout MOODLE_310_STABLE
php admin/cli/upgrade.php --non-interactive;
php admin/cli/maintenance.php --disable;
And then check:
fgrep '$release' version.php
I have a preference for not doing hyperjumps ... skipping versions to a destination version ... but rather 'marching' .... up one version at a time ... checking site/acquiring updates to plugins, site backup again, then next hop.
Takes a little longer, but better me thinks.
'SoS', Ken
Re: Upgrade Trouble Igbinary version
MOODLE_310_STABLE
* MOODLE_39_STABLE
master
remotes/origin/HEAD -> origin/master
remotes/origin/MOODLE_13_STABLE
remotes/origin/MOODLE_14_STABLE, etc...
php admin/cli/cron.php;
Server Time: Thu, 02 Sep 2021 10:46:26 -0700
Ran 0 adhoc tasks found at Thu, 02 Sep 2021 10:46:26 -0700
Cron script completed correctly
Cron completed at 10:46:26. Memory used 18.7MB.
Execution took 0.058206 seconds
php admin/cli/maintenance.php --enable
== Maintenance mode (https://elearntest.mcoe.org) ==
Your site is currently in CLI maintenance mode, no web access is allowed.
git pull;
Updating de301d4..089f5bb
error: Your local changes to the following files would be overwritten by merge:
Gruntfile.js
TRADEMARK.txt
admin/cli/mysql_collation.php
admin/cli/mysql_compressed_rows.php
admin/environment.xml
admin/tests/behat/behat_admin.php, etc.....
...
blocks/activity_results/tests/behat/lowscoreswithoutgroups.feat
Aborting
And that's as far as I get. I did not see a /moodle subdir of the wwwroot on production server. I suppose that means it was not upgraded with git. Same was true for test server until I ran the commands I shared earlier with the git clone...
Upon running the second stack of commands I get as far as git checkout... with this result:
admin/tool/log/tests/privacy_test.php
admin/tool/log/upgrade.txt
admin/tool/log/v
Aborting
Re: Upgrade Trouble Igbinary version
Does it matter if git was not used previously?
Re: Upgrade Trouble Igbinary version
Does it matter? Yes.
The git branch -a command shows at the top which branch is being tracked ... marked with a *.
In the code directory ... which on centos 7 is probably in /var/www/html/ ... there should be a hidden .git directory.
cd /var/www/html/
ls -ld .git
Inside that hidden directory:
cd .git
ls -l
drwxr-xr-x. 2 root root 4096 Jun 22 2020 branches
-rw-r--r--. 1 root root 338 Jun 22 2020 config
-rw-r--r--. 1 root root 73 Jun 22 2020 description
-rw-r--r--. 1 root root 3339 Sep 2 11:57 FETCH_HEAD
-rw-r--r--. 1 root root 33 Jun 22 2020 HEAD
drwxr-xr-x. 2 root root 4096 Jun 22 2020 hooks
-rw-r--r--. 1 root root 2375232 Sep 2 11:57 index
drwxr-xr-x. 2 root root 4096 Jun 22 2020 info
drwxr-xr-x. 3 root root 4096 Jun 22 2020 logs
drwxr-xr-x. 4 root root 4096 Jun 22 2020 objects
-rw-r--r--. 1 root root 41 Sep 2 11:57 ORIG_HEAD
-rw-r--r--. 1 root root 38716 Jun 22 2020 packed-refs
drwxr-xr-x. 5 root root 4096 Jun 22 2020 refs
Your other posting that aborted and complained about merge would change ... then it listed files ...
Git does track every file ... including it's bite size ... it knows if a file has been edited. So did the former admin hack any core code?
'SoS', Ken
Re: Upgrade Trouble Igbinary version
Sent you a private message here in these forums - contains my cell number.
I see that both production and your test instance are in maintenance mode. So is your entity expecting the production instance to be upgraded soon?
Using forums is delayed ... and communications can be behind in sequence ... in this case, a voice call might be 'just in time' support.
'SoS', Ken
Re: Automated and Manual backups do not finish
Well the short version of the answer resides in 32 old H5P Course presentations activities created with 1.16 Libraries .
After a 12 round boxing match, I managed to update quite a few of them and deleting them from the course and editing the locally stored versions on an external Live Moodle installation and re- introducing them back as activities I was able to finish a MANUAL backup of each course on my Sinology NAS Moodle 3.9 installation with H5P framework v1.24 (h5plib_v124) but even this one indicates on plugins overview h5p
qformat_h5p 2020071508 Disabled Uninstall
BUT the course still do not backup on my 3.11.2 Live Moodle installation.
Further on this subject, after ll this I got this useless message from my live 3.11.2 Moodle installation
MOODLE online version ERROR
Error reading from database
Coding error detected, it must be fixed by a programmer: block_manager has not yet loaded the blocks, to it is too soon to request the information you asked for.
NO IDEA WHAT THIS MESSAGE IMPLIES...
No coding has been altered in any form so.
Back to square one.
Thanks
Beto Boton