Additional log messages when tdb databases can no longer be chainlocked or chainunlocked
authorRonnie Sahlberg <ronniesahlberg@gmail.com>
Tue, 8 Jun 2010 02:09:19 +0000 (12:09 +1000)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Tue, 8 Jun 2010 02:21:20 +0000 (12:21 +1000)
BZ64688

common/ctdb_ltdb.c
server/ctdb_freeze.c

index b2fd189943251fc3db6fe93b9c663ef67d63e9e5..d35b6900c9711ea402437c0872b6609ce6e0b4fd 100644 (file)
@@ -191,7 +191,7 @@ int ctdb_ltdb_unlock(struct ctdb_db_context *ctdb_db, TDB_DATA key)
 {
        int ret = tdb_chainunlock(ctdb_db->ltdb->tdb, key);
        if (ret != 0) {
-               DEBUG(DEBUG_ERR,("tdb_chainunlock failed\n"));
+               DEBUG(DEBUG_ERR,(__location__ " tdb_chainunlock failed on database %s\n", ctdb_db->db_name));
        }
        return ret;
 }
index 38520087ce39f2e24b1340677121aa88b4be36a0..70333b0b33ddf11f6e6afdf56f792686e58f8b82 100644 (file)
@@ -48,6 +48,7 @@ static int ctdb_lock_all_databases(struct ctdb_context *ctdb, uint32_t priority)
                }
                DEBUG(DEBUG_INFO,("locking database 0x%08x priority:%u %s\n", ctdb_db->db_id, ctdb_db->priority, ctdb_db->db_name));
                if (tdb_lockall(ctdb_db->ltdb->tdb) != 0) {
+                       DEBUG(DEBUG_ERR,(__location__ " Failed to lock database %s\n", ctdb_db->db_name));
                        return -1;
                }
        }
@@ -60,6 +61,7 @@ static int ctdb_lock_all_databases(struct ctdb_context *ctdb, uint32_t priority)
                }
                DEBUG(DEBUG_INFO,("locking database 0x%08x priority:%u %s\n", ctdb_db->db_id, ctdb_db->priority, ctdb_db->db_name));
                if (tdb_lockall(ctdb_db->ltdb->tdb) != 0) {
+                       DEBUG(DEBUG_ERR,(__location__ " Failed to lock database %s\n", ctdb_db->db_name));
                        return -1;
                }
        }