Learning problems (phoenix for cdh5.9 build and Precautions) hadoop encounter

Reference Document https://www.cnblogs.com/zlslch/p/7096402.html


Three cluster nodes mini1, MINI2, Mini3
1, download the
phoenix for CDH download location, and I downloaded version 5.9 is the highest currently phoenix corresponding cdh, but I use the highest CDH version 5.13 (the highest version 5.13 test, production using a CDH5.11)
https://github.com/chiastic-security/phoenix-for-cloudera/tree/4.9-HBase-1.2-cdh5.9
 

 2, the compiler phoenix for CDH5.9 source package
tops with a maven maven, computer, I'm 3.3.9 version of maven. Do not be too concerned about which version is installed maven feeling can be compiled. (Maven how to install Baidu a lot)
and then enter the Start menu cmd, compiled
into the path you store the phoenix of the source code, I was on the G: \ Phoenix \ phoenix-for -cloudera-4.9-HBase-1.2-cdh5.9
 

 

Direct compile command:

mvn clean package -DskipTests

(Note: The transition process will be very slow, very slow, very slow ......... and the process will complain compilation fails, then compile more than a few times ... I was compiled after N times people ... collapse)

 Appear as shown above, congratulations you compile Success! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! !

 

After packed and generally in the target folder.

 

3. The phoenix-4.9.0-cdh5.9.1.tar.gz, upload cdh of hbase clusters, extract the tar package, tar package I put / home / phoenix directory: Extract

The phoenix-4.9.0-cdh5.9.1-server.jar RegionServer packet copy to each node of the
path to see how you installed RegionServer the CDH. But generally are in default
under /opt/cloudera/parcels/CDH-5.13.0-1.cdh5.13.0.p0.29/lib/hbase/lib, path
(mainly check this directory: /cloudera/parcels/CDH-5.13 .0-1.cdh5.13.0.p0.29 / lib / hbase / lib)
each node must!
 

CDH modification method:
increase hbase-site.xml configuration
<property> <name> hbase.table.sanity.checks < / name> <value> false </ value> </ property>
 Add the following manner:
In the Cluster Management page, click Hbase enter Hbase management interface
 

 

 Restart Hbase  

    This is very simple, not more than that, I will play cloudermanager knows.

 

Log in phoenix

  Enter phoenix-4.8.0-cdh5.8.0 / bin directory to perform.

 

Enter phoenix, (mini1: 2181, not zk the leader node, but the current node)

 

select * from "device_report" limit 10; can be queried. . . .

 

I first built in Table hbase: score, cluster column is a, three data insertion, as follows

 

 

device_report, score which even a table I have and hbase mapped over, the mapping method is:
the Create the Table "Score" (.. NAME archar Primary Key, "A" "Age" VARCHAR, "A" "Sex" VARCHAR); 
Note : table score, must be double quotes! Column cluster and column name is the same double quotes!
Attention to the problem:
Phoenix is case-sensitive, hbase when construction of the table, the table name with quotation marks can also search lowercase, lowercase field conditions definitely do not support, so when hbase build the table, it is strongly recommended, table name, column clusters, rowkey, column names are capitalized, and you can join a phoenix.
I do not know why, a query with a long field where the process of inquiry, you can not find the newspaper columns and column names
Column: try a lot in the following form
select * from "score" where " age" = "16";
. SELECT * from "Score" WHERE "A" "Age" = "16";
SELECT * from "Score" WHERE "a.age" = "16";
SELECT * from "Score" WHERE "A: Age" = " 16 ";
 SELECT * from" Score "WHERE Age = 16;


 

Guess you like

Origin blog.csdn.net/madongyu1259892936/article/details/89203400