private void startCopy() throws Exception {
log.debug("Starting log recovery: " + logFile);
try {
// Ask the logging server to put the file in HDFS
RemoteLogger logger = new RemoteLogger(logFile.server);
String base = logFile.unsortedFileName();
log.debug("Starting to copy " + logFile.file + " from " + logFile.server);
LogCopyInfo lci = logger.startCopy(logFile.file, base, !useMapReduce);
copySize = lci.fileSize;
loggerZNode = lci.loggerZNode;
} catch (Throwable t) {
log.warn("Unable to recover " + logFile + "(" + t + ")", t);
fail();