我要评分
获取效率
正确性
完整性
易理解

check Command

Prerequisites

Before running following commands, create a target database or ensure that a database has been created. The following assumes that a database already exists.

Procedure

  1. Go to a directory, for example, /home.
    1
    cd /home
    
  2. Check the SST file and verify its checksum.
    1
    sst_dump --file=/home/rocksdb/rkdb/000004.sst --command=check --verify_checksum
    

    In the preceding command, 000004.sst is an example file name. Change it to the actual one.

    1
    2
    3
    4
    [root@DC5-07-001 ~]# sst_dump --file=/home/rocksdb/rkdb/000004.sst --command=check --verify_checksum
    from [] to []
    Process  /home/rocksdb/rkdb/000004.sst
    Sst file format: block-based