您好,登錄后才能下訂單哦!
這期內(nèi)容當(dāng)中小編將會(huì)給大家?guī)碛嘘P(guān)RWG中怎么創(chuàng)建自定義數(shù)據(jù)pool,文章內(nèi)容豐富且以專業(yè)的角度為大家分析和敘述,閱讀完這篇文章希望大家可以有所收獲。
創(chuàng)建數(shù)據(jù)pool,注意每個(gè)pool的pg配置規(guī)劃,可以參考http://ceph.com/pgcalc/進(jìn)行設(shè)計(jì)
ceph osd pool create .rgw.root 16 16 ceph osd pool create demo.rgw.data.root 16 16 ceph osd pool create demo.rgw.control 16 16 ceph osd pool create demo.rgw.gc 16 16 ceph osd pool create demo.rgw.log 16 16 ceph osd pool create demo.rgw.intent-log 16 16 ceph osd pool create demo.rgw.usage 16 16 ceph osd pool create demo.rgw.users.keys 16 16 ceph osd pool create demo.rgw.users.email 16 16 ceph osd pool create demo.rgw.users.swift 16 16 ceph osd pool create demo.rgw.users.uid 16 16 ceph osd pool create demo.rgw.buckets.index 16 16 ceph osd pool create demo.rgw.buckets.data 64 64 ceph osd pool create demo.rgw.buckets.non-ec 16 16
ceph.conf配置
[client.radosgw.us-zone1] rgw dns name = s3.ceph.work rgw frontends = "civetweb port=80" host = radosgw-1 keyring = /etc/ceph/ceph.client.radosgw.keyring rgw socket path = /home/ceph/var/run/ceph-client.radosgw.us-zone1.sock log file = /home/ceph/log/radosgw.us-zone1.log rgw print continue = false rgw content length compat = true
zone配置
# zone.json { "id": "2f58efaa-3fa2-48b2-b996-7f924ae1215c", "name": "demo", "domain_root": "demo.rgw.data.root", "control_pool": "demo.rgw.control", "gc_pool": "demo.rgw.gc", "log_pool": "demo.rgw.log", "intent_log_pool": "demo.rgw.intent-log", "usage_log_pool": "demo.rgw.usage", "user_keys_pool": "demo.rgw.users.keys", "user_email_pool": "demo.rgw.users.email", "user_swift_pool": "demo.rgw.users.swift", "user_uid_pool": "demo.rgw.users.uid", "system_key": { "access_key": "", "secret_key": "" }, "placement_pools": [ { "key": "default-placement", "val": { "index_pool": "demo.rgw.buckets.index", #index pool "data_pool": "demo.rgw.buckets.data", #數(shù)據(jù)pool "data_extra_pool": "demo.rgw.buckets.non-ec", "index_type": 0 } } ], "metadata_heap": "", "realm_id": "" }
zonegroup配置
# zonegroup.json { "id": "9d07fb3c-45d7-4d63-a475-fd6ebd41b722", #Zonegroup的ID "name": "zg", #zonegroup名稱 "api_name": "", #bucket的localtion定義在這里 "is_master": "true", "endpoints": [], "hostnames": [], "hostnames_s3website": [], "master_zone": "2f58efaa-3fa2-48b2-b996-7f924ae1215c", #zone的ID "zones": [ { "id": "2f58efaa-3fa2-48b2-b996-7f924ae1215c", #zone的ID "name": "demo", #zone名稱 "endpoints": [], "log_meta": "false", "log_data": "false", "bucket_index_max_shards": 0, "read_only": "false" } ], "placement_targets": [ { "name": "default-placement", "tags": [] } ], "default_placement": "default-placement", "realm_id": "" }
radosgw-admin realm create --rgw-realm=nt --default #新建一個(gè)realm名稱為nt radosgw-admin zonegroup set < zonegroup.json --rgw-realm=nt --rgw-zonegroup=zg --default #導(dǎo)入之前的zonegroup配置,zonegroup名稱為zg radosgw-admin zone set < zone.json --rgw-zonegroup=zg --rgw-zone=demo --master --default #導(dǎo)入zone配置,zone名稱為demo /etc/init.d/radosgw start #啟動(dòng)服務(wù)
新建用戶
radosgw-admin user create --uid=s3user --display-name=s3user
ceph df GLOBAL: SIZE AVAIL RAW USED %RAW USED 92114M 88985M 3128M 3.40 POOLS: NAME ID USED %USED MAX AVAIL OBJECTS .rgw.root 73 2072 0 88558M 12 demo.rgw.data.root 74 609 0 88558M 2 demo.rgw.control 75 0 0 88558M 8 demo.rgw.gc 76 0 0 88558M 32 demo.rgw.log 77 50 0 88558M 128 demo.rgw.intent-log 78 0 0 88558M 0 demo.rgw.usage 79 0 0 88558M 0 demo.rgw.users.keys 80 13 0 88558M 1 demo.rgw.users.email 81 0 0 88558M 0 demo.rgw.users.swift 82 0 0 88558M 0 demo.rgw.users.uid 83 329 0 88558M 2 demo.rgw.buckets.index 84 0 0 88558M 1 demo.rgw.buckets.data 85 0 0 88558M 0 demo.rgw.buckets.non-ec 86 0 0 88558M 0
demo.rgw.users.keys和demo.rgw.users.uid 的OBJECTS>0,說明已經(jīng)成功。
上述就是小編為大家分享的RWG中怎么創(chuàng)建自定義數(shù)據(jù)pool了,如果剛好有類似的疑惑,不妨參照上述分析進(jìn)行理解。如果想知道更多相關(guān)知識(shí),歡迎關(guān)注億速云行業(yè)資訊頻道。
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請(qǐng)聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。