Rate This Document
Findability
Accuracy
Completeness
Readability

Configuring Object Storage

Defining Ceph Service Requirements

  1. Open the site.yml file.
    1
    vim site.yml
    
  2. Add the definition of rgws under the hosts option.
     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    - hosts:
    - mons
    - osds
    #  - mdss
    - rgws
    #  - nfss
    #  - rbdmirrors
    - clients
    - mgrs
    #  - iscsigws
    #  - iscsi-gws # for backward compatibility only!
    #  - grafana-server
    #  - rgwloadbalancers
    

Defining the Cluster Host Service

Define the nodes where the RGW service is located. In this example, the nodes are ceph 1 and ceph 2.
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
[mons]
ceph1

[mgrs]
ceph1

[osds]
ceph1
ceph2

#[mdss]
#ceph1
#ceph2

[rgws]
ceph1
ceph2

[clients]
client3


[grafana-server]
ceph1

Defining the Ceph Cluster Configuration

In the all.yml file, set the front-end network type, port, and number of RGW instances on each RGW node.

  • Online Ceph download mode
     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    ceph_origin: repository
    ceph_repository: community
    ceph_mirror: http://download.ceph.com
    ceph_stable_release: nautilus
    ceph_stable_repo: "{{ ceph_mirror }}/rpm-{{ ceph_stable_release }}"
    ceph_stable_redhat_distro: el7
    monitor_interface: enp133s0
    journal_size: 5120
    public_network: 172.19.106.0/0
    cluster_network: 172.19.106.0/0
    
    osd_objectstore: bluestore
    
    
    ## Rados Gateway options
    radosgw_frontend_type: beast
    radosgw_frontend_port: 12345
    radosgw_interface: "{{monitor_interface}}"
    radosgw_num_instances: 3
    

    Table 1 describes the parameters.

    Table 1 Parameter description

    Parameter

    Description

    monitor_interface

    Network interface device ID of the public network.

    radosgw_frontend_type

    RGW front-end type. This parameter is optional.

    radosgw_frontend_port

    RGW front-end port. This parameter is optional.

    radosgw_num_instances

    Number of RGW instances on each node. RGW access ports are numbered incrementally based on the port number specified by radosgw_frontend_port.

  • Offline Ceph download mode
    1
    2
    3
    ceph_origin: distro
    ceph_repository: local
    ceph_stable_release: nautilus
    

Setting the Permission of the RGW Service

In the rgws.yml file, set pg_num and size of the default RGW data pool and index pool, and specify whether the RGW service can access private devices.

  • CentOS 7.6
     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    rgw_create_pools:
    defaults.rgw.buckets.data:
    pg_num: 8
    size: ""
    defaults.rgw.buckets.index:
    pg_num: 8
    size: ""
    ###########
    # SYSTEMD #
    ###########
    # ceph_rgw_systemd_overrides will override the systemd settings
    # for the ceph-rgw services.
    # For example,to set "PrivateDevices=false" you can specify:
    ceph_rgw_systemd_overrides:
    Service:
    PrivateDevices: False
    
  • openEuler 20.03
    rgw_create_pools: 
      defaults.rgw.buckets.data: 
          pg_num: 64 
          size: 3 
      defaults.rgw.buckets.index: 
          pg_num: 64
          size: 3 
    ########### 
    # SYSTEMD # 
    ########### 
    # ceph_rgw_systemd_overrides will override the systemd settings 
    # for the ceph-rgw services. 
    # For example,to set "PrivateDevices=false" you can specify: 
    ceph_rgw_systemd_overrides: 
      Service: 
         PrivateDevices: False

Defining OSDs

Define the required OSDs by referring to Defining OSDs.