Commit Graph

498 Commits

Author SHA1 Message Date
Xunlei Pang e067d77dfc mkdumprd: apply dracut "--hostonly-cmdline" and "--no-hostonly-default-device"
Dracut has "--hostonly-cmdline" which can generate cmdlines(if any)
regarding the dump target, it's an existing way for us to use to
simplify the code. E.g. We already removed generate_lvm_cmdlines(),
to use "--hostonly-cmdline".

But "--hostonly-cmdline" has other issues(e.g. BZ1451717), it adds
needless devices for kdump like root device.

Now dracut supports "--no-hostonly-default-device" which enables
us to only add the kdump target, which can avoid needless devices
being recognized under kdump. Thus "--hostonly-cmdline" side effects
can be avoided with the help of "--no-hostonly-default-device".

This patch applies dracut's "--hostonly-cmdline" together with
"--no-hostonly-default-device" to achieve above-mentioned purpose.

Signed-off-by: Xunlei Pang <xlpang@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2017-09-06 15:40:04 +08:00
Dave Young c8ab07e72b Release 2.0.15-12
btw, fixed the bogus date in rpm spec changelog
2017-08-17 16:58:06 +08:00
Dave Young 4384995b3d makedumpfile: fix 4.13 kernel larget vmcore bug
Added patch from panand which was accepted by upstream but not merged in upstream yet.
kexec-tools-2.0.15-makedumpfile-fix-SECTION_MAP_MASK-for-kernel-bigger-than-4.13.patch
2017-08-17 16:50:23 +08:00
Dave Young 238f7d836c Release 2.0.15-11
[From ville.skytta@iki.fi]
- Own the /usr/share/makedumpfile dir
- Mark COPYING as %%license
2017-08-15 09:50:35 +08:00
Dave Young 0ffa712fab Release 2.0.15-10 2017-08-08 10:10:50 +08:00
Dave Young 00ceca7f99 Release 2.0.15-9
https://bugzilla.redhat.com/show_bug.cgi?id=1474706

Makedumpfile failed with below error messages, which is caused by kernel changes 65ade2f872b474fa8a04c2d397783350326634e6:

Buffer size for the cyclic mode: 95992
vtop4_x86_64: Can't get the symbol of init_level4_pgt.
readmem: Can't convert a virtual address(ffffffff8fe18284) to physical address.
readmem: type_addr: 0, addr:ffffffff8fe18284, size:390
check_release: Can't get the address of system_utsname.

Pull in Pratyush's fix in upstream makedumpfile (not merged yet but acked by
maintainer)

