Bug #33895 NdbTransaction::execute() hangs endlessly during upgrade from 6.1 to 6.2
Submitted: 17 Jan 2008 9:43 Modified: 20 Feb 2008 22:01
Reporter: Bernd Ocklin Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: NDB API Severity:S2 (Serious)
Version:ndb 6.1 -> ndb 6.2 OS:Linux
Assigned to: Jonas Oreland CPU Architecture:Any

[17 Jan 2008 9:43] Bernd Ocklin
Description:
ndbapi_simple hangs forever when inserting tuples with insertTuple() in NdbTransaction::execute() connecting a 6.1 ndbapi to a running 6.2 cluster. This would typically be the scenario during hot upgrade. 

Seems that also readTuple() is hanging in the same way.

Insert is committed but program hangs after it. It's waiting for more data in TCKEYCONF.

How to repeat:
1. take e.g. 6.1.23 ndbapi_simple
2. take 6.2.10 ndb_mgmd, ndbd, mysqld
3. disable microgcp by TimeBetweenEpoch=0 to be compatible
4. try to run ndbapi_simple
[17 Jan 2008 13:22] Bernd Ocklin
More on the test I did. This time "online" upgrade.

- slightly modified ndbapi_simple 6.1.23 running as in attached file ndbapi_simple.cpp
- cluster 6.1.23 running as described in file config.ini.1
- upgrade software to ndb 6.2.10 
- restart ndb_mgmd processes node 1 and 2 in new version
- ndb_mgm> stop node 3 ndbd
- shell> ndbd -c 'nodeid=3;host=localhost:1186;localhost:1187' -n 
- ndb_mgm> 3 start

As soon as node 3 is started execute() hangs.
[17 Jan 2008 13:23] Bernd Ocklin
modified ndbapi_simple.cpp

Attachment: ndbapi_simple.cpp (text/x-c++src), 8.76 KiB.

[17 Jan 2008 13:23] Bernd Ocklin
config file used

Attachment: config.ini.1 (application/unknown, text), 609 bytes.

[22 Jan 2008 14:20] Jonas Oreland
verified...
fix coming to a 6.2(3) release real soon
[23 Jan 2008 6:51] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/41134

ChangeSet@1.2694, 2008-01-23 07:52:25+01:00, jonas@perch.ndb.mysql.com +1 -0
  ndb - bug#33895
    Fix upgrade bug(wo/ -> w/ micro gcp) with more than one packed tckeyconf in a API_PACKED signal
[23 Jan 2008 9:57] Jonas Oreland
pushed into telco-6.2 & telco-6.3
this affects upgrade from pre micro-gcp
[1 Feb 2008 13:28] Jon Stephens
Documented bugfix for 5.1.23-ndb-6.3.8 as follows:

      
      
        Transactions containing inserts or reads would hang during
        NdbTransaction::execute() calls made from NDB
        API applications built against a MySQL Cluster version that did
        not support micro-GCPs accessing a later version that supported
        micro-GCPs. This issue was observed while upgrading from MySQL
        5.1.15-ndb-6.1.23 to MySQL 5.1.23-ndb-6.2.10 when the API
        application built against the earlier version attempted to
        access a data node already running the later version, even after
        disabling micro-GCPs by setting
        TimeBetweenEpochs equal to 0. 

Left bug in PQ status pending further merges.
[2 Feb 2008 12:08] Jon Stephens
Also documented for 5.1.23-ndb-6.2.11; left status unchanged.
[20 Feb 2008 16:04] Bugs System
Pushed into 6.0.5-alpha
[20 Feb 2008 22:01] Jon Stephens
Also documented for 6.0.5.