Unnamed repository
Go to file
Kairui Song 9966b0a12e kdump-lib: Fix get_bind_mount_source to support btrfs and fstab
Currently get_bind_mount_source will not work on btrfs, that's because
this function relies on findmnt to detect bind mount.

For a bind mount, findmnt will return different value with "-v" option.

For example, we have /dev/sdc mounted on /mnt/source, and then bind
mount /mnt/source/sub/path to /mnt/bind:

$ findmnt /mnt/bind
  TARGET    SOURCE              FSTYPE OPTIONS
  /mnt/bind /dev/sdc[/sub/path] ext4   rw,relatime,seclabel

$ findmnt -v /mnt/bind
  TARGET    SOURCE   FSTYPE OPTIONS
  /mnt/bind /dev/sdc ext4   rw,relatime,seclabel

But findmnt also return similiar result for btrfs, on a fresh installed
Fedora 33:

$ findmnt /
  TARGET SOURCE           FSTYPE OPTIONS
  /      /dev/sdb7[/root] btrfs  rw,relatime,seclabel,ssd,space_cache,subvolid=256,subvol=/root

$ findmnt -v /
  TARGET SOURCE    FSTYPE OPTIONS
  /      /dev/sdb7 btrfs  rw,relatime,seclabel,ssd,space_cache,subvolid=256,subvol=/root

The [...] indicator will contain the subvol of btrfs as well. And if
it's bind mounted under btrfs, it will contain a mixup of btrfs subvol
and the actuall fsroot.

And also, if the bind mount source device is not mounted on /,
get_bind_mount_source will also not work.

So rewrite the get_bind_mount_source function, make it work in every
cases.

Tested with:
 - Silverblue's bind mount
 - Bind mount with source device mounted not under /
 - Btrfs
 - Bind mount and source device is Btrfs