Signed-off-by: Dave Young <dyoung@redhat.com>
2017-08-07 09:44:42 +08:00
Fedora Release Engineering 1ad0c239a5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild 2017-08-03 00:20:54 +00:00
Florian Weimer 610f08562d Rebuild with fixed binutils for ppc64le (#1475636) 2017-07-30 18:12:58 +02:00
Dave Young d968a68263 Release 2.0.15-6
Update makedumpfile to upstream 1.6.2

Signed-off-by: Dave Young <dyoung@redhat.com>
2017-07-28 14:42:15 +08:00
Fedora Release Engineering ee882b26b7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild 2017-07-26 15:08:54 +00:00
Dave Young 06b35b224d Release 2.0.15-4 2017-07-19 09:56:07 +08:00
Dave Young 06c776f36b Release 2.0.15-3 2017-07-14 16:07:11 +08:00
Dave Young 151e0b5345 Release 2.0.15-2 2017-06-28 14:36:01 +08:00
Pratyush Anand 7845cdd89c aarch64: Add makedumpfile executable
Add makedumpfile executable for aarch64 as well.

Signed-off-by: Pratyush Anand <panand@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2017-06-28 14:35:42 +08:00
Dave Young ff28c8fe08 Release kexec-tools 2.0.15-1 2017-06-23 11:33:25 +08:00
Dave Young d6dfe2cc1e Release 2.0.14-13 2017-06-15 09:43:11 +08:00
Bhupesh Sharma f513f035f3 kexec-tools.spec: Fix whitespace errors
This patch fixes the whitespace errors reported by
'rpmlint' or 'fedpkg lint' when they are run on kexec-tools srpm:

kexec-tools.spec:242: W: mixed-use-of-spaces-and-tabs (spaces: line 107,
tab: line 242)

Signed-off-by: Bhupesh Sharma <bhsharma@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2017-06-15 09:41:33 +08:00
Dave Young 70a9f58336 Release 2.0.14-12 2017-05-18 16:50:48 +08:00
Dave Young b74479521c Release 2.0.14-11 2017-05-12 11:00:23 +08:00
Dave Young c3ab408727 Release 2.0.14-10
Speedup kdump service startup
2017-05-05 16:16:25 +08:00
Dave Young 841ea5be0b Release 2.0.14-9 2017-04-27 14:01:45 +08:00
Dave Young 414b2a7dbb Release 2.0.14-8 2017-04-11 16:33:38 +08:00
Dave Young 961bda9152 Release 2.0.14-7 2017-03-31 11:57:36 +08:00
Xunlei Pang 5c87d73cf3 kdump-emergency: fix "Transaction is destructive" emergency failure
We met a problem that the kdump emergency service failed to
start when the target dump timeout(we passed "rd.timeout=30"
to kdump), it reported "Transaction is destructive" messages:

  [ TIME ] Timed out waiting for device dev-mapper-fedora\x2droot.device.
  [DEPEND] Dependency failed for Initrd Root Device.
  [ SKIP ] Ordering cycle found, skipping System Initialization
  [DEPEND] Dependency failed for /sysroot.
  [DEPEND] Dependency failed for Initrd Root File System.
  [DEPEND] Dependency failed for Reload Configuration from the Real Root.
  [ SKIP ] Ordering cycle found, skipping System Initialization
  [ SKIP ] Ordering cycle found, skipping Initrd Default Target
  [DEPEND] Dependency failed for File System Check on /dev/mapper/fedora-root.
  [  OK  ] Reached target Initrd File Systems.
  [  OK  ] Stopped dracut pre-udev hook.
  [  OK  ] Stopped dracut cmdline hook.
           Starting Setup Virtual Console...
           Starting Kdump Emergency...
  [  OK  ] Reached target Initrd Default Target.
  [  OK  ] Stopped dracut initqueue hook.
  Failed to start kdump-error-handler.service: Transaction is destructive.
  See system logs and 'systemctl status kdump-error-handler.service' for details.
  [FAILED] Failed to start Kdump Emergency.
  See 'systemctl status emergency.service' for details.
  [DEPEND] Dependency failed for Emergency Mode.

This is because in case of root failure, initrd-root-fs.target
will trigger systemd emergency target which requires the systemd
emergency service actually is kdump-emergency.service, then our
kdump-emergency.service starts kdump-error-handler.service with
"systemctl isolate"(see 99kdumpbase/kdump-emergency.service, we
replace systemd's with this one under kdump).

This will lead to systemd two contradictable jobs queued as an
atomic transaction:
job 1) the emergency service gets started by initrd-root-fs.target
job 2) the emergency service gets stopped due to "systemctl isolate"
thereby throwing "Transaction is destructive".

In order to solve it, we can utilize "IgnoreOnIsolate=yes" for both
kdump-emergency.service and kdump-emergency.target. Unit with attribute
"IgnoreOnIsolate=yes" won't be stopped when isolating another unit,
they can keep going as expected in case be triggered by any failure.

We add kdump-emergency.target dedicated to kdump the similar way
as did for kdump-emergency.service(i.e. will replace systemd's
emergency.target with kdump-emergency.target under kdump), and
adds "IgnoreOnIsolate=yes" into both of them.

