2.2.7 to 2.4.1 upgrade error

2.2.7 to 2.4.1 upgrade error

by Michael Dahle -
Number of replies: 4

I attempted to upgrade from 2.2.7 to 2.4.1 (this included needing to set up a new db and import the tables and data to meet the db requirements).

It looked like it got 100% through the conversion but then gave me an error (see below) and now I am stuck on a page that says "Site is being upgraded, please retry later." There are no login boxes/options on the page.

I am over my head here. Any one able to help?

The error message:

Upgrading to new version

 

 

 

 

System

Converted unsigned/lob columns in MySQL database - 285/285.



 100%

DDL sql execution error

More information about this error

Debug info: Binary logging not possible. Message: Transaction level 'READ-COMMITTED' in InnoDB is not safe for binlog mode 'STATEMENT'
CREATE UNIQUE INDEX mdl_coursect_cousec_uix ON mdl_course_sections (course, section)
Error code: ddlexecuteerror

Stack trace:

  • line 432 of /lib/dml/moodle_database.php: ddl_change_structure_exception thrown

  • line 860 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()

  • line 88 of /lib/ddl/database_manager.php: call to mysqli_native_moodle_database->change_database_structure()

  • line 77 of /lib/ddl/database_manager.php: call to database_manager->execute_sql()

  • line 817 of /lib/ddl/database_manager.php: call to database_manager->execute_sql_arr()

  • line 393 of /lib/db/upgrade.php: call to database_manager->add_index()

  • line 1493 of /lib/upgradelib.php: call to xmldb_main_upgrade()

  • line 284 of /admin/index.php: call to upgrade_core()

Average of ratings: -
In reply to Michael Dahle

Re: 2.2.7 to 2.4.1 upgrade error

by Michael Dahle -

Update:

After waiting a while longer, when I try to refresh the "try later" page it "loops" me back to the upgrade moodle page. (below)

 

Your Moodle files have been changed, and you are about to automatically upgrade your server to this version:

2.4.1+ (Build: 20130222) (2012120301.12)

Once you do this you can not go back again.

Please note that this process can take a long time.

Are you sure you want to upgrade this server to this version?

In reply to Michael Dahle

Re: 2.2.7 to 2.4.1 upgrade error

by Ken Task -
Picture of Particularly helpful Moodlers

Consider this some food for thought or investigation …

Error says 'Binary logging not possible'

You didn't mention MySQL version.

Ref for below: https://dev.mysql.com/doc/refman/5.5/en/binary-log.html
Items below are clips from above page:

A client that has the SUPER privilege can disable binary logging of its own statements by using a SET sql_log_bin=0 statement.

The format of the events recorded in the binary log is dependent on the binary logging format. Three format types are supported, row-based logging, statement-based logging and mixed-base logging. The binary logging format used depends on the MySQL version.

In MySQL 5.5, the default binary logging format is STATEMENT.

What's the output from mysql> prompt when using:

show variables;

or better yet:

 show variables like '%bin%';

Recently migrated a 2.2.7+ to 2.3.x+ on CentOS using mysql  Ver 14.14 Distrib 5.5.29, for Linux (x86_64) with no issues.

'spirit of sharing', Ken

In reply to Ken Task

Re: 2.2.7 to 2.4.1 upgrade error

by Michael Dahle -

Ken,

Thanks for your reply. I will read it through some more but in answer to the question of the MySQL version, the version is 5.1.61

In reply to Michael Dahle

Re: 2.2.7 to 2.4.1 upgrade error

by Ken Task -
Picture of Particularly helpful Moodlers

Sounds like RedHat or CentOS box.  That about right?  Both are, errr, shall we say 'conservative' when it comes to 'lastest/greatest' PHP or MySQL.    On a CentOS 6.3 box had to use the remi repo to get 5.5.29 of MySQL.

From download.moodle.org requirement for 2.4.1 MySQL 5.1.33

Here's mysql docs on your version concerning bin logging:

https://dev.mysql.com/doc/refman/5.1/en/binary-log.html

Thought migration path had to be 2.2.7 to 2.3.x then to 2.4.1+ cause 2.4.x required 2.3.  Hopefully, you've installed your 2.2.7+ with git.  One can rather easily move to 2.3 and then to 2.4 via git.

'spirit of sharing', Ken