Signed-off-by: Kairui Song <kasong@redhat.com>
Acked-by: Pingfan Liu <piliu@redhat.com>
2020-11-30 15:26:53 +08:00
tests selftest: Fix several test issue with Fedora 33 2020-11-18 23:57:13 +08:00
.gitignore .gitignore: Update to make it more generic 2016-05-16 10:15:01 +08:00
60-kdump.install Add a kernel install hook to clean up kdump initramfs 2020-08-27 11:22:03 +08:00
98-kexec.rules Make udev reload rules quiet during bootup 2018-12-06 17:44:03 +08:00
98-kexec.rules.ppc64 kexec.rules: create dedicated udev rules for ppc64 2019-05-06 16:22:28 +08:00
README README: Add a README file 2014-04-02 10:45:36 +08:00
dracut-early-kdump-module-setup.sh enable the logger for kdump 2020-10-27 17:33:54 +08:00
dracut-early-kdump.sh Add code comments to help better understanding 2020-11-12 13:59:21 +08:00
dracut-kdump-capture.service dracut-kdump-capture.service: Use OnFailureJobMode instead of deprecated OnFailureIsolate 2019-06-14 09:44:09 +08:00
dracut-kdump-emergency.service kdump-emergency: fix "Transaction is destructive" emergency failure 2017-03-31 11:54:30 +08:00
dracut-kdump-emergency.target kdump-emergency: fix "Transaction is destructive" emergency failure 2017-03-31 11:54:30 +08:00
dracut-kdump-error-handler.service kdump-error-handler.service: Remove ExecStopPost 2019-11-28 17:46:00 +08:00
dracut-kdump-error-handler.sh Add failure_action as alias of default and make default obsolete 2019-01-22 17:57:53 +08:00
dracut-kdump.sh Improve debugging in the kdump kernel 2020-10-27 17:34:07 +08:00
dracut-module-setup.sh Add the rd.kdumploglvl option to control log level in the second kernel 2020-11-13 02:43:49 +08:00
dracut-monitor_dd_progress monitor-dd-progress fix 2013-06-25 16:45:59 +08:00
early-kdump-howto.txt Improves the early-kdump-howto.txt document in several points: 2020-03-12 23:31:34 +08:00
fadump-howto.txt fadump: update fadump-howto.txt with some more troubleshooting help 2020-06-04 11:45:05 +08:00
kdump-dep-generator.sh kdump-dep-generator: Add kdump service dependencies on the fly 2014-04-17 11:27:31 +08:00
kdump-in-cluster-environment.txt Add fence_kdump support for generic clusters 2014-04-03 14:43:06 +08:00
kdump-lib-initramfs.sh Make get_mount_info work with bind mount 2020-11-30 15:26:47 +08:00
kdump-lib.sh kdump-lib: Fix get_bind_mount_source to support btrfs and fstab 2020-11-30 15:26:53 +08:00
kdump-logger.sh Capitalize the configuration name of log level 2020-11-13 02:49:35 +08:00
kdump-udev-throttler Make udev reload rules quiet during bootup 2018-12-06 17:44:03 +08:00
kdump.conf increase makdumpfile default message level to 7 2020-10-27 17:45:32 +08:00
kdump.conf.5 Fix comment about ssh dump target 2020-11-05 01:10:14 +08:00
kdump.service kdump.service: use ConditionKernelCommandLine=crashkernel 2020-10-27 12:22:36 -04:00
kdump.sysconfig Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.aarch64 Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.i386 Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.ppc64 Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.ppc64le Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.s390x Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdump.sysconfig.x86_64 Update the kdump sysconfig 2020-11-13 02:49:56 +08:00
kdumpctl kdump-lib.sh: Use a more generic helper to detect omitted dracut module 2020-11-30 15:25:26 +08:00
kdumpctl.8 Update man page for new kdumpctl command: reload / rebuild 2019-04-05 02:02:58 +08:00
kexec-kdump-howto.txt Doc: improve the usage documentation of the logger 2020-11-13 02:49:56 +08:00
kexec-tools-2.0.20-Remove-duplicated-variable-declarations.patch Fix builing failure on Fedora 32 2020-01-29 14:43:47 +08:00
kexec-tools-2.0.20-eppic-Remove-duplicated-variable-declaration.patch Fix builing failure on Fedora 32 2020-01-29 14:43:47 +08:00
kexec-tools-2.0.20-fix-broken-multiboot2-buliding-for-i386.patch x86: Fix broken multiboot2 buliding for i386 2019-08-02 11:24:03 +08:00
kexec-tools-2.0.20-makedumpfile-Introduce-check-params-option.patch makedumpfile: Introduce --check-params option 2020-03-12 23:32:18 +08:00
kexec-tools-2.0.20-makedumpfile-Remove-duplicated-variable-declarations.patch Fix builing failure on Fedora 32 2020-01-29 14:43:47 +08:00
kexec-tools.spec Release 2.0.20-20 2020-11-19 00:38:23 +08:00
live-image-kdump-howto.txt Revert "kdumpctl: filter 'root' kernel parameter when running in live images" 2017-04-11 16:03:12 +08:00
mkdumprd Move watchdog detect and install code to module-setup.sh 2020-11-12 14:03:40 +08:00
mkdumprd.8 Remove comma which is redundant 2013-02-16 15:19:41 +08:00
sources Update makedumpfile to 1.6.7 2020-01-29 08:47:42 +08:00
zanata-notes.txt Add a notes for zanata process 2012-12-05 01:23:09 -05:00

README

Adding a patch to kexec-tools
=============================
There is a mailing list kexec@lists.fedoraproject.org where all the dicussion
related to fedora kexec-tools happen. All the patches are posted there for
inclusion and committed to kexec-tools after review.

So if you want your patches to be included in fedora kexec-tools package,
post these to kexec@lists.fedoraproject.org.

One can subscribe to list and browse through archives here.

https://admin.fedoraproject.org/mailman/listinfo/kexec