跳转至

seabox flashback-cleanup

seabox flashback-cleanup

闪回清理工具

语法

``` bash seabox flashback-cleanup [OPTIONS]

Options: -x, –xid TEXT the cluster gxid for flashback -T, –timestamp TEXT flashback cluster by timestamp -y, –assumeyes answer yes for all questions -h, –help show this help, then exit ```

描述

清理集群开启闪回后的残留数据文件

  • 注意:如有注意事项,补充
选项

该命令支持选项说明如下:

Options

命令支持的选项

-T, --timestamp
指定清理的目标时间戳
-y, --assumeyes
所有的提问按照yes执行
--dry-run
将要执行的删除命令输出到文件中,实际上不执行
-o, --output TEXT
指定dry-run选项输出到的文件路径,默认路径为$SDHOME/flashback_cleanup_tmp.log
--full-cleanup
执行一次完全的清理,不仅清理带有cleanup标记的文件,也会清理不带cleanup标记,但是是脏数据的数据文件
-v, --verbose
显示详细日志
-h, --help
使用该选项时返回seabox flashback-cleanup命令的帮助信息
示例

以下是seabox flashback-cleanup --help的执行结果:

[seabox@mpp-test-1 bin]$ seabox flashback-cleanup --help
cleanup dropped relation files in flashback mode

Usage:
  seabox flashback-cleanup [OPTIONS]

Options:
  -T, --timestamp TEXT  cleanup cluster by timestamp
  -y, --assumeyes       answer yes for all questions
  -v, --verbose         show verbose runtime output
  -o, --output TEXT     cleanup dry run result output file path
  --dry-run             perform a trial run with no actual cleanup
  --full-cleanup        scan all relation files and check if they need to be
                        cleanup
  -h, --help            show this help, then exit

执行集群清理

seabox flashback-cleanup

清理指定时间戳

seabox flashback-cleanup -T TIMESTAMP

执行一次测试清理,输出将要执行的清理命令

seabox flashback-cleanup --dry-run -o OUTPUT_FILE

指定时间戳执行完全清理

seabox flashback-cleanup --full-cleanup -T TIMESTAMP

注解
如果命令不指定一个时间戳,则会清理到最新的满足一致性的事务。
相关命令