1、卸载掉除3.10.0-514.el7.x86_64版本外的所有头文件、开发包
yum remove kernel-headers-(版本号) yum remove kernel-devel-(版本号)
2、安装3.10.0-514.el7.x86_64版本的内核镜像
yum install kernel-3.10.0-514.el7.x86_64
也可以采用rpm安装本地*.rpm包:
rpm -ivh kernel-3.10.0-514.el7.x86_64.rpm
3.10.0-514.el7.x86_64版本的系统,安装内核头文件、开发包
先删除不用的内核:
yum remove kernel-(不用的版本号)
yum install kernel-headers-$(uname -r) kernel-devel-$(uname -r)
也可以采用rpm安装本地*.rpm包:
rpm -ivh kernel-headers-3.10.0-514.el7.x86_64.rpm rpm -ivh kernel-devel-3.10.0-514.el7.x86_64.rpm
rpm -q epel-release
rpmkeys --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
在[epel]最后添加一条属性 priority=11
意思是yum先去官方源查,官方没有再去epel的源找
yum makecache
也可以采用rpm安装本地*.rpm包:
rpm -ivh zfs-release.el7_3.noarch.rpm
rpmkeys --import /etc/pki/rpm-gpg/RPM-GPG-KEY-zfsonlinux
gpg --quiet --with-fingerprint /etc/pki/rpm-gpg/RPM-GPG-KEY-zfsonlinux
yum makecache
yum install zfs
也可以采用rpm安装本地*.rpm包:
rpm -ivh zfs-0.6.5.9-1.el7_3.centos.x86_64.rpm rpm -ivh kmod-zfs-0.6.5.9-1.el7_3.centos.x86_64.rpm rpm -ivh libzfs2-0.6.5.9-1.el7_3.centos.x86_64.rpm
modprobe zfs
systemctl preset zfs-import-cache zfs-import-scan zfs-mount zfs-share zfs-zed zfs.target
安装包下载:
http://down.51cto.com/data/2296227
http://down.51cto.com/data/2296228
本文出自 “十年一剑必成器” 博客,请务必保留此出处http://laoheaifendou.blog.51cto.com/3072239/1911152
原文地址:http://laoheaifendou.blog.51cto.com/3072239/1911152