基于kerberos认证的hadoop连接问题

原创
04/27 09:34
阅读数 224

编写java程序连接hadoop,程序一直报server has invalid kerberros principal:hdfs/hm61@dc1.fh.com

通过排查修改本地的host配置,配置文件所在路径为 C:\Windows\System32\drivers\etc\hosts;

   默认文件内容如下:

# Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

# localhost name resolution is handled within DNS itself.
# 127.0.0.1 localhost
# ::1 localhost

 

 

增加主机

172.16.43.61  hm61

展开阅读全文
打赏
0
0 收藏
分享
加载中
更多评论
打赏
0 评论
0 收藏
0
分享
返回顶部
顶部