Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does msck stands for in Msck repair command

Hive Msck repair command is used to repair partitions, but what is full form of MSCK.

I already tried to find in hive doc's but hard luck.

like image 215
Kaustubh Deshpande Avatar asked Dec 30 '17 15:12

Kaustubh Deshpande


People also ask

What is MSCK repair command?

The MSCK REPAIR TABLE command scans a file system such as Amazon S3 for Hive compatible partitions that were added to the file system after the table was created. MSCK REPAIR TABLE compares the partitions in the table metadata and the partitions in S3.

Why does MSCK repair table take so long?

MSCK is slow because it is waiting for S3 listing among other things. Athena would read the entire 9.7MB table if it were in one file faster than it would be able to list that huge directory structure. I recommend removing the partitions completely, or if you really must have them then remove p2, p3 and p4 levels.


1 Answers

Similar to how fsckstands for filesystem consistency check, msck is Hive's metastore consistency check.

like image 53
Dennis Huo Avatar answered Oct 07 '22 16:10

Dennis Huo