ceph-01-运维那事

待整理ceph运维笔记

1
2
ceph osd set noout
ceph osd unset noout
1
rbd create wxq --size 1
1
2
3
4
5
6
7
8
(ceph-mon)[root@pike-vm /]# rbd info rbd/wxq
rbd image 'wxq':
size 1024 kB in 1 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.498102ae8944a
format: 2
features: layering, exclusive-lock, object-map, fast-diff, deep-flatten
flags:
1
2
(ceph-mon)[root@pike-vm /]# ceph osd map rbd rbd_data.498102ae8944a
osdmap e183 pool 'rbd' (0) object 'rbd_data.498102ae8944a' -> pg 0.455bea7d (0.3d) -> up ([1], p1) acting ([1], p1)
1
2
3
4
5
6
[root@lab8106 ]#ceph-objectstore-tool  \
--data-path /var/lib/ceph/osd/ceph-1/ \
--journal-path /var/lib/ceph/osd/ceph-1/journal \
--pgid 0.3d \
rbd_data.498102ae8944a
remove
1
2
(ceph-mon)[root@pike-vm /]# ceph pg map 8.7d 
osdmap e183 pg 8.7d (8.7d) -> up [2] acting [2]
1
2
3
4
5
(ceph-mon)[root@pike-vm /]# ceph pg 8.7d query
{
"state": "active+clean",
"snap_trimq": "[]",
...
1
2
3
4
ceph  pg dump
ceph osd dump
ceph pg map 8.7d
ceph pg 8.7d list_missing
1
2
ceph pg 4.438 mark_unfound_lost revert
ceph pg 4.438 mark_unfound_lost delete
1
2
ceph pg repair 0.44
ceph osd pool set rbd min_size 1