天天看點

ceph在centos7上安裝

一、更新:

1、yum update -y

2、yum install docker -y

二、安裝python3:

1、yum -y groupinstall “Development tools”

2、yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-3、devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel libffi-devel

4、wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0a1.tar.xz

5、tar -xvJf Python-3.7.0a1.tar.xz

6、./configure --prefix=/usr/local/bin/python3

7、 make

8、 make install

9、ln -s /usr/local/bin/python3/bin/python3 /usr/bin/python3

10、ln -s /usr/local/bin/python3/bin/pip3 /usr/bin/pip3

三、安裝cephadm:

1、curl --silent --remote-name --location https://github.com/ceph/ceph/raw/pacific/src/cephadm/cephadm

2、chmod +x cephadm

3、./cephadm add-repo --release octopus

4、./cephadm install

四、安裝ceph client:

1、cephadm install ceph-common

五、建立ceph叢集:

1、cephadm bootstrap --mon-ip

六、增加主機到叢集:

1、ssh-copy-id -f -i /etc/ceph/ceph.pub [email protected]

2、ceph orch host add hostX

3、ceph orch host ls

七、增加OSD:

1、ceph orch daemon add osd hostX:/dev/sdX

注意:

The device must have no partitions.

The device must not have any LVM state.

The device must not be mounted.

The device must not contain a file system.

The device must not contain a Ceph BlueStore OSD.

The device must be larger than 5 GB.

安裝完dashboard圖:

ceph在centos7上安裝

繼續閱讀