If you need to add a host name: OSD4 ip:192.168.0.110 OSD
1. Create a directory for Mount directories and placement profiles in OSD4
SSH 192.168.0.110 (this is from Mon host ssh to OSD4 host)
Mkdir/ceph/osd.4
Mkdir/etc/ceph
2. On OSD4, format the EXT4 Sda3 partition, mount the partition.
Mkfs.ext4/dev/sda3
Mount-o User_xattr/dev/sda3/ceph/osd.4
3. The id_dsa.pub of the Mon host is copied to the OSD4 host for password-free access
Scp/root/.ssh/id_dsa.pub 192.168.0.110:/root/.ssh/id_dsa.pub102
SSH 192.168.0.110
Cd/root/.ssh
Cat id_dsa.pub102 > Authorized_keys
4. Modify the ceph.conf configuration file on the Mon host
Vi/etc/ceph/ceph.conf
[Osd.4]
Host = Osd4
Deves =/dev/sda3
5. Copy the modified ceph.conf file to each MDS and OSD node and copy one to/usrlocal/etc/ceph/
Scp/etc/ceph/ceph.conf 192.168.0.110:/etc/ceph/(Just write this one here, don't forget to sync the other node's profile)
6. Create an OSD
Ceph OSD Create Osd.4
7. Loading the OSD Data directory
SSH 192.168.0.110
Ceph-osd-i Osd.4--mkfs--mkkey
After updating Crushmap, the new OSD will be able to store the data.
8. Create a crushmap that is currently in use
Ceph OSD Getcrushmap-o Map (map is a custom name, you need to use this name below)
9. Post-compilation export Crushmap
crushtool-d Map-o/root/map.txt (map.txt is the file name of the export)
10. Modify Map.txt
Ceph adds OSD flow