ambari Hadoop 部署 connection failed / connection refuse 错误 NTP 未启用

时间:2024-03-16 08:58:43

环境 Redhat 7.3 / ambari 2.7 / hadoop 3.1

使用ambaar完成i部署hadoop 集群没有报错,但发现有几个服务不能启动,查看日志提示都显示指向某一台host connection refuse, 如:

Connection failed: [Errno 111] Connection refused to ……

ambari Hadoop 部署 connection failed / connection refuse 错误 NTP 未启用

Failed connect to hadoop-app1.novalocal:50070; Connection refused

网上找了一圈,这个错误很常见,一般是防火墙相关设置的问题。

所以先查看一下firewalld 

[[email protected] ~]# systemctl status firewalld

● firewalld.service - firewalld - dynamic firewall daemon

   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)

   Active: inactive (dead)

     Docs: man:firewalld(1)

显示防火墙已经禁用,试着重启agent问题依然存在。

又创仔细重新阅读官方文档,逐步核对环境准备各步骤。

官方配置步骤——https://docs.hortonworks.com/HDPDocuments/Ambari-2.7.3.0/bk_ambari-installation/content/enable_ntp_on_the_cluster_and_on_the_browser_host.html

ambari Hadoop 部署 connection failed / connection refuse 错误 NTP 未启用

 

一步一步重新试了,也重新装了NTP,并且根据要求 systemctl enable ntpd, 依然不行。。

查看了下不同host各服务有哪些不同。

connection refuse 的host ntpd status --

[[email protected] ~]# systemctl status ntpd

● ntpd.service - Network Time Service

   Loaded: loaded (/usr/lib/systemd/system/ntpd.service; enabled; vendor preset: disabled)

   Active: inactive (dead)

对比其他未报错host

[[email protected] ~]# systemctl status ntpd

ntpd.service - Network Time Service

   Loaded: loaded (/usr/lib/systemd/system/ntpd.service; enabled; vendor preset: disabled)

   Active: active (running) since Thu 2019-01-24 10:39:05 CST; 1 weeks 0 days ago

 Main PID: 569 (ntpd)

   CGroup: /system.slice/ntpd.service

           └─569 /usr/sbin/ntpd -u ntp:ntp -g

原来虽然enable 了,但不知道为啥,没有启动,运行命令 systemctl start ntpd 启动,查看ntpd status 与其他host一样 active,再手动启动hadoop 相关service  connection refuse 错误解决

 

*****************************

看NTP的简介便可以发现它在集群互信过程中起着重要作用。。

The Network Time Protocol (NTP) is a networking protocol for clock synchronization between computer systems over packet-switched, variable-latency data networks. In operation since before 1985, NTP is one of the oldest Internet protocols in current use. NTPwas designed by David L. Mills of the University of Delawar...