mc replicate edit

mc replicate edit 子命令用来修改现有的服务器端复制配置规则,语法如下:

C:\> mc replicate edit -h
NAME:
  mc replicate edit - modify an existing server side replication configuration rule

USAGE:
  mc replicate edit TARGET

FLAGS:
  --config-dir value, -C value  path to configuration folder (default: "C:\\Users\\Administrator\\mc")
  --quiet, -q                   disable progress bar display
  --no-color                    disable color theme
  --json                        enable JSON lines formatted output
  --debug                       enable debug output
  --insecure                    disable SSL certificate verification
  --id value                    id for the rule, should be a unique value
  --tags value                  format '<key1>=<value1>&<key2>=<value2>&<key3>=<value3>', multiple values allowed for multiple key/value pairs
  --storage-class value         storage class for destination (STANDARD_IA,REDUCED_REDUNDANCY etc)
  --state value                 change rule status. Valid values are [enable|disable]
  --priority value              priority of the rule, should be unique and is a required field (default: 0)
  --remote-bucket value         destination bucket, should be a unique value for the configuration
  --replicate value             comma separated list to enable replication of delete markers, deletion of versioned objects and syncing replica metadata modifications.Valid options are "delete-marker", "delete","replica-metadata-sync", "existing-objects" and ""
  --help, -h                    show help

示例

(1)更改别名为 “myminio” 的 MinIO 存储服务上的存储桶 “mybucket” 上规则 ID 为 “bsibgh8t874dnjst8hkg” 的规则优先级。

C:\> mc replicate edit myminio/mybucket --id "bsibgh8t874dnjst8hkg"  --priority 3

(2)在目标 myminio/bucket 上禁用规则 ID 为 “bsibgh8t874dnjst8hkg” 的复制配置规则。

C:\> mc replicate edit myminio/mybucket --id "bsibgh8t874dnjst8hkg" --state disable

(3)在目标 myminio/bucket/prefix 上使用规则 ID 为 “kMYD.491” 的复制配置上设置标签和存储类。

C:\> mc replicate edit myminio/mybucket --id "kMYD.491" --tags "key1=value1&key2=value2" \
          --storage-class "STANDARD" --priority 2

(4)清除目标 myminio/bucket 上 ID 为 “kMYD.491” 的复制配置规则的标签。

C:\> mc replicate edit myminio/mybucket --id "kMYD.491" --tags ""

(5)在目标 myminio/bucket 上对 ID 为 “kxYD.491” 的复制配置规则启用删除标记复制。

C:\> mc replicate edit myminio/mybucket --id "kxYD.491" --replicate "delete-marker"

(6)在目标 myminio/bucket 上对 ID 为 “kxYD.491” 的复制配置规则禁用删除标记和版本化删除复制。

C:\> mc replicate edit myminio/mybucket --id "kxYD.491" --replicate ""

(7)在目标 myminio/bucket 上启用 ID 为 “kxYD.491” 的配置规则上的现有对象复制。规则以前启用了删除标记和版本化删除复制。

C:\> mc replicate edit myminio/mybucket --id "kxYD.491" --replicate "existing-objects,delete-marker,delete"
说说我的看法
全部评论(
没有评论
关于
本网站属于个人的非赢利性网站,转载的文章遵循原作者的版权声明,如果原文没有版权声明,请来信告知:hxstrive@outlook.com
公众号