gpcheckcat - Part 2

  1. What is gpchectkcat?
  2. When should gpcheckcat be run?
  • In-Short: The gpcheckcat script is used to test tables for inconsistencies.
  • Better Explanation :
  1. This script executes multiple tests to check database catalog inconsistencies. 
  2. Few tests are recommended to be run only when the system is not available to users. 
  3. Such tests are called has Off-line tests. 
  4. These cannot be run concurrently with other workload or the results wil not be usable. So how to run such tests? its always better to start the database in restricted mode when running gpcheckcat, restricted mode helps in preventing users connections reaching database. 
  5. There is a trick to run gpcheckcat without putting database in restricted mode, just set database connection to 0. 
  6. Then terminate all existing users connections. When we run this script, it checks for and removes orphaned, temporary database schemas in the specified database. 
  7. The same will also be reported in command line and logs.
  8. Catalog inconsistencies are inconsistencies that occur between database system tables. 
  9. There are 3 types of inconsistencies:
  • Inconsistencies in system tables at the segment level. 
  • Inconsistencies between same system table across segments.
  • Persistent table inconsistencies are inconsistencies in persistence object state and file system objects on a segments.
  1. It is always better to run Online gpcheckcat on daily bases. (-O option). This is nowhere related to database size. 
  2. It is a best partice to run Offline gpchechcat on all databases at least once in a Month. Most preferred method is to run once in a week (depending on maintenance window).

Comments

Popular posts from this blog

GP - Kerberos errors and resolutions

How to set Optimizer at database level in greenplum

GP - SQL Joins