Setup openafs client and kerberos on Ubuntu lucidMonday, April 16, 2012 15:59

In my working organization I often need to login to openAFS through my Ubuntu box. As www.openafs.org says, AFS is a distributed filesystem product, pioneered at Carnegie Mellon University and supported and developed as a product by Transarc Corporation (now IBM Pittsburgh Labs) and offers a client-server architecture for federated file sharing and replicated read-only content distribution, providing location independence, scalability, security, and transparent migration capabilities.

In order to install openafs client:

sudo apt-get install openafs-client krb5-config krb5-user libkadm55 openafs-krb5

The first package is the standard openafs client that lets you connect to a default cell, configurated in /etc/openafs/CellServDB, the others are related to kerberos 5 authentication, configuration in /etc/krb5.conf.

Depending on different configuration, the Ubuntu box lets you obtain AFS tokens in different ways. The preferred one for me is the following

kinit <username>

and you are prompted for password for you default kerberos domain (usually in all uppercase characters). In order to see if you are logged in kerberos realm issue:

klist -5f

In order to get AFS token through kerberos ticket:

aklog -c <afs_cell> -k <kerberos_realm>

In order to verify if you get the AFS token, please issue:

tokens

With these simple commands you should get your afs client working with Ubuntu.

Categories: afs, ubuntu