On 03/29/2017 at 02:29 PM, Dave Young wrote:
On 03/28/17 at 03:48pm, Dave Young wrote:
> On 03/27/17 at 12:07pm, Xunlei Pang wrote:
>> I found this problem when debugging "Transaction is destructive"
>> (see the following patch) issue using nfs, in the case that nfs
>> is mounted implicitly to the save path other than explicitly
>> using the "nfs" directive in /etc/kdump.conf,
"is_nfs_dump_target"
>> will return false, so this nfs mount will be added "x-initrd.mount"
>> option wrongly.
>>
>> It affects the systemd service behaviours when emergency failure
>> happens as the code comment described.
>>
>> To fix it, we use "is_fs_type_nfs $_fstype" instead.
>>
>> Signed-off-by: Xunlei Pang <xlpang(a)redhat.com>
>> ---
>> mkdumprd | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/mkdumprd b/mkdumprd
>> index f30d9c2..f1bac01 100644
>> --- a/mkdumprd
>> +++ b/mkdumprd
>> @@ -120,7 +120,7 @@ to_mount() {
>> # If remote mount fails, dracut-initqueue will still start and once
>> # dracut-initqueue finishes, kdump service will start. Because remote mount
>> # failed, kdump service will fail and it will lead to kdump error handler.
>> - if ! is_nfs_dump_target; then
>> + if ! is_fs_type_nfs $_fstype; then
>> _options="$_options,x-initrd.mount"
>> fi
>> _mntopts="$_target $_fstype $_options"
>> --
>> 1.8.3.1
>> _______________________________________________
>> kexec mailing list -- kexec(a)lists.fedoraproject.org
>> To unsubscribe send an email to kexec-leave(a)lists.fedoraproject.org
> Acked-by: Dave Young <dyoung(a)redhat.com>
Per discussion in irc. let's defer this one since during your testing
kdump works well without appending x-initrd.mount. Let's do more test
and work on it after understanding why later..
Maybe I made a mistake last time when testing rhel7, there is some difference between
rhel7 and Fedora
in terms of systemd. The difference was introduced by the following systemd fstab
generator commit, that's
why "x-initrd.mount" makes no difference on Fedora which uses a newer systemd
including this commit:
commit ce3f6d82b003f365f718f24e48f55b8a0372b924
Author: nmartensen <nis.martensen(a)web.de>
Date: Fri Jan 15 07:55:25 2016 +0100
fstab-generator: remove bogus condition
The sysroot mount is already taken care of by the add_sysroot_mount function. With
this condition left in, we can g
initrd-root-fs.target.requires
`-- usr.mount -> /run/systemd/generator/usr.mount
in the main system (i.e., not in the initramfs). In the initramfs, the previous
condition already kicks in.
diff --git a/src/fstab-generator/fstab-generator.c
b/src/fstab-generator/fstab-generator.c
index 87b8b77..c924b65 100644
--- a/src/fstab-generator/fstab-generator.c
+++ b/src/fstab-generator/fstab-generator.c
@@ -463,8 +463,6 @@ static int parse_fstab(bool initrd) {
"x-systemd.automount\0");
if (initrd)
post = SPECIAL_INITRD_FS_TARGET;
- else if (mount_in_initrd(me)) // true if with
"x-initrd.mount" option
- post = SPECIAL_INITRD_ROOT_FS_TARGET;
else if (mount_is_network(me))
post = SPECIAL_REMOTE_FS_TARGET;
else