Install Package and Cephadm
rpm-18.2.0은 원하는 ceph version으로 변경
--release reef는 원하는 ceph version으로 변경
dnf search release-ceph
dnf install --assumeyes centos-release-ceph-reef
dnf install --assumeyes cephadm
curl --silent --remote-name --location https://download.ceph.com/rpm-18.2.0/el8/noarch/cephadm
chmod +x cephadm
./cephadm add-repo --release reef
./cephadm install
Run Cephadm Bootstrap
cephadm bootstrap --mon-ip *<mon-ip>*
cephadm install ceph-common
ssh-copy-id -f -i /etc/ceph/ceph.pub root@{Host IP}
cephadm shell -- ceph config-key get mgr/cephadm/ssh_identity_key > ~/cephadm_private_key
cephadm shell -- ceph cephadm get-ssh-config > config
ssh -F config -i ~/cephadm_private_key root@{Host IP}
Add Ceph Host and Label
ceph orch host add <newhostname> <newhostip>
ceph orch host label add <my_hostname> <my_label>
ceph orch host add <newhostname> <newhostip> --labels _admin
Add Ceph MGR and OSD
ceph orch apply mgr --placement="HOSTNAME1 HOSTNAME2 HOSTNAME3"
ceph orch device ls --refresh
ceph orch apply osd --all-available-devices
Reset Ceph OSD disk
Disk는 "/dev/sdb"라고 가정
이전에 Ceph를 설치한 이력이 있는 Node라면 수행 필요
sgdisk --zap-all /dev/sdb
dd if=/dev/zero of=/dev/sdb bs=1M count=100 oflag=direct,dsync
blkdiscard /dev/sdb
ls /dev/mapper/ceph-* | xargs -I% -- dmsetup remove %
rm -rf /dev/ceph-*
'DevOps > CEPH' 카테고리의 다른 글
[CEPH] Local Disk (root) Full(사용 가능 공간 5%미만) 상태로 인한 Error (0) | 2023.12.05 |
---|---|
[CEPH] Ceph monitoring and integration with Zabbix on Ubuntu 20.04 - woodev.co (0) | 2023.12.05 |