Turn On Locking with -x

The -x option can be appended to the -ci, -cI, -pk, -pK, -pl, and -pL options to place a shared lock on affected tables. While the table is locked, no other users can perform inserts, updates, and deletions while oncheck checks or prints the index. Without the -x option for tables with row locking, oncheck only places an IS (intent shared) lock on the table, which prevents actions such as dropping the table or the indexes during the check.

For example, the following sample command instructs oncheck to lock indexes for the customer table while it validates the order of key values, validates horizontal links, and ensures that no node appears twice in the index:
oncheck -cix stores_demo:customer

When you specify option -x, oncheck locks indexes for tables that use row locking. If oncheck detects page-lock mode, it displays a warning message and places a shared lock on the table regardless.

Copyright© 2019 HCL Technologies Limited