Bug 1300952 - kpatch utility reports the wrong metadata
kpatch utility reports the wrong metadata
Status: CLOSED DUPLICATE of bug 1282508
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: kpatch (Show other bugs)
7.2
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Josh Poimboeuf
Chunyu Hu
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-01-22 03:05 EST by Chunyu Hu
Modified: 2016-06-15 11:20 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-06-15 11:20:37 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Chunyu Hu 2016-01-22 03:05:21 EST
Description of problem:

kpatch version shows the old version value.

Version-Release number of selected component (if applicable):


How reproducible:

[root@ibm-x3655-03 ~]# rpm -q kpatch
kpatch-0.3.1-1.el7_2.noarch
[root@ibm-x3655-03 ~]# kpatch version
0.2.2

And the help info shows about initrd, but seems not using initrd. 

usage: kpatch <command> [<args>]

Valid commands:
   install [-k|--kernel-version=<kernel version>] <module>
      install patch module to the initrd to be loaded at boot
   uninstall [-k|--kernel-version=<kernel version>] <module>
      uninstall patch module from the initrd

[root@ibm-x3655-03 ~]# kpatch unload --all
+ INSTALLDIR=/var/lib/kpatch
++++ type -p /usr/sbin/kpatch
+++ dirname /usr/sbin/kpatch
++ readlink -f /usr/sbin
+ SCRIPTDIR=/usr/sbin
+ VERSION=0.2.2
+ unset MODULE
+ [[ 2 -lt 1 ]]
+ case "$1" in
+ [[ 2 -ne 2 ]]
+ case "$2" in
+ for module in '/sys/kernel/kpatch/patches/*'
+ [[ -e /sys/kernel/kpatch/patches/kpatch_3_10_0_327_3_1_1_1 ]]
++ basename /sys/kernel/kpatch/patches/kpatch_3_10_0_327_3_1_1_1
+ unload_module kpatch_3_10_0_327_3_1_1_1
+ PATCH=kpatch_3_10_0_327_3_1_1_1
+ PATCH=kpatch_3_10_0_327_3_1_1_1
+ ENABLED=/sys/kernel/kpatch/patches/kpatch_3_10_0_327_3_1_1_1/enabled
+ [[ -e /sys/kernel/kpatch/patches/kpatch_3_10_0_327_3_1_1_1/enabled ]]
++ cat /sys/kernel/kpatch/patches/kpatch_3_10_0_327_3_1_1_1/enabled
+ [[ 1 -eq 1 ]]
+ echo 'disabling patch module: kpatch_3_10_0_327_3_1_1_1'
disabling patch module: kpatch_3_10_0_327_3_1_1_1
+ echo 0
+ echo 'unloading patch module: kpatch_3_10_0_327_3_1_1_1'
unloading patch module: kpatch_3_10_0_327_3_1_1_1
+ rmmod kpatch_3_10_0_327_3_1_1_1

Actual results:

kpatch version should show right value
kpatch help info should show the right info about initrd.

Expected results:


Additional info:
Comment 3 Josh Poimboeuf 2016-01-22 11:24:20 EST
Thanks for finding these issues!
Comment 4 Josh Poimboeuf 2016-06-15 11:11:10 EDT
This issue has been fixed with the rebase to kpatch-0.3.2-1.el7 with bug 1282508.
Comment 5 Josh Poimboeuf 2016-06-15 11:20:37 EDT

*** This bug has been marked as a duplicate of bug 1282508 ***

Note You need to log in before you can comment on or make changes to this bug.