OpenStack - Upgrade Ceph Mimic ke Nautilus

Kita bisa mengupgrade daemon di dalam Ceph cluster sementara cluster dalam keadaaan online. Ada beberapa tipe upgrade berdasarkan urutan dependensi. Untuk urutan upgrade direkomendasikan seperti berikut:

1. Ceph Deploy
2. Ceph Monitors
3. Ceph OSD Daemons
4. Ceph Metadata Servers
5. Ceph Object Gateways

Ceph Deploy

sebelum upgrade ceph daemons, upgrade tool ceph-deploy

# yum install ceph-deploy

Prosedur Upgrade

Upgrade Monitors

Untuk mengupgrade monitors, lakukan langkah berikut:

Upgrade paket Ceph untuk setiap daemon atau bisa semua sekaligus:

[stack@ceph1 ~]$ ceph-deploy install --release nautilus ceph-mon

Update juga untuk binary ceph:

[stack@ceph1 ~]$ sudo yum update && sudo yum install ceph

restart ceph mon services

[stack@ceph1 ~]$  systemctl restart ceph-mon@ceph1

image

cek monitor ceph:

[stack@ceph1 ~]$  ceph mon stat

Upgrade OSD

Untuk mengupgrade osd daemon, lakukan langkah berikut:

Gunakan tool ceph-deploy untuk upgrade semua node OSD daemon:

[stack@ceph1 ~]$ ceph-deploy install --release nautilus osd0 osd1

image

Update juga untuk binary ceph:

[stack@ceph1 ~]$ ssh osd0
[stack@osd0 ~]$ sudo yum update && sudo yum install ceph
[stack@ceph1 ~]$ ssh osd1
[stack@osd1 ~]$ sudo yum update && sudo yum install ceph

restart OSD:

systemctl restart ceph-osd@1
systemctl restart ceph-osd@2
systemctl restart ceph-osd@3

[stack@ceph1 ~]$ systemctl status ceph-osd@1
� ceph-osd@1.service - Ceph object storage daemon osd.1
   Loaded: loaded (/usr/lib/systemd/system/ceph-osd@.service; enabled-runtime; vendor preset: disabled)
   Active: active (running) since Tue 2019-08-06 15:39:40 WIB; 24h ago
  Process: 12624 ExecStartPre=/usr/lib/ceph/ceph-osd-prestart.sh --cluster ${CLUSTER} --id %i (code=exited, status=0/SUCCESS)
 Main PID: 12629 (ceph-osd)
   CGroup: /system.slice/system-ceph\x2dosd.slice/ceph-osd@1.service
           ��12629 /usr/bin/ceph-osd -f --cluster ceph --id 1 --setuser ceph --setgroup ceph
[stack@ceph1 ~]$

Upgrade Metadata Server

jalankan:

[stack@ceph1 ~]$ ceph-deploy install --release nautilus mds0
[stack@ceph1 ~]$ sudo yum update && sudo yum install ceph-mds
[stack@ceph1 ~]$ systemctl restart ceph-mgr@ceph1

jika metadata server diinstall satu server dengan ceph-mon. maka langkah ini tidak diperlukan lagi.

sampai dengan disini ceph server seharusnya sudah menjadi versi nautilus. cek dengan command ceph -s untuk melihat status cluster.

Troubleshoot:

Monitor not have enabled msgr2

Error Log:

Monitor not have enabled msgr2

image

Jalankan:

ceph mon enable-msgr2

lalu cek lagi ceph -s

image

Legacy BlueStore stats reporting detected

Error Log:

image

How to solve:

repair OSD satu per satu:

Contoh:

sudo ceph-bluestore-tool repair --path /var/lib/ceph/osd/ceph-1/
sudo ceph-bluestore-tool repair --path /var/lib/ceph/osd/ceph-2/
sudo ceph-bluestore-tool repair --path /var/lib/ceph/osd/ceph-3/

image

image

solved:

image

Summary Code

!/bin/bash

ceph-deploy install --release nautilus ceph-mon
sudo yum update -y && sudo yum install ceph -y
sudo systemctl restart ceph-mon@ceph1

#osd upgrade
ceph-deploy install --release nautilus osd0 osd1


ssh osd0 "sudo yum update -y && sudo yum install ceph -y"
ssh osd1 "sudo yum update -y && sudo yum install ceph -y"


ceph-deploy install --release nautilus mds0
sudo yum update -y && sudo yum install ceph-mds -y

systemctl restart ceph-mgr@ceph1
ceph --version
ssh osd0 "ceph --version"
ssh osd1 "ceph --version"

Ref:

  1. Ceph Docs