title: Cloudera Hadoop access with Kerberos gives TokenCache error : Can't get Master Kerberos principal for use as renewer
body: <p>I am trying to access Cloudera Hadoop setup (HIVE + Impala) from Mac Book Pro OS X 10.8.4.</p>
  
  <p>We have Cloudera CDH-4.3.0 installed on Linux servers. I have extracted CDH-4.2.0 tarball to my Mac Book Pro.</p>
  
  <p>I have set proper configuration and Kerberos credentials so that commands like 'hadoop -fs -ls /' works and HIVE shell starts up.</p>
  
  <p>However when I do 'show databases' command it gives following error:</p>
  
  <pre><code>&gt; hive
  &gt; show databases;
  &gt;
   Failed with exception java.io.IOException:java.io.IOException: Can't get Master Kerberos    principal for use as renewer
  </code></pre>
  
  <p>The error is related to TokenCache.</p>
  
  <p>When I searched for error, it seems following method 'obtainTokensForNamenodesInternal' throws this error when it tries to get a delegation token for specific FS and fails. </p>
  
  <p><a href="http://hadoop.apache.org/docs/current/api/src-html/org/apache/hadoop/mapreduce/security/TokenCache.html" rel="nofollow">http://hadoop.apache.org/docs/current/api/src-html/org/apache/hadoop/mapreduce/security/TokenCache.html</a></p>
  
  <p>On client side I don't see any error in HIVE shell logs. I have also tried using tarballs of CDH 4.3.0 with same configuration I get the same error.</p>
  
  <p>Any help or pointers for resolving this error would be highly appreciated.</p>