Realm: Zonegroup: 理解为数据中心,由一个或多个Zone组成,每个Realm有且仅有 一个Master Zonegroup,用于处理系统变更,其他的称为Slave Zonegroup,元数据与Master Zonegroup保持一致;

Zone: Zone是一个逻辑概念,包含一个或者多个RGW实例。每个Zonegroup有且仅有一个Master Zone,用于处理bucket和user等元数据变更。

Period: 保存realm当前的配置信息,使用epoch维护版本信息。

Metadata Sync:Zone是一个逻辑概念,包含一个或者多个RGW实例。每个Zonegroup有且仅有一个Master Zone,用于处理bucket和user等元数据变更。

systemctl restart ceph-radosgw@rgw.hostname

创建realm:

A realm contains the notion of periods. Each period represents the state of the zone group and zone configuration in time.Each time you make a change to a zonegroup or zone, update the period and commit it.

realm里所有的元数据名称都是全局唯一的,无法创建同名的用户(uid)和bucket, container;

radosgw-admin realm create --rgw-realm=Giant --default

查看存在的realm:

radosgw-admin realm list

创建Master zonegroup:

删除 Default ZoneGroup并创建Master ZoneGroup

为了前向兼容,所以会存在默认的zonegroup,需要删除

radosgw-admin zonegroup delete --rgw-zonegroup=default

radosgw-admin zonegroup create --rgw-zonegroup=beijing --endpoints=beijing.com --master --default

查看zonegroup相关信息:

radosgw-admin zonegroup list

radosgw-amdin zonegroup get {zonegroup name}

创建Master zone:

删除default Zone 并创建Master Zone

为了前向兼容,所以默认存在zone,需要删除

radosgw-admin zone delete --rgw-zone=default

#创建Master zone,并指定zonegroup

radosgw-admin zone create --rgw-zonegroup=beijing --rgw-zone=beijing --endpoints=beijing.com --access-key=admin --secret=admin --default --master

Secondary Zones:

You must execute metadata operations, such as user creation, on a host within the master zone. The master zone and the secondary zone can receive bucket operations, but the secondary zone redirects bucket operations to the master zone. If the master zone is down, bucket operations will fail.

Bucket Sharding

主要为了解决.rgw.buckets.index pool的性能问题;该pool下存放了bucket index data;

rgw_override_bucket_index_max_shards

default: 0 #不启用分片

推荐值: {number of objects expected in a bucket / 100,000}

max value: 7877

The default value for rgw_max_objs_per_shard is 100k objects per shard.

动态修改sharding值: rgw_dynamic_reshading = true

rgw_reshard_num_logs: The number of shards for the resharding log. The default value is 16.

rgw_reshard_bucket_lock_duration: The duration of the lock on a bucket during resharding. The default value is 120 seconds.

rgw_dynamic_resharding: Enables or disables dynamic resharding. The default value is true.

rgw_max_objs_per_shard: The maximum number of objects per shard. The default value is 100000 objects per shard.

rgw_reshard_thread_interval: The maximum time between rounds of reshard thread processing. The default value is 600 seconds.

将bucket加入resharding 队列:

radosgw-admin bucket reshard add --bucket --num-shards

查看resharding队列:

radosgw-admin bucket reshard list

手动执行reshard:

radosgw-admin bucket reshard process

取消在bucket resharding期间取消resharding:

radosgw-admin bucket reshard cancel --bucket

压缩:compression

压缩插件: zlib: 支持 snappy, zstd: 预览版

radosgw-admin zone placement modify --rgw-zone=default --placement-id=default-placement --compression=zlib

After enabling or disabling compression, restart the Ceph Object Gateway instance so the change will take effect.

$ radosgw-admin bucket stats --bucket= { ... "usage": { "rgw.main": { "size": 1075028, "size_actual": 1331200, "size_utilized": 592035, "size_kb": 1050, "size_kb_actual": 1300, "size_kb_utilized": 579, "num_objects": 104 } }, ... }

The size_utilized and size_kb_utilized fields represent the total size of compressed data in bytes and kilobytes respectively.

Quota 管理:

Quotas include the maximum number of objects in a bucket and the maximum storage size in megabytes.

IMPORT: Buckets with a large number of objects can cause serious performance issues.

The recommended maximum number of objects in a one bucket is 100,000. To increase this number,

configure bucket index sharding

Set User Quotas:

radosgw-admin quota set --quota-scope=user --uid= [--max-objects=] [--max-size=]

eg:

radosgw-admin quota set --quota-scope=user --uid=johndoe --max-objects=1024 --max-size=1024

A negative value for num objects and / or max size means that the specific quota attribute check is disabled.

Ebable and Disable User Quotas:

#radosgw-admin quota enable --quota-scope=user --uid=

#radosgw-admin quota disable --quota-scope=user --uid=

Set Bucket Quotas:

#radosgw-admin quota set --uid= --quota-scope=bucket [--max-objects=] [--max-size=

Enable and Disable Bucket Quotas

#radosgw-amdin quota enable --quota-scope=bucket --uid=

#radosgw-admin quota-disable --quota-scope=bucket --uid=

Get Quota Settings

#radosgw-admin user info --uid=

Update Quota Stats

#radosgw-admin user stats --uid= --sync-stats

Get User Quota Usage Stats

#radosgw-admin user stats --uid=

Quota Cache:

rgw bucket quota ttl, rgw user quota bucket sync interval, rgw user quota sync interval.

统计用户

