From: Date: January 15 2007 9:03pm Subject: bk commit into 5.1 tree (jonas:1.2366) BUG#25636 List-Archive: http://lists.mysql.com/commits/18149 X-Bug: 25636 Message-Id: <20070115200345.BB04068E387@perch.ndb.mysql.com> Below is the list of changes that have just been committed into a local 5.1 repository of jonas. When jonas does a push these changes will be propagated to the main repository and, within 24 hours after the push, to the public repository. For information on how to access the public repository see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html ChangeSet@stripped, 2007-01-15 21:03:39+01:00, jonas@stripped +5 -0 ndb - bug#25636 Fix DD problem during NR after 3 missed LCP's storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp@stripped, 2007-01-15 21:03:37+01:00, jonas@stripped +11 -0 Send START_FRAGREQ also for fragments wo/ LCP storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp@stripped, 2007-01-15 21:03:37+01:00, jonas@stripped +13 -3 inform TUP that no LCP is restored (if no lcp is restored :-) storage/ndb/src/kernel/blocks/dbtup/Dbtup.hpp@stripped, 2007-01-15 21:03:37+01:00, jonas@stripped +2 -0 inform TUP that no LCP is restored (if no lcp is restored :-) storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp@stripped, 2007-01-15 21:03:37+01:00, jonas@stripped +7 -0 inform TUP that no LCP is restored (if no lcp is restored :-) storage/ndb/src/kernel/blocks/pgman.cpp@stripped, 2007-01-15 21:03:37+01:00, jonas@stripped +7 -0 Add error insert using dump # This is a BitKeeper patch. What follows are the unified diffs for the # set of deltas contained in the patch. The rest of the patch, the part # that BitKeeper cares about, is below these diffs. # User: jonas # Host: perch.ndb.mysql.com # Root: /home/jonas/src/51-work --- 1.19/storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp 2007-01-15 21:03:45 +01:00 +++ 1.20/storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp 2007-01-15 21:03:45 +01:00 @@ -1423,6 +1423,13 @@ } void +Dbtup::disk_restart_mark_no_lcp(Uint32 tableId, Uint32 fragId) +{ + jamEntry(); + disk_restart_undo_lcp(tableId, fragId, Fragrecord::UC_CREATE); +} + +void Dbtup::disk_restart_undo_lcp(Uint32 tableId, Uint32 fragId, Uint32 flag) { Ptr tabPtr; --- 1.18/storage/ndb/src/kernel/blocks/pgman.cpp 2007-01-15 21:03:45 +01:00 +++ 1.19/storage/ndb/src/kernel/blocks/pgman.cpp 2007-01-15 21:03:45 +01:00 @@ -1258,6 +1258,8 @@ void Pgman::process_lcp_locked(Signal* signal, Ptr ptr) { + CRASH_INSERTION(11006); + ptr.p->m_last_lcp = m_last_lcp; if (ptr.p->m_state & Page_entry::DIRTY) { @@ -2350,6 +2352,11 @@ if (signal->theData[0] == 11005) { g_dbg_lcp = ~g_dbg_lcp; + } + + if (signal->theData[0] == 11006) + { + SET_ERROR_INSERT_VALUE(11006); } } --- 1.96/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp 2007-01-15 21:03:45 +01:00 +++ 1.97/storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp 2007-01-15 21:03:45 +01:00 @@ -2916,6 +2916,17 @@ takeOverPtr.p->toCurrentTabref, takeOverPtr.p->toCurrentFragid); replicaPtr.p->lcpIdStarted = 0; + BlockReference ref = calcLqhBlockRef(takeOverPtr.p->toStartingNode); + StartFragReq *req = (StartFragReq *)signal->getDataPtrSend(); + req->userPtr = 0; + req->userRef = reference(); + req->lcpNo = ZNIL; + req->lcpId = 0; + req->tableId = takeOverPtr.p->toCurrentTabref; + req->fragId = takeOverPtr.p->toCurrentFragid; + req->noOfLogNodes = 0; + sendSignal(ref, GSN_START_FRAGREQ, signal, + StartFragReq::SignalLength, JBB); } else { --- 1.128/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp 2007-01-15 21:03:45 +01:00 +++ 1.129/storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp 2007-01-15 21:03:45 +01:00 @@ -13836,6 +13836,7 @@ Uint32 lcpNo = startFragReq->lcpNo; Uint32 noOfLogNodes = startFragReq->noOfLogNodes; Uint32 lcpId = startFragReq->lcpId; + ndbrequire(noOfLogNodes <= 4); fragptr.p->fragStatus = Fragrecord::CRASH_RECOVERING; fragptr.p->srBlockref = startFragReq->userRef; @@ -13890,7 +13891,16 @@ signal->theData[1] = fragId; sendSignal(DBACC_REF, GSN_EXPANDCHECK2, signal, 2, JBB); } - + + if (getNodeState().getNodeRestartInProgress()) + { + jam(); + fragptr.p->fragStatus = Fragrecord::ACTIVE_CREATION; + } + + c_tup->disk_restart_mark_no_lcp(tabptr.i, fragId); + jamEntry(); + return; }//if @@ -16713,8 +16723,8 @@ ccurrentGcprec = RNIL; caddNodeState = ZFALSE; cstartRecReq = ZFALSE; - cnewestGci = ~0; - cnewestCompletedGci = ~0; + cnewestGci = 0; + cnewestCompletedGci = 0; crestartOldestGci = 0; crestartNewestGci = 0; csrPhaseStarted = ZSR_NO_PHASE_STARTED; --- 1.53/storage/ndb/src/kernel/blocks/dbtup/Dbtup.hpp 2007-01-15 21:03:45 +01:00 +++ 1.54/storage/ndb/src/kernel/blocks/dbtup/Dbtup.hpp 2007-01-15 21:03:45 +01:00 @@ -2711,6 +2711,8 @@ Ptr m_extent_ptr; Local_key m_key; }; + + void disk_restart_mark_no_lcp(Uint32 table, Uint32 frag); private: void disk_restart_undo_next(Signal*);