title: Child Error due to javax.security.auth.login.LoginException
body: <p>I have a 20 node Hadoop cluster where each node has 8GB memory and an 8-core processor. I sometimes get the following error on a random basis when I have a long running job with 300-600 reducers:</p>
  
  <pre><code>Exception in thread "main" java.io.IOException: Exception reading file:/var/tmp/jim/hadoop-jim/mapred/local/taskTracker/jim/jobcache/job_201305231647_0005/jobToken
    at org.apache.hadoop.security.Credentials.readTokenStorageFile(Credentials.java:135)
    at org.apache.hadoop.mapreduce.security.TokenCache.loadTokens(TokenCache.java:165)
    at org.apache.hadoop.mapred.Child.main(Child.java:92)
  
  Caused by: java.io.IOException: failure to login
    at org.apache.hadoop.security.UserGroupInformation.getLoginUser(UserGroupInformation.java:501)
    at org.apache.hadoop.security.UserGroupInformation.getCurrentUser(UserGroupInformation.java:463)
    at org.apache.hadoop.fs.FileSystem$Cache$Key.&lt;init&gt;(FileSystem.java:1519)
    at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:1420)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:254)
    at org.apache.hadoop.fs.Path.getFileSystem(Path.java:187)
    at org.apache.hadoop.security.Credentials.readTokenStorageFile(Credentials.java:129)
  ... 2 more
  
  Caused by: javax.security.auth.login.LoginException: java.lang.NullPointerException: invalid null input: name
    at com.sun.security.auth.UnixPrincipal.&lt;init&gt;(UnixPrincipal.java:70)
    at com.sun.security.auth.module.UnixLoginModule.login(UnixLoginModule.java:132)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  </code></pre>
  
  <p>I tried switching JVM's and both open JDK 1.7 and Oracle JVM 1.6 resulted in the same errors occasionally. It doesn't always happen and when it happens, all tasks running in a particular node fail and that node gets blacklisted. However, the same node usually runs just fine when I submit another job. I am running Ubuntu 12.10 on my cluster nodes.</p>
  
  <p>I searched for this error on-line and the only post I could find was from the Cloudera mailing archives where someone running a pseudo distributed Hadoop cluster on a Mac. Other than that, I think I am the first person to come across this issue. </p>
  
  <p>I am not new to Hadoop and generally can solve cluster related problems or mis-configuration issues by myself but I would really appreciate any feedback on this. </p>