Ceph 的监控可视化界面方案不少----grafana、Kraken。可是从Luminous开始,Ceph 提供了原生的Dashboard功能,经过Dashboard能够获取Ceph集群的各类基本状态信息。shell
注:Mimic 13.2.1还不支持非ssl的http访问,而最新Master版本里已经有非ssl的支持tcp
查看集群状态,并确认mgr的active状态节点ide
[cephuser@cephmanager01 ~]$ sudo ceph -s cluster: id: 6a71324c-6949-42bc-92ca-325c9d45ae06 health: HEALTH_OK services: mon: 3 daemons, quorum cephmanager01,cephmanager02,cephmanager03 mgr: cephmanager03_mgr(active), standbys: cephmanager01_mgr, cephmanager02_mgr osd: 12 osds: 12 up, 12 in data: pools: 0 pools, 0 pgs objects: 0 objects, 0 B usage: 12 GiB used, 588 GiB / 600 GiB avail pgs:
mgr的active节点为:cephmanager033d
默认dashboard服务在可开启列表中,但并未启动,须要手工开启code
[在manager节点执行,以cephmanager03为例]server
# 可查看mgr默认开启的服务:(sudo) ceph mgr module ls [cephuser@cephmanager03 ~]$ sudo ceph mgr module ls [cephuser@cephmanager03 ~]$ sudo ceph mgr module enable dashboard
1) 生成并安装一个 自签名证书blog
[cephuser@cephmanager03 ~]$ sudo ceph dashboard create-self-signed-cert
2)配置服务地址、端口,默认的端口是7000ssl
# 这里的IP须要是mgr为active的IP地址 [cephuser@cephmanager03 ~]$ sudo ceph config-key put mgr/dashboard/server_addr 192.168.10.75 [cephuser@cephmanager03 ~]$ sudo ceph config-key put mgr/dashboard/server_port 7000
3)禁用和启用Bashboradget
[cephuser@cephmanager03 ~]$ sudo ceph mgr module disable dashboard [cephuser@cephmanager03 ~]$ sudo ceph mgr module enable dashboard
4)查看服务访问方式
# Dashboard服务已开启,默认监听所有地址的tcp7000端口; [cephuser@cephmanager03 ~]$ sudo netstat -tunlp |grep mgr [cephuser@cephmanager03 ~]$ sudo ceph mgr services # 确认配置状况 [cephuser@cephmanager03 ~]$ sudo ceph config dump
5)建立Dashboard用户名和密码
[cephuser@cephmanager03 ~]$ sudo ceph dashboard set-login-credentials admin admin
web登陆:https://192.168.10.75:7000
登陆查看状态信息
集群hosts信息等