#radosgw-admin usage show --uid=johndeo --start-data=2012-03-01 --end-date=2012-04-01

#radosgw-amdin usage show --show-log-entri

清理孤儿对象:

create a new log pool:

1、rados mkpool .log

2、radosgw-admin orphans find --pool= --job-id= [--num-shards=] [--orphan-stale-secs=]

3、radosgw-admin orphans find --pool=.rgw.buckets --job-id=abc123

4、Clean up the search data:

radosgw-amdin orphans finish --job-id=abc123

Zones:

Ceph Object Gateway supports the notion of zones. A zone defines a logical group consisting of one or more Ceph Object Gateway instances.

ceph rgw java_ceph rgw multisite基本用法相关推荐

  1. 【转】Ceph对象存储(rgw)的IPv6环境配置

    引言 在搭建成功Ceph集群后,对于如何使用,其实我还是一脸MB的,心想竟然提供三种存储接口(对象,文件,快),口气也未免太大.在结合项目需求之后,我选择了对象存储接口.那么问题又来了,如何配置IPv ...

  2. Ceph对象存储(rgw)的IPv6环境配置

    本文作者: lemon 本文链接: https://lemon2013.github.io/2016/11/09/Ceph对象存储-rgw-IPv6环境配置/ 版权声明: 本博客所有文章除特别声明外, ...

  3. Ceph-ansible 安装 ceph (rbd + rgw)

    实验环境: 3 台 monitor 节点:centos7.6 操作系统 3台 osd 节点: centos7.6 操作系统,每台 20 块磁盘 所有节点上配置好 ceph yum repo 源(lum ...

  4. 趣解 ceph rgw multisite data sync 机制

    multisite是ceph rgw对象数据异地容灾备份的一个有效方案,笔者希望深入理解该技术,并应用于生产环境中,然而rgw的这部分代码晦涩难懂,笔者多次尝试阅读,仍云里雾里不解其意,最终流着泪咬着 ...

  5. Ceph使用系列之——Ceph RGW使用

    本文分享主题是<Ceph使用系列之--Ceph RGW使用>,欢迎关注. Ceph RGW介绍 Ceph对象网关是在librados之上构建的对象存储接口,旨在为应用程序提供通往Ceph存 ...

  6. ceph——rgw服务启不起来

    环境:SUSE SESv5版本--对应社区ceph的L版本(12.2) 故障背景:在给ceph集群扩充第四个节点的时候,运行到stage4,报错: sesadmin:~ # salt-run stat ...

  7. CEPH J版本新特性RGW Multi-tenancy详解

    CEPH官方对RGW Multi-tenancy的介绍如下 RGW Multi-tenancy 多租户特性允许创建使用不同的存储桶和用户,前提是将其分离在不同的租户之下.例如,允许不同租户下的Swif ...

  8. Ceph使用---块设备、RGW、CephFS初步使用

    一.ceph应用逻辑图 1.1.rbd块设备应用 [root@ceph-deploy ~]# ceph osd pool create myrbd1 64 64 #创建存储池,指定pg和pgp的数量, ...

  9. ceph s3 rgw配置

    参考如下: root@ceph01:~# ceph orch apply rgw myorg ceph01 Scheduled rgw.myorg update... root@ceph01:~# c ...

最新文章

  1. matlab中的转义字符使用和说明
  2. 一个物理学家学习Windows编程的感受
  3. [转]js判断url是否有效
  4. c# url传参不能包含html标签,c#解析包含HTML特殊字符的字符串XElement
  5. 千锋教育python全集_千锋python+人工智能最新视频教程(大全集)
  6. 【今日CV 计算机视觉论文速览】Tue, 26 Feb 2019
  7. linux远程开启不挂起的服务
  8. ActiveMQ实现负载均衡+高可用部署方案 -转载
  9. 流媒体传输协议浅析(三)可靠UDP传输方案
  10. 小程序外包需要注意哪些事情(小程序外包开发流程)
  11. php读取剪贴板内容,jQuery获取剪贴板内容的方法
  12. FAT文件系统与文件恢复
  13. 读书笔记010:《伤寒论》- 足少阴肾经
  14. 用水泥混凝土摊铺机进行作业时该做到的日常养护工作
  15. 成为测试/开发程序员,小张:现实就来了个下马威......
  16. 思博伦Spirent TestCenter _如何使用抓包过滤功能抓取特定的帧_双极未来
  17. lisp 左手钢筋_CAD左手键与加载过程.docx
  18. Linux操作系统分析-课程总结报告
  19. 《水经注地图服务》发布的卫星影像数据在QGIS中调用
  20. python以表格形式打印出结果——PrettyTable

热门文章

  1. python3支持中文_彻底颓了—— Vim Python 3 接口不支持中文 - Jacky Liu's Blog
  2. python3小游戏源代码_Python3制作仿“FlappyBird”小游戏|python3教程|python入门|python教程...
  3. mysql生成app接口_Java实现app接口和Socket消息传递(10)java连接MySQL实现App登录接口...
  4. Matlab在坐标点上按顺序标序号
  5. 初中数学知识点总结_初中物理 | 最全知识点总结
  6. vue点击弹窗自动触发点击事件的解决办法
  7. Bash脚本教程之read命令
  8. 如何获取电脑网站(手机网站)支付宝支付的配置信息(appid、商户私钥、支付宝公钥)
  9. docker更换国内镜像源
  10. kail利用msf工具对ms17-010(永恒之蓝)漏洞入侵渗透Win7