Forums | Mahara Community
Support
/
Upgrade Error from 19.04.7 to 19.10.6
01 December 2021, 22:45
Hello everyone!
In my university we ve been using mahara 15.04 for years and now I must upgrade to the topper version that I could get.
Im using Debian 8.11 with php 7.0 and mysql 5.5.62. Its the first time that Im working with mahara but, with some effort, I ve managed to upgrade to mahara 19.04.7.
My problem is that when I try to launch the upgrade to 19.10.6 from console it gives me this error.
[WAR] 0c (lib/errors.php:536) [ParseError]: syntax error, unexpected '?'
Call stack (most recent first):
* exception(object(ParseError)) at Unknown:0
A nonrecoverable error occurred. This probably means you have encountered a bug in the system
I had more problems before but in the other cases it always gave some kind of clue to start with, this time Im kind of stuck.
I apologize in advance, because maybe it is a really obvious question.
Could you help me please? If you need more info of the apps or the system just ask me for them.
Thanks in advance!!
Kepa
02 December 2021, 4:38
Hi again!!
I have discorvered that the last update dindt finish well too, when i try to open a embebed PDF o any other link in the page it gives me the same error. Help me please. Maybe I should start again from 15.04 o maybe some of the programs or versions that Im using are not the best for this. If you could recommend me a way to follow for updating and what version o PHP and mysql work better it would be nice!
Thanks in advance.
Kepa
02 December 2021, 15:31
Hi Kepa,
Sorry to hear about your upgrade issues. Can you please confirm a couple of things?
You are trying to upgrade Mahara 15.04 to Mahara 19.10. Did you make an intermediate upgrade to Mahara 17.04? You can't upgrade straight from 15.04 to 19.04 or 19.10.
We'd also recommend that you upgrade to Mahara 21.10 because 19.10 is no longer in support.
The upgrade process would then be: 15.04 → 17.04 → 19.10 → 21.10.
Please note that Mahara 19.04 and later require at minimum MySQL 5.7. If you continue with MySQL 5.5, you will run into problems. Mahara 21.10 should be used with PHP 7.2 at minimum, but 7.4 (or 7.3) is recommended.
Your error message is too generic at this stage to figure out what went wrong without additional information about your MySQL and upgrade process.
All the best for another upgrade attempt
Kristina
03 December 2021, 0:57
Hi!
Firstly thank you very much for your help!!
I ve made the updates in order but with the 18.X version in the middle, anyway now that I have a correct order and minimn versions of php and mysql I will start again from the begining following these steps. I guess that I should update php and mysql just after I ll get ver 19, am I right? Or is it posible to first update them and I after start with the mahara updates?
You ve been really helpful!
Thank you very much!!
Kepa
07 December 2021, 8:46
Hi Kepa,
You can do the code update and resolve merge conflicts in the code without needing a newer version of PHP or MySQL, but before you actually try to go to the upgraded site, your newer PHP and MySQL should be in place as Mahara runs through a number of database upgrades during the upgrade process. Please also refer to our upgrade guide.
The Mahara team releases two versions of Mahara each year: One in April (e.v. 21.04) and one in October (e.g. 21.10). The second number is important to know as our version numbering is a date based one like Ubuntu. The third number, e.g. 21.10.0 is the minor point update that often includes security updates. This is the number we recommend you not reveal in public forum posts so as not to give too many hints on in you have already patched your instance of Mahara or not. Please always include the first two numbers though as there are usually significant changes between versions.
Thank you
Kristina
09 December 2021, 4:15
Hello!!
I have tried again from the begining, now I have this problem, I have updated the server so now im using mariadb and php 7.4.
Could you help me please?
Thanks in advance.
[WAR] 7f (lib/view.php:1371) "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?
Call stack (most recent first):
* log_message(string(size 87), integer, true, true, string(size 43), integer) at /var/www/mahara-17.10.9/htdocs/lib/errors.php:521
* error(integer, string(size 87), string(size 43), integer, array(size 7)) at /var/www/mahara-17.10.9/htdocs/export/lib.php:14
* require_once() at /var/www/mahara-17.10.9/htdocs/export/lib.php:14
* require_once("/var/www/mahara-17.10.9/htdocs/export/lib.php") at /var/www/mahara-17.10.9/htdocs/lib/mahara.php:1545
* safe_require(string(size 6), string(size 4)) at /var/www/mahara-17.10.9/htdocs/lib/upgrade.php:1047
* validate_plugin(string(size 6), string(size 4)) at /var/www/mahara-17.10.9/htdocs/lib/upgrade.php:163
* check_upgrades() at /var/www/mahara-17.10.9/htdocs/admin/cli/upgrade.php:40
[INF] 7f (admin/cli/upgrade.php:49) Upgrading Mahara
[INF] 7f (lib/mahara.php:234) Upgrading core
[WAR] 7f (lib/errors.php:859) Failed to get a recordset: mysqli error: [1054: Unknown column 'time' in 'field list'] in EXECUTE("SELECT event, data, time
[WAR] 7f (lib/errors.php:859) FROM "event_log"
[WAR] 7f (lib/errors.php:859) WHERE event = 'createuser'
[WAR] 7f (lib/errors.php:859) AND POSITION(',"password":"",' IN data) = 0
[WAR] 7f (lib/errors.php:859) ")Command was: SELECT event, data, time
[WAR] 7f (lib/errors.php:859) FROM "event_log"
[WAR] 7f (lib/errors.php:859) WHERE event = ?
[WAR] 7f (lib/errors.php:859) AND POSITION(',"password":"",' IN data) = 0
[WAR] 7f (lib/errors.php:859) and values was (0:createuser)
Call stack (most recent first):
* log_message(string(size 693), integer, true, true) at /var/www/mahara-17.10.9/htdocs/lib/errors.php:95
* log_warn(string(size 693)) at /var/www/mahara-17.10.9/htdocs/lib/errors.php:859
* SQLException->__construct(string(size 693)) at /var/www/mahara-17.10.9/htdocs/lib/dml.php:517
* get_recordset_sql(string(size 269), array(size 1), string(size 0), string(size 0)) at /var/www/mahara-17.10.9/htdocs/lib/dml.php:714
* get_records_sql_array(string(size 269), array(size 1)) at /var/www/mahara-17.10.9/htdocs/lib/db/upgrade.php:47
* xmldb_core_upgrade(string(size 10)) at /var/www/mahara-17.10.9/htdocs/lib/upgrade.php:347
* upgrade_core(object(stdClass)) at /var/www/mahara-17.10.9/htdocs/lib/mahara.php:268
* upgrade_mahara(array(size 1)) at /var/www/mahara-17.10.9/htdocs/admin/cli/upgrade.php:53
[WAR] 7f (lib/dml.php:517) Failed to get a recordset: mysqli error: [1054: Unknown column 'time' in 'field list'] in EXECUTE("SELECT event, data, time
[WAR] 7f (lib/dml.php:517) FROM "event_log"
[WAR] 7f (lib/dml.php:517) WHERE event = 'createuser'
[WAR] 7f (lib/dml.php:517) AND POSITION(',"password":"",' IN data) = 0
[WAR] 7f (lib/dml.php:517) ")Command was: SELECT event, data, time
[WAR] 7f (lib/dml.php:517) FROM "event_log"
[WAR] 7f (lib/dml.php:517) WHERE event = ?
[WAR] 7f (lib/dml.php:517) AND POSITION(',"password":"",' IN data) = 0
[WAR] 7f (lib/dml.php:517) and values was (0:createuser)
Call stack (most recent first):
* get_recordset_sql() at /var/www/mahara-17.10.9/htdocs/lib/dml.php:714
* get_records_sql_array() at /var/www/mahara-17.10.9/htdocs/lib/db/upgrade.php:47
* xmldb_core_upgrade() at /var/www/mahara-17.10.9/htdocs/lib/upgrade.php:347
* upgrade_core() at /var/www/mahara-17.10.9/htdocs/lib/mahara.php:268
* upgrade_mahara() at /var/www/mahara-17.10.9/htdocs/admin/cli/upgrade.php:53
09 December 2021, 9:50
Hi Kepa,
The change at https://reviews.mahara.org/#/c/10245/ should fix your problem.
Just make the same change to your own code
Cheers
Robert
10 December 2021, 1:45
Hi!!
That have solved something, but I still having the this error. I hope you could help me please.
Thanks in advance.
[INF] 60 (admin/cli/upgrade.php:70) Upgrading Mahara
[INF] 60 (lib/mahara.php:240) Upgrading core
[WAR] 60 (lib/errors.php:859) Failed to get a recordset: mysqli error: [1054: Unknown column 'time' in 'field list'] in EXECUTE("SELECT event, data, time
[WAR] 60 (lib/errors.php:859) FROM "event_log"
[WAR] 60 (lib/errors.php:859) WHERE event = 'createuser'
[WAR] 60 (lib/errors.php:859) AND POSITION(',"password":"",' IN data) = 0
[WAR] 60 (lib/errors.php:859) ")Command was: SELECT event, data, time
[WAR] 60 (lib/errors.php:859) FROM "event_log"
[WAR] 60 (lib/errors.php:859) WHERE event = ?
[WAR] 60 (lib/errors.php:859) AND POSITION(',"password":"",' IN data) = 0
[WAR] 60 (lib/errors.php:859) and values was (0:createuser)
Call stack (most recent first):
* log_message(string(size 693), integer, true, true) at /var/www/mahara-19.10.6/htdocs/lib/errors.php:95
* log_warn(string(size 693)) at /var/www/mahara-19.10.6/htdocs/lib/errors.php:859
* SQLException->__construct(string(size 693)) at /var/www/mahara-19.10.6/htdocs/lib/dml.php:540
* get_recordset_sql(string(size 269), array(size 1), string(size 0), string(size 0)) at /var/www/mahara-19.10.6/htdocs/lib/dml.php:737
* get_records_sql_array(string(size 269), array(size 1)) at /var/www/mahara-19.10.6/htdocs/lib/db/upgrade.php:47
* xmldb_core_upgrade(string(size 10)) at /var/www/mahara-19.10.6/htdocs/lib/upgrade.php:376
* upgrade_core(object(stdClass)) at /var/www/mahara-19.10.6/htdocs/lib/mahara.php:274
* upgrade_mahara(array(size 1)) at /var/www/mahara-19.10.6/htdocs/admin/cli/upgrade.php:74
[WAR] 60 (lib/dml.php:540) Failed to get a recordset: mysqli error: [1054: Unknown column 'time' in 'field list'] in EXECUTE("SELECT event, data, time
[WAR] 60 (lib/dml.php:540) FROM "event_log"
[WAR] 60 (lib/dml.php:540) WHERE event = 'createuser'
[WAR] 60 (lib/dml.php:540) AND POSITION(',"password":"",' IN data) = 0
[WAR] 60 (lib/dml.php:540) ")Command was: SELECT event, data, time
[WAR] 60 (lib/dml.php:540) FROM "event_log"
[WAR] 60 (lib/dml.php:540) WHERE event = ?
[WAR] 60 (lib/dml.php:540) AND POSITION(',"password":"",' IN data) = 0
[WAR] 60 (lib/dml.php:540) and values was (0:createuser)
Call stack (most recent first):
* get_recordset_sql() at /var/www/mahara-19.10.6/htdocs/lib/dml.php:737
* get_records_sql_array() at /var/www/mahara-19.10.6/htdocs/lib/db/upgrade.php:47
* xmldb_core_upgrade() at /var/www/mahara-19.10.6/htdocs/lib/upgrade.php:376
* upgrade_core() at /var/www/mahara-19.10.6/htdocs/lib/mahara.php:274
* upgrade_mahara() at /var/www/mahara-19.10.6/htdocs/admin/cli/upgrade.php:74
10 December 2021, 3:21
Hi!
I think i ve solved last error but I have another one. Dont know whats wrong with my DB :(.
Sorry for the continuos comments.
Thanks in advance.
root@mahara02:/var/www# sudo -u www-data /usr/bin/php7.4 mahara/admin/cli/upgrade.php -v
[INF] a3 (admin/cli/upgrade.php:70) Upgrading Mahara
[INF] a3 (lib/mahara.php:240) Upgrading core
[DBG] a3 (lib/db/upgrade.php:85) Add new logoxs column in institution table for small logos
[DBG] a3 (lib/db/upgrade.php:126) Fix up missing creation time for users
[DBG] a3 (lib/db/upgrade.php:138) Fix missing property in group Forums
[DBG] a3 (lib/db/upgrade.php:161) Clear menu cache for removal of menu items
[DBG] a3 (lib/db/upgrade.php:166) Add new fields to "event_log" table
[DBG] a3 (lib/db/upgrade.php:233) Adjust existing "event_log" data to fit new table structure
[DBG] a3 (lib/db/upgrade.php:375) Loop through all records and adjust
[DBG] a3 (lib/db/upgrade.php:451) Add new logging events
[DBG] a3 (lib/db/upgrade.php:469) Remove obsolete default notification method
[DBG] a3 (lib/db/upgrade.php:506) Removing "Persona" authentication plugin
[DBG] a3 (lib/db/upgrade.php:514) Clear all caches to allow regeneration of session directories
[DBG] a3 (lib/db/upgrade.php:519) Add primary key to site_content table
[DBG] a3 (lib/db/upgrade.php:593) Add an "useragent" field to usr_session table
[DBG] a3 (lib/db/upgrade.php:604) Remove MaharaDroid configurations
[DBG] a3 (lib/db/upgrade.php:613) Add Voki filters to DB
[INF] a3 (lib/upgrade.php:1283) Enabled 3 HTML filters.
[DBG] a3 (lib/db/upgrade.php:618) Anonymising remaining deleted user data
[DBG] a3 (lib/db/upgrade.php:627) Adding new event type "userleavesgroup"
[DBG] a3 (lib/db/upgrade.php:635) Make site_content mauthor field have a user id by defaut
[DBG] a3 (lib/db/upgrade.php:653) Create "site_content_version" table
[DBG] a3 (lib/mahara.php:2223) Table site_content_version exists. Create skipped
[DBG] a3 (lib/mahara.php:2223) Table site_content_version exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:674) Move the site and institution Privacy statement from the site_content table to the site_content_version table
[DBG] a3 (lib/db/upgrade.php:696) Create "usr_agreement" table
[DBG] a3 (lib/mahara.php:2223) Table usr_agreement exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:715) Auto accept the privacy agreement for all site admins
[DBG] a3 (lib/db/upgrade.php:724) Move the site and institution terms and conditions from the site_content table to the site_content_version table
[DBG] a3 (lib/db/upgrade.php:745) Auto accept the terms and conditions for all site admins
[DBG] a3 (lib/db/upgrade.php:754) Remove privacy statement and T&C conditions custom links from footer
[DBG] a3 (lib/db/upgrade.php:773) Add an "usr_pendingdeletion" table
[DBG] a3 (lib/mahara.php:2223) Table usr_pendingdeletion exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:786) Clean old alwaysallowselfdelete configuration setting
[DBG] a3 (lib/db/upgrade.php:791) Remove auto-added users from deleted groups if added post deletion
[DBG] a3 (lib/db/upgrade.php:804) Combine footer links T&C and Privacy into Legal link
[DBG] a3 (lib/db/upgrade.php:828) Removing confusing blockinstance title information
[DBG] a3 (lib/db/upgrade.php:833) Add "manualhelp" as a default footer link
[DBG] a3 (lib/db/upgrade.php:844) Create a new "unsubscribetoken" field in "usr_watchlist_view" table
[DBG] a3 (lib/mahara.php:2223) Field unsubscribetoken exists. Create skipped
[DBG] a3 (lib/mahara.php:2223) Index unsubscribetokenix exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:856) Upgrade artefact/file plugin
[DBG] a3 (lib/db/upgrade.php:877) Change the artefactid (integer) in the configdata of the existing plan blocktypes to artefactids (array). This change will allow plan blocktypes to contain more than one plan.
[DBG] a3 (lib/db/upgrade.php:905) Create new "existingcopy" table to map who already has what.
[DBG] a3 (lib/mahara.php:2223) Table existingcopy exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:923) Adding new event type "userchangegrouprole"
[DBG] a3 (lib/db/upgrade.php:931) Add a "tags" field to the institution table
[DBG] a3 (lib/db/upgrade.php:941) Add a "tag" table to migrate all the tag information to
[DBG] a3 (lib/mahara.php:2223) Table tag exists. Create skipped
[DBG] a3 (lib/db/upgrade.php:957) Move the data from the old *_tag tables
[DBG] a3 (lib/dml.php:180) mysqli error: [1146: Table 'mahara.artefact_tag' doesn't exist] in EXECUTE("INSERT INTO "tag" (tag,resourcetype,resourceid,ownertype,ownerid,editedby,ctime,mtime)
[DBG] a3 (lib/dml.php:180) SELECT xt.tag, 'artefact' AS resourcetype, xt.artefact AS resourceid,
[DBG] a3 (lib/dml.php:180) CASE WHEN x.owner IS NOT NULL THEN 'user'
[DBG] a3 (lib/dml.php:180) WHEN x.group IS NOT NULL THEN 'group'
[DBG] a3 (lib/dml.php:180) ELSE 'institution'
[DBG] a3 (lib/dml.php:180) END AS ownertype,
[DBG] a3 (lib/dml.php:180) CASE WHEN x.owner IS NOT NULL THEN x.owner
[DBG] a3 (lib/dml.php:180) WHEN x.group IS NOT NULL THEN x.group
[DBG] a3 (lib/dml.php:180) ELSE x.institution
[DBG] a3 (lib/dml.php:180) END AS ownerid,
[DBG] a3 (lib/dml.php:180) NULL AS editedby, x.ctime AS ctime, x.mtime AS mtime
[DBG] a3 (lib/dml.php:180) FROM "artefact_tag" xt
[DBG] a3 (lib/dml.php:180) JOIN "artefact" x ON x.id = xt.artefact")Command was: INSERT INTO "tag" (tag,resourcetype,resourceid,ownertype,ownerid,editedby,ctime,mtime)
[DBG] a3 (lib/dml.php:180) SELECT xt.tag, 'artefact' AS resourcetype, xt.artefact AS resourceid,
[DBG] a3 (lib/dml.php:180) CASE WHEN x.owner IS NOT NULL THEN 'user'
[DBG] a3 (lib/dml.php:180) WHEN x.group IS NOT NULL THEN 'group'
[DBG] a3 (lib/dml.php:180) ELSE 'institution'
[DBG] a3 (lib/dml.php:180) END AS ownertype,
[DBG] a3 (lib/dml.php:180) CASE WHEN x.owner IS NOT NULL THEN x.owner
[DBG] a3 (lib/dml.php:180) WHEN x.group IS NOT NULL THEN x.group
[DBG] a3 (lib/dml.php:180) ELSE x.institution
[DBG] a3 (lib/dml.php:180) END AS ownerid,
[DBG] a3 (lib/dml.php:180) NULL AS editedby, x.ctime AS ctime, x.mtime AS mtime
[DBG] a3 (lib/dml.php:180) FROM "artefact_tag" xt
[DBG] a3 (lib/dml.php:180) JOIN "artefact" x ON x.id = xt.artefact
[WAR] a3 (lib/errors.php:859) Could not execute command: INSERT INTO "tag" (tag,resourcetype,resourceid,ownertype,ownerid,editedby,ctime,mtime)
[WAR] a3 (lib/errors.php:859) SELECT xt.tag, 'artefact' AS resourcetype, xt.artefact AS resourceid,
[WAR] a3 (lib/errors.php:859) CASE WHEN x.owner IS NOT NULL THEN 'user'
[WAR] a3 (lib/errors.php:859) WHEN x.group IS NOT NULL THEN 'group'
[WAR] a3 (lib/errors.php:859) ELSE 'institution'
[WAR] a3 (lib/errors.php:859) END AS ownertype,
[WAR] a3 (lib/errors.php:859) CASE WHEN x.owner IS NOT NULL THEN x.owner
[WAR] a3 (lib/errors.php:859) WHEN x.group IS NOT NULL THEN x.group
[WAR] a3 (lib/errors.php:859) ELSE x.institution
[WAR] a3 (lib/errors.php:859) END AS ownerid,
[WAR] a3 (lib/errors.php:859) NULL AS editedby, x.ctime AS ctime, x.mtime AS mtime
[WAR] a3 (lib/errors.php:859) FROM "artefact_tag" xt
[WAR] a3 (lib/errors.php:859) JOIN "artefact" x ON x.id = xt.artefact
Call stack (most recent first):
* log_message(string(size 963), integer, true, true) at /var/www/mahara-19.10.6/htdocs/lib/errors.php:95
* log_warn(string(size 963)) at /var/www/mahara-19.10.6/htdocs/lib/errors.php:859
* SQLException->__construct(string(size 963)) at /var/www/mahara-19.10.6/htdocs/lib/dml.php:181
* execute_sql(string(size 936)) at /var/www/mahara-19.10.6/htdocs/lib/db/upgrade.php:973
* xmldb_core_upgrade(string(size 10)) at /var/www/mahara-19.10.6/htdocs/lib/upgrade.php:376
* upgrade_core(object(stdClass)) at /var/www/mahara-19.10.6/htdocs/lib/mahara.php:274
* upgrade_mahara(array(size 1)) at /var/www/mahara-19.10.6/htdocs/admin/cli/upgrade.php:74
[WAR] a3 (lib/dml.php:181) Could not execute command: INSERT INTO "tag" (tag,resourcetype,resourceid,ownertype,ownerid,editedby,ctime,mtime)
[WAR] a3 (lib/dml.php:181) SELECT xt.tag, 'artefact' AS resourcetype, xt.artefact AS resourceid,
[WAR] a3 (lib/dml.php:181) CASE WHEN x.owner IS NOT NULL THEN 'user'
[WAR] a3 (lib/dml.php:181) WHEN x.group IS NOT NULL THEN 'group'
[WAR] a3 (lib/dml.php:181) ELSE 'institution'
[WAR] a3 (lib/dml.php:181) END AS ownertype,
[WAR] a3 (lib/dml.php:181) CASE WHEN x.owner IS NOT NULL THEN x.owner
[WAR] a3 (lib/dml.php:181) WHEN x.group IS NOT NULL THEN x.group
[WAR] a3 (lib/dml.php:181) ELSE x.institution
[WAR] a3 (lib/dml.php:181) END AS ownerid,
[WAR] a3 (lib/dml.php:181) NULL AS editedby, x.ctime AS ctime, x.mtime AS mtime
[WAR] a3 (lib/dml.php:181) FROM "artefact_tag" xt
[WAR] a3 (lib/dml.php:181) JOIN "artefact" x ON x.id = xt.artefact
Call stack (most recent first):
* execute_sql() at /var/www/mahara-19.10.6/htdocs/lib/db/upgrade.php:973
* xmldb_core_upgrade() at /var/www/mahara-19.10.6/htdocs/lib/upgrade.php:376
* upgrade_core() at /var/www/mahara-19.10.6/htdocs/lib/mahara.php:274
* upgrade_mahara() at /var/www/mahara-19.10.6/htdocs/admin/cli/upgrade.php:74
- «Previous page
- 1
- 2
- »Next page