Uploaded image for project: 'Hadoop YARN'
  1. Hadoop YARN
  2. YARN-9811

FederationInterceptor fails to recover in Kerberos environment

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: amrmproxy
    • Labels:
      None

      Description

      scenario:
      Start up cluster in Kerberos environment with enable recover & AMRMProxy in NM. Submit one application to cluster, and restart NM which has master container. The NM will block in FederationInterceptor recover.

      LOG

      INFO org.apache.hadoop.yarn.server.nodemanager.amrmproxy.FederationInterceptor: Recovering data for FederationInterceptor
      INFO org.apache.hadoop.yarn.server.nodemanager.amrmproxy.FederationInterceptor: Found 0 existing UAMs for application application_1561534175896_4102 in NMStateStore
      INFO org.apache.hadoop.yarn.server.utils.AMRMClientUtils: Creating RMProxy to RM online-bx for protocol ApplicationClientProtocol for user recommend (auth:SIMPLE)
      INFO org.apache.hadoop.yarn.server.federation.failover.FederationRMFailoverProxyProvider: Initialized Federation proxy for user: recommend
      INFO org.apache.hadoop.yarn.server.federation.failover.FederationRMFailoverProxyProvider: Failing over to the ResourceManager for SubClusterId: online-bx
      INFO org.apache.hadoop.yarn.server.federation.failover.FederationRMFailoverProxyProvider: Connecting to /10.88.86.142:8032 subClusterId online-bx with protocol ApplicationClientProtocol as user recommend (auth:SIMPLE)
      WARN org.apache.hadoop.ipc.Client: Exception encountered while connecting to the server : org.apache.hadoop.security.AccessControlException: Client cannot authenticate via:[TOKEN, KERBEROS]
      INFO org.apache.hadoop.yarn.server.federation.failover.FederationRMFailoverProxyProvider: Failing over to the ResourceManager for SubClusterId: online-bx
      INFO org.apache.hadoop.yarn.server.federation.utils.FederationStateStoreFacade: Flushing subClusters from cache and rehydrating from store, most likely on account of RM failover.
      INFO org.apache.hadoop.yarn.server.federation.failover.FederationRMFailoverProxyProvider: Connecting to /10.88.86.142:8032 subClusterId online-bx with protocol ApplicationClientProtocol as user recommend (auth:SIMPLE)
      WARN org.apache.hadoop.ipc.Client: Exception encountered while connecting to the server : org.apache.hadoop.security.AccessControlException: Client cannot authenticate via:[TOKEN, KERBEROS]
      INFO org.apache.hadoop.io.retry.RetryInvocationHandler: java.io.IOException: DestHost:destPort hadoop1684.bx.momo.com:8032 , LocalHost:localPort hadoop999.bx.momo.com/10.88.64.186:0. Failed on local exception: java.io.IOException: org.apache.hadoop.security.AccessControlException: Client cannot authenticate via:[TOKEN, KERBEROS], while invoking ApplicationClientProtocolPBClientImpl.getContainers over online-bx after 1 failover attempts. Trying to failover after sleeping for 3244ms.

      Analysis

      rmclient.getContainers is called. But AuthMethod of appSubmitter is SIMPLE.We should use createProxyUser instead of createRemoteUser in Security.

      UserGroupInformation appSubmitter = UserGroupInformation          .createRemoteUser(getApplicationContext().getUser());      ApplicationClientProtocol rmClient =       createHomeRMProxy(getApplicationContext(),              ApplicationClientProtocol.class, appSubmitter);
            GetContainersResponse response = rmClient          .getContainers(GetContainersRequest.newInstance(this.attemptId));
      

        Attachments

          Activity

            People

            • Assignee:
              yifan.stan Xie YiFan
              Reporter:
              yifan.stan Xie YiFan
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: