hadoop namenode格式化失败
执行hadoop namenode -format格式化命令后,报错:
Call From hadoop01/192.168.195.134 to hadoop02:8485 failed on connection exception: java.net.Connectxception: 拒绝连接;
详细日志:
19/02/16 12:29:51 INFO namenode.NameNode: registered UNIX signal handlers for [TERM, HUP, INT]
19/02/16 12:29:51 INFO namenode.NameNode: createNameNode [-format]
19/02/16 12:29:51 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-javaclasses where applicable
Formatting using clusterid: CID-12fffbf9-a6d7-41ab-b6fa-0505ac21d655
19/02/16 12:29:52 INFO namenode.FSNamesystem: No KeyProvider found.
19/02/16 12:29:52 INFO namenode.FSNamesystem: fsLock is fair:true
19/02/16 12:29:52 INFO blockmanagement.DatanodeManager: dfs.block.invalidate.limit=1000
19/02/16 12:29:52 INFO blockmanagement.DatanodeManager: dfs.namenode.datanode.registration.ip-hostname-check=true
19/02/16 12:29:52 INFO blockmanagement.BlockManager: dfs.namenode.startup.delay.block.deletion.sec is set to 000:00:00:00.00
19/02/16 12:29:52 INFO blockmanagement.BlockManager: The block deletion will start around 2019 二月 16 12:29:52
19/02/16 12:29:52 INFO util.GSet: Computing capacity for map BlocksMap
19/02/16 12:29:52 INFO util.GSet: VM type = 64-bit
19/02/16 12:29:52 INFO util.GSet: 2.0% max memory 889 MB = 17.8 MB
19/02/16 12:29:52 INFO util.GSet: capacity = 2^21 = 2097152 entries
19/02/16 12:29:52 INFO blockmanagement.BlockManager: dfs.block.access.token.enable=false
19/02/16 12:29:52 INFO blockmanagement.BlockManager: defaultReplication = 3
19/02/16 12:29:52 INFO blockmanagement.BlockManager: maxReplication = 512
19/02/16 12:29:52 INFO blockmanagement.BlockManager: minReplication = 1
19/02/16 12:29:52 INFO blockmanagement.BlockManager: maxReplicationStreams = 2
19/02/16 12:29:52 INFO blockmanagement.BlockManager: shouldCheckForEnoughRacks = false
19/02/16 12:29:52 INFO blockmanagement.BlockManager: replicationRecheckInterval = 3000
19/02/16 12:29:52 INFO blockmanagement.BlockManager: encryptDataTransfer = false
19/02/16 12:29:52 INFO blockmanagement.BlockManager: maxNumBlocksToLog = 1000
19/02/16 12:29:52 INFO namenode.FSNamesystem: fsOwner = root (auth:SIMPLE)
19/02/16 12:29:52 INFO namenode.FSNamesystem: supergroup = supergroup
19/02/16 12:29:52 INFO namenode.FSNamesystem: isPermissionEnabled = false
19/02/16 12:29:52 INFO namenode.FSNamesystem: Determined nameservice ID: ns
19/02/16 12:29:52 INFO namenode.FSNamesystem: HA Enabled: true
19/02/16 12:29:52 INFO namenode.FSNamesystem: Append Enabled: true
19/02/16 12:29:52 INFO util.GSet: Computing capacity for map INodeMap
19/02/16 12:29:52 INFO util.GSet: VM type = 64-bit
19/02/16 12:29:52 INFO util.GSet: 1.0% max memory 889 MB = 8.9 MB
19/02/16 12:29:52 INFO util.GSet: capacity = 2^20 = 1048576 entries
19/02/16 12:29:52 INFO namenode.FSDirectory: ACLs enabled? false
19/02/16 12:29:52 INFO namenode.FSDirectory: XAttrs enabled? true
19/02/16 12:29:52 INFO namenode.FSDirectory: Maximum size of an xattr: 16384
19/02/16 12:29:52 INFO namenode.NameNode: Caching file names occuring more than 10 times
19/02/16 12:29:52 INFO util.GSet: Computing capacity for map cachedBlocks
19/02/16 12:29:52 INFO util.GSet: VM type = 64-bit
19/02/16 12:29:52 INFO util.GSet: 0.25% max memory 889 MB = 2.2 MB
19/02/16 12:29:52 INFO util.GSet: capacity = 2^18 = 262144 entries
19/02/16 12:29:52 INFO namenode.FSNamesystem: dfs.namenode.safemode.threshold-pct = 0.9990000128746033
19/02/16 12:29:52 INFO namenode.FSNamesystem: dfs.namenode.safemode.min.datanodes = 0
19/02/16 12:29:52 INFO namenode.FSNamesystem: dfs.namenode.safemode.extension = 30000
19/02/16 12:29:52 INFO metrics.TopMetrics: NNTop conf: dfs.namenode.top.window.num.buckets = 10
19/02/16 12:29:52 INFO metrics.TopMetrics: NNTop conf: dfs.namenode.top.num.users = 10
19/02/16 12:29:52 INFO metrics.TopMetrics: NNTop conf: dfs.namenode.top.windows.minutes = 1,5,25
19/02/16 12:29:52 INFO namenode.FSNamesystem: Retry cache on namenode is enabled
19/02/16 12:29:52 INFO namenode.FSNamesystem: Retry cache will use 0.03 of total heap and retry cache entry expiry time is600000 millis
19/02/16 12:29:52 INFO util.GSet: Computing capacity for map NameNodeRetryCache
19/02/16 12:29:52 INFO util.GSet: VM type = 64-bit
19/02/16 12:29:52 INFO util.GSet: 0.029999999329447746% max memory 889 MB = 273.1 KB
19/02/16 12:29:52 INFO util.GSet: capacity = 2^15 = 32768 entries
19/02/16 12:29:53 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 0 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:53 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 0 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:53 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 0 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:54 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 1 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:54 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 1 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:54 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 1 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:55 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 2 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:55 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 2 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:55 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 2 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:56 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 3 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:56 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 3 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:56 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 3 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:57 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 4 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:57 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 4 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:57 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 4 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:58 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 5 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:58 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 5 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:58 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 5 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:59 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 6 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:59 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 6 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:29:59 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 6 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:00 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 7 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:00 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 7 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:00 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 7 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:01 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 8 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:01 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 8 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:01 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 8 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:02 INFO ipc.Client: Retrying connect to server: hadoop01/192.168.195.134:8485. Already tried 9 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:02 INFO ipc.Client: Retrying connect to server: hadoop02/192.168.195.135:8485. Already tried 9 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:02 INFO ipc.Client: Retrying connect to server: hadoop03/192.168.195.136:8485. Already tried 9 time(s); rety policy is RetryUpToMaximumCountWithFixedSleep(maxRetries=10, sleepTime=1000 MILLISECONDS)
19/02/16 12:30:02 WARN namenode.NameNode: Encountered exception during format:
org.apache.hadoop.hdfs.qjournal.client.QuorumException: Unable to check if JNs are ready for formatting. 2 exceptions thron:
192.168.195.135:8485: Call From hadoop01/192.168.195.134 to hadoop02:8485 failed on connection exception: java.net.Connectxception: 拒绝连接; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
192.168.195.134:8485: Call From hadoop01/192.168.195.134 to hadoop01:8485 failed on connection exception: java.net.Connectxception: 拒绝连接; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
at org.apache.hadoop.hdfs.qjournal.client.QuorumException.create(QuorumException.java:81)
at org.apache.hadoop.hdfs.qjournal.client.QuorumCall.rethrowException(QuorumCall.java:223)
at org.apache.hadoop.hdfs.qjournal.client.QuorumJournalManager.hasSomeData(QuorumJournalManager.java:232)
at org.apache.hadoop.hdfs.server.common.Storage.confirmFormat(Storage.java:900)
at org.apache.hadoop.hdfs.server.namenode.FSImage.confirmFormat(FSImage.java:184)
at org.apache.hadoop.hdfs.server.namenode.NameNode.format(NameNode.java:987)
at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1429)
at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1554)
19/02/16 12:30:02 ERROR namenode.NameNode: Failed to start namenode.
org.apache.hadoop.hdfs.qjournal.client.QuorumException: Unable to check if JNs are ready for formatting. 2 exceptions thron:
192.168.195.135:8485: Call From hadoop01/192.168.195.134 to hadoop02:8485 failed on connection exception: java.net.Connectxception: 拒绝连接; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
192.168.195.134:8485: Call From hadoop01/192.168.195.134 to hadoop01:8485 failed on connection exception: java.net.Connectxception: 拒绝连接; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
at org.apache.hadoop.hdfs.qjournal.client.QuorumException.create(QuorumException.java:81)
at org.apache.hadoop.hdfs.qjournal.client.QuorumCall.rethrowException(QuorumCall.java:223)
at org.apache.hadoop.hdfs.qjournal.client.QuorumJournalManager.hasSomeData(QuorumJournalManager.java:232)
at org.apache.hadoop.hdfs.server.common.Storage.confirmFormat(Storage.java:900)
at org.apache.hadoop.hdfs.server.namenode.FSImage.confirmFormat(FSImage.java:184)
at org.apache.hadoop.hdfs.server.namenode.NameNode.format(NameNode.java:987)
at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1429)
at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1554)
19/02/16 12:30:02 INFO util.ExitUtil: Exiting with status 1
19/02/16 12:30:02 INFO namenode.NameNode: SHUTDOWN_MSG:
/************************************************************
SHUTDOWN_MSG: Shutting down NameNode at hadoop01/192.168.195.134
************************************************************/
从详细日志中查看到一下关键信息:
Encountered exception during format:
org.apache.hadoop.hdfs.qjournal.client.QuorumException: Unable to check if JNs are ready for formatting.
猜想应该是需要启动journalNode进程;
在各节点上使用 hadoop-daemon.sh start journalnode 启动journalnode进程,再执行格式化命令,格式化成功.(首先,需要启动zookeeper服务)
本文来自互联网用户投稿,文章观点仅代表作者本人,不代表本站立场,不承担相关法律责任。如若转载,请注明出处。 如若内容造成侵权/违法违规/事实不符,请点击【内容举报】进行投诉反馈!