Signed-off-by: Xunlei Pang <xlpang@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
Acked-by: Pratyush Anand <panand@redhat.com>
[bhe: improve the patch log about IgnoreOnIsolate="]
2017-03-31 11:54:30 +08:00
Dave Young 00ed76e7e2 Release 2.0.14-6 2017-03-17 10:21:49 +08:00
Pratyush Anand 86a81de3e5 Fix `makedumpfile --mem-usage /proc/kcore`
Patches have been taken from kexec-tools and makedumpfile to fix issue
with `makedumpfile --mem-usage /proc/kcore`.

Two of the patches is from kexec-tools and rest are from makedumpfile.
All the patches have been acked upstream and applies without conflict.

Kexec-tools patches:
(kexec-tools-2.0.14-x86-x86_64-Fix-format-warning-with-die.patch), which
fixes koji build issue.

kexec-tools-2.0.14-build_mem_phdrs-check-if-p_paddr-is-invalid.patch fixes
the regresssion caused by kernel /proc/kcore fix to use -1 as default value
of p_paddr for pt_loads. Without his patch kexec -p will fail with latest
kernel.

Other makedumpfile patches are backported to support --mem-usage while
kernel kaslr being enabled. Details please see the patch log of the individual
patches.

All the patches are backport of upstream commits.

Patches has been tested with kernel 4.11.0-0.rc1.git0.1.fc26.x86_64.

    # makedumpfile --mem-usage /proc/kcore -f
    The kernel version is not supported.
    The makedumpfile operation may be incomplete.

    TYPE            PAGES                   EXCLUDABLE      DESCRIPTION
    ----------------------------------------------------------------------
    ZERO            1960                    yes             Pages filled
    with zero
    NON_PRI_CACHE   22850                   yes             Cache pages
    without private flag
    PRI_CACHE       1517                    yes             Cache pages with
    private flag
    USER            32522                   yes             User process
    pages
    FREE            1898981                 yes             Free pages
    KERN_DATA       78721                   no              Dumpable kernel
    data

    page size:              4096
    Total pages on system:  2036551
    Total size on system:   8341712896       Byte

We won't need to pass -f once fedora kernel is rebased with v4.12.

Signed-off-by: Pratyush Anand <panand@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2017-03-17 10:14:17 +08:00
Dave Young bbe10baeb2 Release 2.0.14-5 2017-03-09 16:59:31 +08:00
Dave Young 00bd88cd58 Release 2.0.14-4 2017-01-23 16:00:59 +08:00
Tong Li 1c27a3d827 drop kdump script rhcrashkernel-param in kexec-tools repo
Resolves: bz1399436

Since currently crashkernel= will be handled in kdump anaconda addon
we can safely remove rhcrashkernel-param callback.

Signed-off-by: Tong Li <tonli@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2017-01-23 15:59:47 +08:00
Dave Young 769e1d53c6 Release 2.0.14-3 2017-01-04 15:00:49 +08:00
Dave Young bd8a109b91 Rebase makedumpfile 1.6.1
Rebase makedumpfile to 1.6.1 and drop the upstreamed patches

Signed-off-by: Dave Young <dyoung@redhat.com>
2017-01-04 14:58:56 +08:00
Dave Young abfed0b6d6 Release 2.0.14-2
Fix build error, forgot to update anaconda addon file in rpm spec.
Update changelog etc.
2016-12-20 17:45:45 +08:00
Dave Young 6cd80235c6 Update addon tarball in rpm spec
Previously forgot to update addon file name in rpm spec..
Signed-off-by: Dave Young <dyoung@redhat.com>
2016-12-20 17:43:09 +08:00
Dave Young 986a4999d4 Release 2.0.14-1
Rebase kexec-tools to upstream 2.0.14

Signed-off-by: Dave Young <dyoung@redhat.com>
2016-12-20 17:09:40 +08:00
Dave Young 8cfb265790 Release 2.0.13-9 2016-11-28 10:43:20 +08:00
Dave Young 4137ad43c3 Release 2.0.13-8 2016-11-11 14:15:42 +08:00
Dave Young 9a1312a624 kexec/arch/i386: Add support for KASLR memory randomization
Backport upstream kexec-tools commit for correct kaslr page_offset value
commit 9f62cbddddfc93d78d9aafbddf3e1208cb242f7b
Author: Thomas Garnier <thgarnie@google.com>
Date:   Tue Sep 13 15:10:05 2016 +0800

    kexec/arch/i386: Add support for KASLR memory randomization

    Multiple changes were made on KASLR (right now in linux-next). One of
    them is randomizing the virtual address of the physical mapping, vmalloc
    and vmemmap memory sections. It breaks kdump ability to read physical
    memory.

    This change identifies if KASLR memories randomization is used by
    checking if the page_offset_base variable exists. It search for the
    correct PAGE_OFFSET value by looking at the loaded memory section and
    find the lowest aligned on PUD (the randomization level).

    Related commits on linux-next:
     - 0483e1fa6e09d4948272680f691dccb1edb9677f: Base for randomization
     - 021182e52fe01c1f7b126f97fd6ba048dc4234fd: Enable for PAGE_OFFSET

    Signed-off-by: Thomas Garnier <thgarnie@google.com>
    Signed-off-by: Simon Horman <horms@verge.net.au>

Signed-off-by: Dave Young <dyoung@redhat.com>
Acked-by: Baoquan He <bhe@redhat.com>
2016-11-11 14:14:59 +08:00
Dave Young 50c70debae Update kdump anaconda addon
*) Add support for new Anaconda addon methods (#1288636)
*) update latin translation (#1053550)

Signed-off-by: Dave Young <dyoung@redhat.com>
2016-11-11 11:03:59 +08:00
Tong Li 7e53e9fe38 Documentation: step by step guide on confiuring kdump in live images
This is a short document about how to setup kdump on live images. All
steps were tested on Fedora 25 Alpha LiveCD and saved vmcore captured
by kdump to a USB stick successfully.

Signed-off-by: Tong Li <tonli@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2016-11-11 10:56:11 +08:00
Dave Young 11785bdffb Release 2.0.13-7 2016-10-27 14:52:32 +08:00
Pratyush Anand 938280a5e9 x86_64: fix page_offset calculation
V1 of the KASLR patch which was backported in 2.0.13-6 had wrong
calculation for page_offset. This patch takes the correct difference.

Signed-off-by: Pratyush Anand <panand@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2016-10-27 14:52:15 +08:00
Dave Young f77aa85025 Release 2.0.13-6 2016-10-27 14:44:27 +08:00
Pingfan Liu aee378209e Add initial upstream support for kexec on aarch64
Fix Bug 925630 - kexec-tools: support for arm64
https://bugzilla.redhat.com/show_bug.cgi?id=925630
involves three things:
  1. back porting upstream code to enable the function of kexec-tools on arm64
     patchset backported from upstream:
        commit abdfe97736f89d9bc73662b9134604b0229a599e
        commit 522df5f7217fda01ece3f6ac3e9987b0320c2bb0
        commit 217bcc00c9309416a6c6cd0584196559d28a9259
  2. fix the arm related building issue by using autoreconf in spec file

  3. patches to fix the issue of higher version gcc used by koji (not upstrem yet,
     and the corresponding fix in kernel side is in other package)
        kexec-tools-2.0.13-arm64-Add-support-for-additional-relocations-in-the-kexec-purgatory-code.patch
        kexec-tools-2.0.13-arm64-Add-support-of-R_AARCH64_PREL32-relocation-in-.patch
[panand: apply patches in 3 of above paragraph]

Signed-off-by: Pingfan Liu <piliu@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
Acked-by: Pratyush Anand <panand@redhat.com>
2016-10-27 14:44:13 +08:00
Dave Young 658db69940 Support kdump for kaslr enabled Fedora kernel
Since in Fedora 25 kernel kaslr is enabled (x86) but makedumpfile can not save
a correct vmcore, so it means kdump default setup will not work.

Pratyush posted a patch series to upstream which can fix the issue. Let's merge them in F25, will get the normal fixes after it being merged in upstream, we hopefully can rebase soon in rawhide.

This is an urgent fix for F25 since F25 freeze is this week.

Signed-off-by: Dave Young <dyoung@redhat.com>
Acked-by: Pratyush Anand <panand@redhat.com>
Acked-by: Baoquan He <bhe@redhat.com>
2016-10-27 14:44:02 +08:00
Dave Young f583213ea4 Release 2.0.13-5 2016-09-16 15:43:52 +08:00
Dave Young fdd79a70f6 Release 2.0.13-4 2016-08-26 14:05:37 +08:00
Xunlei Pang d614274092 spec: Update to add dependency on dracut version >= 044-117
Fedora dracut-network version >= 044-117 must be installed to work with
this set of kexec-tools patches. Therefore adding dependency for them.

Acked-by: Dave Young <dyoung@redhat.com>
Signed-off-by: Xunlei Pang <xlpang@redhat.com>
2016-08-26 14:03:48 +08:00
Dave Young 8e669fa5dd Release 2.0.13-3 2016-08-09 15:42:46 +08:00
Dave Young 97581f1a43 Fix armv7 build failure
Upstream kexec-tools 2.0.13 tarball does not pack arm phys_to_virt.h and
iomem.h, add them to avoid armv7 build failure.
2016-08-09 15:42:39 +08:00
Dave Young 3638e9e3a5 Release 2.0.13-2 2016-08-09 14:34:10 +08:00