Kerberos commands usage

Enter the kadmin console

#kadmin.local

Adding Principal to a Keytab File

kadmin.local : ktadd -k /etc/krb5/anoop.keytab sherlock

Removing a principal from keytab

kadmin.local : ktremove host/denver.example.com@EXAMPLE.COM

Adding principal

addprinc -randkey $primary_name/$fully.qualified.domain.name@EXAMPLE.COM

To list all of the entries in the etc/krb5/my_keytab key table with timestamps, type:

klist -t -k etc/krb5/my_keytab
Create the hdfs keytab file, which contains an entry for the hdfs principal.
$ kadmin
kadmin: xst -k hdfs-unmerged.keytab hdfs/fully.qualified.domain.name

To obtain tickets using hdfs principal using the keytab:
$ kinit -k -t hdfs.keytab hdfs/fully.qualified.domain.name@YOUR-REALM.COM

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s