kylin Cannot delete segment as its status is not READY. Discard
the on-going job for it.
注:无法删除segment
build时发现报error:
There is already 10 building segment
此时应该是segment损坏,删除segment时发现无法删除
解决:
1.备份元数据
./bin/metastore.sh backup
2.进入元数据备份目录删除损坏的segment:
cd $KYLIN_HOME/meta_backups/meta_2018_06_27_08_30_49/cube
vim kylin_cube.json
{
"uuid" : "5877617f-5fd1-40b5-bdc9-fd59945135af",
"name" : "20180626000000_20180627000000",
"storage_location_identifier" : "KYLIN_8SJTX5SBNM",
"date_range_start" : 1528416000000,
"date_range_end" : 1528502400000,
"source_offset_start" : 0,
"source_offset_end" : 0,
"status" : "NEW",
"size_kb" : 0,
"input_records" : 0,
"input_records_size" : 0,
"last_build_time" : 0,
"last_build_job_id" : null,
"create_time_utc" : 1529030216244,
"cuboid_shard_nums" : { },
"total_shards" : 0,
"blackout_cuboids" : [ ],
"binary_signature" : null,
"dictionaries" : null,
"snapshots" : null,
"rowkey_stats" : [ ]
}
不要删错,或者多删
3.恢复元数据:
/bin/metastore.sh reset
./bin/metastore.sh restore $KYLIN_HOME/meta_backups/meta_2018_06_27_08_30_49