Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Name node logs are spammed with "No groups available for user hdfs"

avatar
Expert Contributor

When I see the Name Node logs, I continuously see the message going on in the logs.

hadoop-hdfs-namenode-<HOST_NAME>.log

WARN security.UserGroupInformation (UserGroupInformation.java:getGroupNames(1573)) - No groups available for user hdfs

I checked on the Name node the user hdfs does exist on the host and it is member of the gorup hadoop.

$id hdfs

uid=123(hdfs) gid=663(hadoop) groups=993(hadoop)

I am concerned because of three things.

1) Lack of useful information is hidden under spams

2) Possible performance hit due to I/O

3) Unnecessarily logs are getting bigger and occupying disk space.

What configuration do you think are we missing here?

Thanks,

SS

1 ACCEPTED SOLUTION

avatar

@Smart Soultions

output of id hdfs should be

[root@hdp-2 ~]# id hdfs

uid=9022(hdfs) gid=501(hadoop) groups=501(hadoop),9014(hdfs)

In your output there is no group like hdfs

Create hdfs goup and add hdfs user in hdfs group. And try to restart namenode.

groupadd group1

usermod -a -G grpup1 abc

In this example I created group group1 adn addedd the user abc to group1.

View solution in original post

8 REPLIES 8

avatar

@Smart Soultions

output of id hdfs should be

[root@hdp-2 ~]# id hdfs

uid=9022(hdfs) gid=501(hadoop) groups=501(hadoop),9014(hdfs)

In your output there is no group like hdfs

Create hdfs goup and add hdfs user in hdfs group. And try to restart namenode.

groupadd group1

usermod -a -G grpup1 abc

In this example I created group group1 adn addedd the user abc to group1.

avatar
Expert Contributor

Thank you @Ashnee Sharma Is it a work around or hdfs user needs to be in the hdfs group?

I also checked in the log, for the spark user it says no groups found for user spark, for user yarn same is the case.

Do you think we need to create groups for each user?

Thank you.

avatar

@Smart Solutions

yes you need to create group of each user. If groups are not there.

Please accept the ans so it will helps to others.

avatar
Expert Contributor

Before accepting I am trying to understand the root cause, why I do not have groups for the users on my cluster.

avatar

@Smart Solutions

May be some one deleted the group or not installed the properly. Because while installing HDP . Ambari creates user and group itself.

avatar
Expert Contributor

@Ashnee Sharma No one deleted the groups. Well digging further found this issue is different from deletion of the groups. Its something related with infra initial setup 🙂 Anyway accepting the answer as it can help with normal scenarios.

Thank you.

avatar

This error has nothing to do with the missing user-specific group. The NameNode has no requirement that the group name match the user name. As long as the id command succeeded and returned any groups the NameNode would not have logged the error.

This error was likely due to a temporary infrastructure issue as pointed out by @Smart Solutions in a later comment. The following article is a good starting point for any issues related to groups lookups.

https://community.hortonworks.com/articles/38591/hadoop-and-ldap-usage-load-patterns-and-tuning.html

avatar
Expert Contributor

You are right Arpit. It is a deeper issue, related to groups in LDAP.