List:Commits« Previous MessageNext Message »
From:Jonas Oreland Date:February 19 2009 2:24pm
Subject:bzr commit into mysql-5.1-telco-6.2 branch (jonas:2848) Bug#17614
View as plain text  
#At file:///home/jonas/src/telco-6.2/

 2848 Jonas Oreland	2009-02-19
      ndb - bug#17614 - handle logfile groups wo/ undofiles during restart
modified:
  storage/ndb/src/kernel/blocks/lgman.cpp

=== modified file 'storage/ndb/src/kernel/blocks/lgman.cpp'
--- a/storage/ndb/src/kernel/blocks/lgman.cpp	2009-02-19 10:01:01 +0000
+++ b/storage/ndb/src/kernel/blocks/lgman.cpp	2009-02-19 14:24:10 +0000
@@ -192,11 +192,13 @@ Lgman::execCONTINUEB(Signal* signal){
     Ptr<Logfile_group> ptr;
     if(ptrI != RNIL)
     {
+      jam();
       m_logfile_group_pool.getPtr(ptr, ptrI);
       find_log_head(signal, ptr);
     }
     else
     {
+      jam();
       init_run_undo_log(signal);
     }
     return;
@@ -2492,6 +2494,8 @@ Lgman::init_run_undo_log(Signal* signal)
   Logfile_group_list& list= m_logfile_group_list;
   Logfile_group_list tmp(m_logfile_group_pool);
 
+  bool found_any = false;
+
   list.first(group);
   while(!group.isNull())
   {
@@ -2499,6 +2503,18 @@ Lgman::init_run_undo_log(Signal* signal)
     list.next(group);
     list.remove(ptr);
 
+    if (ptr.p->m_state & Logfile_group::LG_ONLINE)
+    {
+      /**
+       * No logfiles in group
+       */
+      jam();
+      tmp.addLast(ptr);
+      continue;
+    }
+    
+    found_any = true;
+
     {
       /**
        * Init buffer pointers
@@ -2541,6 +2557,17 @@ Lgman::init_run_undo_log(Signal* signal)
   }
   list = tmp;
 
+  if (found_any == false)
+  {
+    /**
+     * No logfilegroup had any logfiles
+     */
+    jam();
+    signal->theData[0] = reference();
+    sendSignal(DBLQH_REF, GSN_START_RECCONF, signal, 1, JBB);
+    return;
+  }
+  
   execute_undo_record(signal);
 }
 

Thread
bzr commit into mysql-5.1-telco-6.2 branch (jonas:2848) Bug#17614Jonas Oreland19 Feb