kpatch how to
Contents
- git clone kpatch repo from
https://github.com/dynup/kpatch.git
- config kernel src repo since we need src.rpm package
- install dependence package
for kpatch
yum install -y gcc kernel-devel elfutils elfutils-devel
for kpatch-build
|
|
- generate a patch exactly the same kernel with the one we will build. Kpatch could not adjust the patch even for a single line. So use 123.el7 to generate a patch if you want to build a module in 123.el7
- switch to kpatch folder and run
make; make install
- kpatch-build your.patch
- kpatch load kpatch-your.ko
- done
Author Hangbin Liu
LastMod 2018-12-02 (a90227f)