Other options with -u
Use the -u option of the oncheck utility to restrict the checking of an R-tree index to specific levels or pages. You can also use this option to perform a cleanup of the index. Unlike the other default options of the oncheck utility, the -u option always takes at least one parameter, enclosed in double quotes. The available parameters are described later on in this section.
You must use the -u option of the oncheck utility in combination with one of the default options (-pk, -pK, -pl, -pL, -ci, or -cI).
The -u option applies to R-tree indexes only. You cannot use this option to check other types of indexes, such as B-tree.
- slevel(N)
- Starts checking at the level in the R-tree structure specified
by the value of N
By default, the oncheck utility starts checking at level 0 or at the root page.
- elevel(M)
- Stops checking the R-tree structure after you check level M
By default, the oncheck utility stops checking at the last level of the R-tree structure.
- spage(pg)
- Starts checking only when a page number matches pg
By default, the oncheck utility starts checking at the root page.
- rtree_cleanup
- Cleans up an R-tree index
Cleaning up an index includes freeing unused pages, tightening bounding boxes, and merging almost-unused pages.
If you specify this parameter, the database server takes an exclusive lock on the index fragment currently being cleaned up.
You cannot specify any of the other -u parameters with the rtree_cleanup parameter.
The preceding parameters apply to each fragment. For example, if you specify -u "spage(5)", each fragment is checked starting at page 5, assuming it exists in the fragment.
oncheck -pk -u "slevel(2)" rtree_db:polygons
oncheck -pk -u "slevel(2),elevel(5)" rtree_db:polygons
oncheck -pk -u "rtree_cleanup" rtree_db:polygons