CentOS 7.0 installs Ceph(jewel) and above

background

Because rexray, the Ceph plug-in of docker, has certain requirements for Ceph version, when Ceph version is hammer (0.94.10), rexray cannot create rbd device successfully. For CentOS 7 and above, hammer is installed by default, so we need to install a higher version of jewel. Ceph version available See also.

install

For installation speed, we can choose domestic source. Domestic sources commonly used include:
  

Add source

Add a Ceph source to yum (take Netease source as an example).

$ tee /etc/yum.repos.d/ceph.repo <<-'EOF'
[Ceph]
name=Ceph packages for $basearch
baseurl=http://mirrors.163.com/ceph/rpm-jewel/el7/$basearch
enabled=1
gpgcheck=0
type=rpm-md
gpgkey=https://mirrors.163.com/ceph/keys/release.asc
priority=1

[Ceph-noarch]
name=Ceph noarch packages
baseurl=http://mirrors.163.com/ceph/rpm-jewel/el7/noarch
enabled=1
gpgcheck=0
type=rpm-md
gpgkey=https://mirrors.163.com/ceph/keys/release.asc
priority=1

[ceph-source]
name=Ceph source packages
baseurl=http://mirrors.163.com/ceph/rpm-jewel/el7/SRPMS
enabled=1
gpgcheck=0
type=rpm-md
gpgkey=https://mirrors.163.com/ceph/keys/release.asc
priority=1
EOF

Installation dependency

$ yum install -y yum-utils && yum-config-manager --add-repo https://dl.fedoraproject.org/pub/epel/7/x86_64/ && yum install --nogpgcheck -y epel-release && rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7 && rm -f /etc/yum.repos.d/dl.fedoraproject.org*

This step is very important. If you skip this step and install ceph directly, the following error will be reported:

Error: Package: 1:ceph-common-10.2.10-0.el7.x86_64 (Ceph)
           Requires: libbabeltrace.so.1()(64bit)
Error: Package: 1:librados2-10.2.10-0.el7.x86_64 (Ceph)
           Requires: liblttng-ust.so.0()(64bit)
Error: Package: 1:librgw2-10.2.10-0.el7.x86_64 (Ceph)
           Requires: libfcgi.so.0()(64bit)
Error: Package: 1:librbd1-10.2.10-0.el7.x86_64 (Ceph)
           Requires: liblttng-ust.so.0()(64bit)
Error: Package: 1:ceph-common-10.2.10-0.el7.x86_64 (Ceph)
           Requires: libbabeltrace-ctf.so.1()(64bit)

Install Ceph

The last step is to install Ceph. Here, take the installation of Ceph common as an example:

$ yum -y install ceph-common

Verify Ceph

$ ceph --version
ceph version 10.2.10 (5dc1e4c05cb68dbf62ae6fce3f0700e4654fdbbe)

The above indicates a successful installation.

Keywords: Ceph RPM yum EPEL

Added by fiorelina21 on Thu, 30 Apr 2020 09:15:09 +0300