linux系统: CentOS6.7
Hadoop版本: 2.6.5
zookeeper版本: 3.4.8
192.168.179.201: m1
192.168.179.202: m2
192.168.179.203: m3
m1: Zookeeper, Namenode, DataNode, ResourceManager, NodeManager, Master, Worker
m2: Zookeeper, Namenode, DataNode, ResourceManager, NodeManager, Worker
m3: Zookeeper, DataNode, NodeManager, Worker
官方资料:
https://cwiki.apache.org/confluence/display/Hive/IndexDev
https://cwiki.apache.org/confluence/display/Hive/LanguageManual+DDL#LanguageManualDDL-Create/Drop/AlterIndex
<property>
<name>hive.optimize.index.filtername>
<value>truevalue>
property>
<property>
<name>hive.optimize.index.groupbyname>
<value>truevalue>
property>
<property>
<name>hive.index.compact.file.ignore.hdfsname>
<value>truevalue>
property>
官方资料:
https://cwiki.apache.org/confluence/display/Hive/LanguageManual+Indexing
create index table01_index on table table01 (column2) as 'compact';
show index on table01;
drop index table01_index on table01;
create index table02_index on table table02 (column3) as 'compact' with deferred rebuild;
alter index table02_index on table2 rebuild;
show formatted index on table02;
drop index table02_index on table02;
create index table03_index on table table03 (column4) as 'bitmap' with deferred rebuild;
alter index table03_index on table03 rebuild;
show formatted index on table03;
drop index table03_index on table03;
create index table04_index on table table04 (column5) as 'compact' with deferred rebuild in table table04_index_table;
create index table05_index on table table05 (column6) as 'compact' stored as RCFile;
create index table06_index on table table06 (column7) as 'compact' row format delimited fields terminated by '\t' stored as textFile;
create index table07_index on table table07 (column8) as 'COMPACT' idxproperties ("prop1"="value1", "prop2"="value2");
create index table08_index on table table08 (column9) as 'compact' tblproperties ("prop3"="value3", "prop4"="value4");
drop index if exists table09_index on table09;
alter index table10_index on table10 partition (columnX='valueQ', columnY='valueR') rebuild;