[ 
https://issues.apache.org/jira/browse/HBASE-15741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15269834#comment-15269834
 ] 

Mikhail Antonov commented on HBASE-15741:
-----------------------------------------

v3 looks good to me. 

(there's an existing code duplication in registerService() method in HRS and 
HM, which would be nice to remove, but that'd be a separate change..)

> TokenProvider coprocessor RPC incompatibile between 1.2 and 1.3
> ---------------------------------------------------------------
>
>                 Key: HBASE-15741
>                 URL: https://issues.apache.org/jira/browse/HBASE-15741
>             Project: HBase
>          Issue Type: Bug
>          Components: Coprocessors
>    Affects Versions: 1.3.0
>            Reporter: Gary Helmling
>            Assignee: Gary Helmling
>            Priority: Blocker
>             Fix For: 1.3.0
>
>         Attachments: HBASE-15741.001.patch, HBASE-15741.002.patch, 
> HBASE-15741.003.patch
>
>
> Attempting to run a map reduce job with a 1.3 client on a secure cluster 
> running 1.2 is failing when making the coprocessor rpc to obtain a delegation 
> token:
> {noformat}
> Exception in thread "main" 
> org.apache.hadoop.hbase.exceptions.UnknownProtocolException: 
> org.apache.hadoop.hbase.exceptions.UnknownProtocolException: No registered 
> coprocessor service found for name hbase.pb.AuthenticationService in region 
> hbase:meta,,1
>         at 
> org.apache.hadoop.hbase.regionserver.HRegion.execService(HRegion.java:7741)
>         at 
> org.apache.hadoop.hbase.regionserver.RSRpcServices.execServiceOnRegion(RSRpcServices.java:1988)
>         at 
> org.apache.hadoop.hbase.regionserver.RSRpcServices.execService(RSRpcServices.java:1970)
>         at 
> org.apache.hadoop.hbase.protobuf.generated.ClientProtos$ClientService$2.callBlockingMethod(ClientProtos.java:33652)
>         at org.apache.hadoop.hbase.ipc.RpcServer.call(RpcServer.java:2170)
>         at org.apache.hadoop.hbase.ipc.CallRunner.run(CallRunner.java:109)
>         at 
> org.apache.hadoop.hbase.ipc.RpcExecutor.consumerLoop(RpcExecutor.java:137)
>         at org.apache.hadoop.hbase.ipc.RpcExecutor$1.run(RpcExecutor.java:112)
>         at java.lang.Thread.run(Thread.java:745)
>         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native 
> Method)
>         at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>         at 
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>         at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
>         at 
> org.apache.hadoop.ipc.RemoteException.instantiateException(RemoteException.java:106)
>         at 
> org.apache.hadoop.ipc.RemoteException.unwrapRemoteException(RemoteException.java:95)
>         at 
> org.apache.hadoop.hbase.protobuf.ProtobufUtil.getRemoteException(ProtobufUtil.java:332)
>         at 
> org.apache.hadoop.hbase.protobuf.ProtobufUtil.execService(ProtobufUtil.java:1631)
>         at 
> org.apache.hadoop.hbase.ipc.RegionCoprocessorRpcChannel$1.call(RegionCoprocessorRpcChannel.java:104)
>         at 
> org.apache.hadoop.hbase.ipc.RegionCoprocessorRpcChannel$1.call(RegionCoprocessorRpcChannel.java:94)
>         at 
> org.apache.hadoop.hbase.client.RpcRetryingCaller.callWithRetries(RpcRetryingCaller.java:137)
>         at 
> org.apache.hadoop.hbase.ipc.RegionCoprocessorRpcChannel.callExecService(RegionCoprocessorRpcChannel.java:108)
>         at 
> org.apache.hadoop.hbase.ipc.CoprocessorRpcChannel.callBlockingMethod(CoprocessorRpcChannel.java:73)
>         at 
> org.apache.hadoop.hbase.protobuf.generated.AuthenticationProtos$AuthenticationService$BlockingStub.getAuthenticationToken(AuthenticationProtos.java:4512)
>         at 
> org.apache.hadoop.hbase.security.token.TokenUtil.obtainToken(TokenUtil.java:86)
>         at 
> org.apache.hadoop.hbase.security.token.TokenUtil$1.run(TokenUtil.java:111)
>         at 
> org.apache.hadoop.hbase.security.token.TokenUtil$1.run(TokenUtil.java:108)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at javax.security.auth.Subject.doAs(Subject.java:422)
>         at 
> org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1657)
>         at 
> org.apache.hadoop.hbase.security.User$SecureHadoopUser.runAs(User.java:340)
>         at 
> org.apache.hadoop.hbase.security.token.TokenUtil.obtainToken(TokenUtil.java:108)
>         at 
> org.apache.hadoop.hbase.security.token.TokenUtil.addTokenForJob(TokenUtil.java:329)
>         at 
> org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil.initCredentials(TableMapReduceUtil.java:490)
>         at 
> org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil.initTableMapperJob(TableMapReduceUtil.java:209)
>         at 
> org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil.initTableMapperJob(TableMapReduceUtil.java:162)
>         at 
> org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil.initTableMapperJob(TableMapReduceUtil.java:285)
>         at 
> org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil.initTableMapperJob(TableMapReduceUtil.java:86)
>         at 
> org.apache.hadoop.hbase.mapreduce.CellCounter.createSubmittableJob(CellCounter.java:193)
>         at 
> org.apache.hadoop.hbase.mapreduce.CellCounter.main(CellCounter.java:290)
> Caused by: 
> org.apache.hadoop.hbase.ipc.RemoteWithExtrasException(org.apache.hadoop.hbase.exceptions.UnknownProtocolException):
>  org.apache.hadoop.hbase.exceptions.UnknownProtocolException: No registered 
> coprocessor service found for name hbase.pb.AuthenticationService in region 
> hbase:meta,,1
>         at 
> org.apache.hadoop.hbase.regionserver.HRegion.execService(HRegion.java:7741)
>         at 
> org.apache.hadoop.hbase.regionserver.RSRpcServices.execServiceOnRegion(RSRpcServices.java:1988)
>         at 
> org.apache.hadoop.hbase.regionserver.RSRpcServices.execService(RSRpcServices.java:1970)
>         at 
> org.apache.hadoop.hbase.protobuf.generated.ClientProtos$ClientService$2.callBlockingMethod(ClientProtos.java:33652)
>         at org.apache.hadoop.hbase.ipc.RpcServer.call(RpcServer.java:2170)
>         at org.apache.hadoop.hbase.ipc.CallRunner.run(CallRunner.java:109)
>         at 
> org.apache.hadoop.hbase.ipc.RpcExecutor.consumerLoop(RpcExecutor.java:137)
>         at org.apache.hadoop.hbase.ipc.RpcExecutor$1.run(RpcExecutor.java:112)
>         at java.lang.Thread.run(Thread.java:745)
>         at 
> org.apache.hadoop.hbase.ipc.RpcClientImpl.call(RpcClientImpl.java:1270)
>         at 
> org.apache.hadoop.hbase.ipc.AbstractRpcClient.callBlockingMethod(AbstractRpcClient.java:226)
>         at 
> org.apache.hadoop.hbase.ipc.AbstractRpcClient$BlockingRpcChannelImplementation.callBlockingMethod(AbstractRpcClient.java:331)
>         at 
> org.apache.hadoop.hbase.protobuf.generated.ClientProtos$ClientService$BlockingStub.execService(ClientProtos.java:35420)
>         at 
> org.apache.hadoop.hbase.protobuf.ProtobufUtil.execService(ProtobufUtil.java:1628)
>         ... 22 more
> {noformat}
> This is talking to a 1.2 server.  Running with a 1.2 client works.  I believe 
> this is due to HBASE-14077, where we added package names to the protobuf 
> files.
> This is causing 1.2 and 1.3 to disagree on the name of the 
> AuthenticationService:
> * 1.2 = AuthenticationService
> * 1.3 = hbase.pb.AuthenticationService
> I think this is effectively a break in client-server wire compatibility 
> between 1.2 and 1.3, since this is calling a built-in coprocessor required 
> for security.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to