HBASE-3074 Zookeeper test failing on hudson; xtra debugging to help figure whats happening up on hudson

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1003919 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2010-10-02 23:48:00 +00:00
parent fd755dffaa
commit 8ff999cf9a
5 changed files with 18 additions and 14 deletions

View File

@ -45,7 +45,7 @@ public class HRegionLocation implements Comparable<HRegionLocation> {
@Override @Override
public String toString() { public String toString() {
return "address: " + this.serverAddress.toString() + ", regioninfo: " + return "address: " + this.serverAddress.toString() + ", regioninfo: " +
this.regionInfo; this.regionInfo.getRegionNameAsString();
} }
/** /**

View File

@ -382,8 +382,7 @@ public class CatalogTracker {
throw e; throw e;
} }
} }
LOG.info("Failed verification of " + Bytes.toString(regionName) + LOG.info("Failed verification of " + Bytes.toString(regionName) + "; " + t);
", assigning anew: " + t);
return false; return false;
} }

View File

@ -594,7 +594,7 @@ public class HConnectionManager {
MetaScanner.metaScan(conf, visitor, tableName, row, MetaScanner.metaScan(conf, visitor, tableName, row,
this.prefetchRegionLimit); this.prefetchRegionLimit);
} catch (IOException e) { } catch (IOException e) {
LOG.warn("Encounted problems when prefetch META table: ", e); LOG.warn("Encountered problems when prefetch META table: ", e);
} }
} }
@ -627,9 +627,10 @@ public class HConnectionManager {
+ Bytes.toStringBinary(row) + " after " + numRetries + " tries."); + Bytes.toStringBinary(row) + " after " + numRetries + " tries.");
} }
HRegionLocation metaLocation = null;
try { try {
// locate the root or meta region // locate the root or meta region
HRegionLocation metaLocation = locateRegion(parentTable, metaKey); metaLocation = locateRegion(parentTable, metaKey);
HRegionInterface server = HRegionInterface server =
getHRegionConnection(metaLocation.getServerAddress()); getHRegionConnection(metaLocation.getServerAddress());
@ -714,7 +715,10 @@ public class HConnectionManager {
} }
if (tries < numRetries - 1) { if (tries < numRetries - 1) {
if (LOG.isDebugEnabled()) { if (LOG.isDebugEnabled()) {
LOG.debug("locateRegionInMeta attempt " + tries + " of " + LOG.debug("locateRegionInMeta parentTable=" +
Bytes.toString(parentTable) + ", metaLocation=" +
((metaLocation == null)? "null": metaLocation) + ", attempt=" +
tries + " of " +
this.numRetries + " failed; retrying after sleep of " + this.numRetries + " failed; retrying after sleep of " +
getPauseTime(tries) + " because: " + e.getMessage()); getPauseTime(tries) + " because: " + e.getMessage());
} }
@ -731,7 +735,8 @@ public class HConnectionManager {
Thread.sleep(getPauseTime(tries)); Thread.sleep(getPauseTime(tries));
} catch (InterruptedException e) { } catch (InterruptedException e) {
Thread.currentThread().interrupt(); Thread.currentThread().interrupt();
throw new IOException("Giving up trying to location region in meta: thread is interrupted."); throw new IOException("Giving up trying to location region in " +
"meta: thread is interrupted.");
} }
} }
} }

View File

@ -60,7 +60,7 @@ public class ServerShutdownHandler extends EventHandler {
this.server = server; this.server = server;
this.services = services; this.services = services;
this.deadServers = deadServers; this.deadServers = deadServers;
if (this.deadServers.contains(hsi.getServerName())) { if (!this.deadServers.contains(hsi.getServerName())) {
LOG.warn(hsi.getServerName() + " is NOT in deadservers; it should be!"); LOG.warn(hsi.getServerName() + " is NOT in deadservers; it should be!");
} }
} }

View File

@ -539,7 +539,7 @@ public class HRegionServer implements HRegionInterface, HBaseRPCErrorHandler,
} // for } // for
} catch (Throwable t) { } catch (Throwable t) {
if (!checkOOME(t)) { if (!checkOOME(t)) {
abort("Unhandled exception", t); abort("Unhandled exception: " + t.getMessage(), t);
} }
} }
this.leases.closeAfterLeasesExpire(); this.leases.closeAfterLeasesExpire();
@ -1247,9 +1247,9 @@ public class HRegionServer implements HRegionInterface, HBaseRPCErrorHandler,
*/ */
public void abort(String reason, Throwable cause) { public void abort(String reason, Throwable cause) {
if (cause != null) { if (cause != null) {
LOG.fatal("Aborting region server " + this + ": " + reason, cause); LOG.fatal("ABORTING region server " + this + ": " + reason, cause);
} else { } else {
LOG.fatal("Aborting region server " + this + ": " + reason); LOG.fatal("ABORTING region server " + this + ": " + reason);
} }
this.abortRequested = true; this.abortRequested = true;
this.reservedSpace.clear(); this.reservedSpace.clear();
@ -1358,9 +1358,9 @@ public class HRegionServer implements HRegionInterface, HBaseRPCErrorHandler,
try { try {
this.requestCount.set(0); this.requestCount.set(0);
lastMsg = System.currentTimeMillis(); lastMsg = System.currentTimeMillis();
ZKUtil.setAddressAndWatch(zooKeeper, ZKUtil.joinZNode( ZKUtil.setAddressAndWatch(zooKeeper,
zooKeeper.rsZNode, ZKUtil.getNodeName(serverInfo)), ZKUtil.joinZNode(zooKeeper.rsZNode, ZKUtil.getNodeName(serverInfo)),
this.serverInfo.getServerAddress()); this.serverInfo.getServerAddress());
this.serverInfo.setLoad(buildServerLoad()); this.serverInfo.setLoad(buildServerLoad());
result = this.hbaseMaster.regionServerStartup(this.serverInfo); result = this.hbaseMaster.regionServerStartup(this.serverInfo);
break; break;