org.apache.hadoop.dfs
Class SecondaryNameNode
java.lang.Object
org.apache.hadoop.dfs.SecondaryNameNode
- All Implemented Interfaces:
- Runnable, FSConstants
public class SecondaryNameNode
- extends Object
- implements FSConstants, Runnable
The Secondary NameNode is a helper to the primary NameNode.
The Secondary is responsible for supporting periodic checkpoints
of the HDFS metadata. The current design allows only one Secondary
NameNode per HDFs cluster.
The Secondary NameNode is a daemon that periodically wakes
up (determined by the schedule specified in the configuration),
triggers a periodic checkpoint and then goes back to sleep.
The Secondary NameNode uses the ClientProtocol to talk to the
primary NameNode.
- Author:
- Dhruba Borthakur
Field Summary |
static org.apache.commons.logging.Log |
LOG
|
Fields inherited from interface org.apache.hadoop.dfs.FSConstants |
BLOCK_INVALIDATE_CHUNK, BLOCKREPORT_INTERVAL, BUFFER_SIZE, CHUNKED_ENCODING, COMPLETE_SUCCESS, HEARTBEAT_INTERVAL, LAYOUT_VERSION, LEASE_HARDLIMIT_PERIOD, LEASE_SOFTLIMIT_PERIOD, MAX_PATH_DEPTH, MAX_PATH_LENGTH, MIN_BLOCKS_FOR_WRITE, OP_ACK, OP_BLOCKRECEIVED, OP_BLOCKREPORT, OP_CLIENT_ABANDONBLOCK, OP_CLIENT_ABANDONBLOCK_ACK, OP_CLIENT_ADDBLOCK, OP_CLIENT_ADDBLOCK_ACK, OP_CLIENT_COMPLETEFILE, OP_CLIENT_COMPLETEFILE_ACK, OP_CLIENT_DATANODE_HINTS, OP_CLIENT_DATANODE_HINTS_ACK, OP_CLIENT_DATANODEREPORT, OP_CLIENT_DATANODEREPORT_ACK, OP_CLIENT_DELETE, OP_CLIENT_DELETE_ACK, OP_CLIENT_EXISTS, OP_CLIENT_EXISTS_ACK, OP_CLIENT_ISDIR, OP_CLIENT_ISDIR_ACK, OP_CLIENT_LISTING, OP_CLIENT_LISTING_ACK, OP_CLIENT_MKDIRS, OP_CLIENT_MKDIRS_ACK, OP_CLIENT_OBTAINLOCK, OP_CLIENT_OBTAINLOCK_ACK, OP_CLIENT_OPEN, OP_CLIENT_OPEN_ACK, OP_CLIENT_RAWSTATS, OP_CLIENT_RAWSTATS_ACK, OP_CLIENT_RELEASELOCK, OP_CLIENT_RELEASELOCK_ACK, OP_CLIENT_RENAMETO, OP_CLIENT_RENAMETO_ACK, OP_CLIENT_RENEW_LEASE, OP_CLIENT_RENEW_LEASE_ACK, OP_CLIENT_STARTFILE, OP_CLIENT_STARTFILE_ACK, OP_CLIENT_TRYAGAIN, OP_ERROR, OP_FAILURE, OP_HEARTBEAT, OP_INVALIDATE_BLOCKS, OP_READ_BLOCK, OP_READ_RANGE_BLOCK, OP_READSKIP_BLOCK, OP_TRANSFERBLOCKS, OP_TRANSFERDATA, OP_WRITE_BLOCK, OPERATION_FAILED, READ_TIMEOUT, RUNLENGTH_ENCODING, STILL_WAITING, WRITE_COMPLETE |
Method Summary |
static void |
main(String[] argv)
main() has some simple utility methods. |
void |
run()
|
void |
shutdown()
Shut down this instance of the datanode. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LOG
public static final org.apache.commons.logging.Log LOG
SecondaryNameNode
public SecondaryNameNode(Configuration conf)
throws IOException
- Create a connection to the primary namenode.
- Throws:
IOException
shutdown
public void shutdown()
- Shut down this instance of the datanode.
Returns only after shutdown is complete.
run
public void run()
- Specified by:
run
in interface Runnable
main
public static void main(String[] argv)
throws Exception
- main() has some simple utility methods.
- Parameters:
argv
- Command line parameters.
- Throws:
Exception
- if the filesystem does not exist.
Copyright © 2006 The Apache Software Foundation