Created on 11-15-2016 06:22 AM - edited 08-18-2019 03:18 AM
hello everyone,
My Phoenix's one index Become unavailable. Before can normal work .
but now other is normal.Details are as follows。x
My phoenix table name is "SysAction".
I Create index sql is create index SysActionLog_idx on "SysActionLog" ("CreateTime", "ModuleCode","AppCode","Invoker","ClientIP")
I execute sql with phoenix shell but find can't use phoenix index. How to solve this problem ?
I dont want to rebulid index because rebulid index may be shut down my hbase cluster
Created 11-21-2016 02:16 PM
There was bug with one api(PhoenixRuntime#getTable()) in HDP 2.2 where case sensitive tables are not handled properly, that's why automatic rebuilding is not happening to bring your disabled index up to date and make it active for use. Now you have two options either you can move to later version of HDP 2.3( or later ) or you can drop the current index and create ASYNC index on your table (as your table is large) and run IndexTool to create a index data for you by using map reduce job.
Refer for creating ASYNC index and running IndexTool:- http://phoenix.apache.org/secondary_indexing.html
Created 11-15-2016 06:29 AM
what is your primary key and is the primary key in the where clause? did you create local or global index?
Created 11-16-2016 04:14 AM
my primary key is "RowKey" IS NOT IN WHERE CLAUSE
Created 11-15-2016 07:13 AM
Can you first check whether your index is active or not.
https://community.hortonworks.com/articles/58818/phoenix-index-lifecycle.html
Created on 11-16-2016 06:51 AM - edited 08-18-2019 03:18 AM
Thanks.
I Find my table's index state is x ,How I can change this index state? rebuild it ?
Created on 11-16-2016 06:52 AM - edited 08-18-2019 03:18 AM
Thanks.
I Find my table's index state is x ,How I can change this index state? rebuild it ?
Created 11-16-2016 07:01 AM
From the snapshot you have provided writing to index got failed at timestamp 1478692767291 that's why the indexes got disabled. They will be automatically rebuild by the Phoenix in the background. If you see the index failure taking more time then you can drop the index and recreate it.
Created on 11-17-2016 02:05 AM - edited 08-18-2019 03:18 AM
I USE THIS commond
ALTER INDEX IF EXISTS SysActionLog_idx ON "SysActionLog" REBUILD;
but error
the error is timeout. so i change phoeinx query sql timeout
but index current state is
i execute rebuild command but the other error occured,I cant drip index ,because my cluster is not strong ,cant create index success
this table is 800G.
Created 11-17-2016 05:29 AM
My HDP Version HDP-2.4.2.0-258, I diont change config about phoenix default paramater
but I didn't find my index is rebuilded automatically because this index'state is always rebuild(b)
why? Thanks !
Created 11-17-2016 08:43 AM
The index rebuild does full table scan of data table there is a chance of timeout. Can you try increasing the timeout values of below properties and retry rebuilding index. Once you add/change the configurations then you need to export HBASE_CONF_DIR or HBASE_CONF_PATH with directly having hbase-site.xml.
|