Client PKGs
RHEL从7.1版本(包含7.1)将libceph.ko、ceph.ko、rbd.ko纳入到kernel中,所以如果选择7.1之前的版本需要自己编译相关ko文件
Cluster PKGs
步骤:
更换yum
- 卸载RHEL yum包
1 2
| rpm -qa | grep yum | xargs -e --nodeps rpm -qa | grep python-iniparse | xargs -e --nodeps
|
- 安装CentOS yum包
下载yum包1 2 3 4
| wget http://mirrors.163.com/centos/7.2.1511/os/x86_64/Packages/yum-3.4.3-132.el7.centos.0.1.noarch.rpm wget http://mirrors.163.com/centos/7.2.1511/os/x86_64/Packages/python-iniparse-0.4-9.el7.noarch.rpm wget http://mirrors.163.com/centos/7.2.1511/os/x86_64/Packages/yum-metadata-parser-1.1.4-10.el7.x86_64.rpm wget http://mirrors.163.com/centos/7.2.1511/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.31-34.el7.noarch.rpm
|
安装yum包
修改repo
在“/etc/yum.repo.d/”目录下,增加文件rhel7.repo,内容如下。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
| [base] name=CentOS-$releasever - Base baseurl=http://mirrors.163.com/centos/7.2.1511/os/$basearch/ gpgcheck=1 gpgkey=http://mirrors.163.com/centos/7.2.1511/os/x86_64/RPM-GPG-KEY-CentOS-7
#released updates [updates] name=CentOS-$releasever - Updates baseurl=http://mirrors.163.com/centos/7.2.1511/updates/$basearch/ gpgcheck=1 gpgkey=http://mirrors.163.com/centos/7.2.1511/os/x86_64/RPM-GPG-KEY-CentOS-7
[extras] name=CentOS-$releasever - Extras baseurl=http://mirrors.163.com/centos/7.2.1511/extras//$basearch/ gpgcheck=1 gpgkey=http://mirrors.163.com/centos/7.2.1511/os/x86_64/RPM-GPG-KEY-CentOS-7
[centosplus] name=CentOS-$releasever - Plus baseurl=http://mirrors.163.com/centos/7.2.1511/centosplus//$basearch/ gpgcheck=1 enabled=0k
|
在“/etc/yum.repo.d/”目录下,增加文件ceph.repo,内容如下。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
| [ceph] name=Ceph packages for $basearch baseurl=http://ceph.com/rpm-infernalis/el7/$basearch enabled=1 priority=2 gpgcheck=1 type=rpm-md gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
[ceph-noarch] name=Ceph noarch packages baseurl=http://ceph.com/rpm-infernalis/el7/noarch enabled=1 priority=2 gpgcheck=1 type=rpm-md gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
[ceph-source] name=Ceph source packages baseurl=http://ceph.com/rpm-infernalis/el7/SRPMS enabled=0 priority=2 gpgcheck=1 type=rpm-md gpgkey=https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc
|
使用downloadonly下载安装包
1 2 3
| yum install --downloadonly ceph-common --downloaddir=./ yum install --downloadonly ceph --downloaddir=./ yum install --downloadonly snappy leveldb gdisk python-argparse gperftools-libs --downloaddir=./
|
详细见《yum和rpm使用方法》
安装已下载的rpm包
进入rpm包所在目录
参考&鸣谢