I m facing the following an error when i am try "hdfs dfs -ls /" command.
Caused by: javax.security.sasl.SaslException: GSS initiate failed [Caused by GSSException: No valid credentials provided (Mechanism level: Failed to find any Kerberos tgt)]
[hdfs@nn1 ~]$ klist -ef
Ticket cache: FILE:/tmp/krb5cc_493
Default principal: hdfs@CLOUDERA.LOCAL
Valid starting Expires Service principal
12/27/16 12:19:35 12/28/16 12:19:35 krbtgt/CLOUDERA.LOCAL@CLOUDERA.LOCAL
renew until 12/27/16 12:19:35, Flags: FRI
Etype (skey, tkt): aes256-cts-hmac-sha1-96, aes256-cts-hmac-sha1-96
Could you please post the output of listprincs from the KDC server and also realm details.
Normally the principal should looks like
but in your case it I see hdfs/CLOUDERA.LOCAL.
As long as your have the valid TGT for the user/service and KDC matches, you should be able to execute it.
can you clarrify how did you remove and recreate kerberos configuration? which configuration? kdc or krb5.conf