Ceph: Rados Gateway ウェブエンドポイントが応答しない

Ceph: Rados Gateway ウェブエンドポイントが応答しない

シンプルな Ceph クラスターを作成し、Ceph Gateway に接続しようとしています。

これは私の Ceph クラスターの ceph ステータス出力です:

  cluster:
    id:     a7f64266-0894-4f1e-a635-d0aeaca0e993
    health: HEALTH_WARN
            mon is allowing insecure global_id reclaim
            1 monitors have not enabled msgr2
            5 pool(s) have no replicas configured

  services:
    mon: 1 daemons, quorum rhcsa (age 4h)
    mgr: rhcsa(active, since 8s)
    osd: 1 osds: 1 up (since 4h), 1 in (since 4h)

  data:
    pools:   5 pools, 129 pgs
    objects: 27 objects, 453 KiB
    usage:   22 MiB used, 20 GiB / 20 GiB avail
    pgs:     129 active+clean

これは /etc/ceph/ceph.conf の下にある Ceph 設定です。

[global]
fsid = a7f64266-0894-4f1e-a635-d0aeaca0e993
mon_initial_members = rhcsa
mon_host = 192.168.122.61
public_network = 192.168.122.0/24
auth_cluster_required = cephx
auth_service_required = cephx
auth_client_required = cephx
osd_pool_default_size = 1
osd_pool_default_min_size = 1
osd_pool_default_pg_num = 333
osd_crush_chooseleaf_type = 1


[client.rgw.rhcsa]
host = rhcsa
rgw dns name = rhcsa
log file = /var/log/ceph/client.rgw.rhcsa.log
keyring = /var/lib/ceph/radosgw/ceph-rgw.rhcsa/keyring
rgw frontends = "beast port=8080"

rgw 用に次のディレクトリを作成しました: /var/lib/ceph/radosgw/ceph-rgw.rhcsa

次にキーリング:

sudo ceph-authtool --create-keyring /var/lib/ceph/radosgw/ceph-rgw.rhcsa/keyring
sudo chmod +r /var/lib/ceph/radosgw/ceph-rgw.rhcsa/keyring
sudo ceph-authtool /var/lib/ceph/radosgw/ceph-rgw.rhcsa/keyring -n client.rgw.rhcsa --gen-key   
sudo ceph-authtool -n client.rgw.rhcsa --cap osd 'allow rwx' --cap mon 'allow rwx' /var/lib/ceph/radosgw/ceph-rgw.rhcsa/keyring

次に、Ceph の RadosGW サービスを開始します。

sudo systemctl restart [email protected]

RadosGW サービスは正常に動作しているようです:

[root@rhcsa ~]# systemctl status [email protected][email protected] - Ceph rados gateway
     Loaded: loaded (/usr/lib/systemd/system/[email protected]; disabled; preset: disabled)
     Active: active (running) 
   Main PID: 18501 (radosgw)
      Tasks: 9
     Memory: 6.5M
        CPU: 39ms
     CGroup: /system.slice/system-ceph\x2dradosgw.slice/[email protected]
             └─18501 /usr/bin/radosgw -f --cluster ceph --name client.rgw --setuser ceph --setgroup ceph

rhcsa systemd[1]: Started Ceph rados gateway.

しかし、8080 から応答を取得しようとすると、何も返されません。

[root@rhcsa ~]# curl http://localhost:8080
curl: (7) Failed to connect to localhost port 8080: Connection refused

私は Rocky Linux 9.2 と Ceph バージョン 17.2.6 quincy/stable を使用しています。

答え1

ceph-mgr デーモンを再作成して再度アクティブ化することで問題が解決し、RadosGW エンドポイントから応答を取得できるようになりました。

関連情報