You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "Jeffrey Zhong (JIRA)" <ji...@apache.org> on 2015/02/13 04:27:12 UTC

[jira] [Updated] (PHOENIX-1078) Unable to run pig script with Phoenix in a secure HBase cluster

     [ https://issues.apache.org/jira/browse/PHOENIX-1078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jeffrey Zhong updated PHOENIX-1078:
-----------------------------------
    Attachment: PHOENIX-1078.patch

It took me a while to pass all necessary configurations to MR job. When running in security Phoenix cluster, a user needs to make sure hbase-site.xml should be in Pig class path.

> Unable to run pig script with Phoenix in a secure HBase cluster
> ---------------------------------------------------------------
>
>                 Key: PHOENIX-1078
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1078
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 3.0.0
>            Reporter: Anil Gupta
>              Labels: 3.0.0
>         Attachments: PHOENIX-1078.patch
>
>
> I am running the HBase0.94.15 and latest phoenix 3.1 nightly build. I have to use pig on phoenix views. This is a secure HBase cluster. When i run the job i get following error:
> ERROR org.apache.hadoop.hbase.io.HbaseObjectWritable - Error in readFields
> java.lang.NegativeArraySizeException: -1
>     at org.apache.hadoop.hbase.util.Bytes.readByteArray(Bytes.java:175)
>     at org.apache.phoenix.schema.PColumnImpl.readFields(PColumnImpl.java:157)
>     at org.apache.phoenix.schema.PTableImpl.readFields(PTableImpl.java:721)
>     at org.apache.phoenix.coprocessor.MetaDataProtocol$MetaDataMutationResult.readFields(MetaDataProtocol.java:161)
>     at org.apache.hadoop.hbase.io.HbaseObjectWritable.readObject(HbaseObjectWritable.java:692)
>     at org.apache.hadoop.hbase.io.HbaseObjectWritable.readObject(HbaseObjectWritable.java:596)
>     at org.apache.hadoop.hbase.client.coprocessor.ExecResult.readFields(ExecResult.java:83)
>     at org.apache.hadoop.hbase.io.HbaseObjectWritable.readObject(HbaseObjectWritable.java:692)
>     at org.apache.hadoop.hbase.io.HbaseObjectWritable.readFields(HbaseObjectWritable.java:333)
>     at org.apache.hadoop.hbase.ipc.SecureClient$SecureConnection.receiveResponse(SecureClient.java:383)
>     at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.run(HBaseClient.java:588)
> Here is my pig script:
> register /tmp/phoenix-3.1-jars/phoenix-core-3.1.0-SNAPSHOT.jar;
> register /tmp/phoenix-3.1-jars/phoenix-pig-3.1.0-SNAPSHOT.jar;
> A = load 'hbase://query/SELECT * from test_table' using org.apache.phoenix.pig.PhoenixHBaseLoader('ZK');
> grpd = GROUP A BY UNSIGNED_DATE_COLUMN;
> cnt = FOREACH grpd GENERATE group AS UNSIGNED_DATE_COLUMN,COUNT(A);
> DUMP cnt;



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