Actually mntpoint is also passed as an argument to Dracut. So, we do the rebuild
if there is a change needed into that.
For example:
# egrep -v "^#" /etc/kdump.conf
ext4 /dev/md0
path /var/crash
core_collector makedumpfile -l --message-level 1 -d 31 -F
# mount /dev/md0 /mnt/
# lsinitrd /boot/initramfs-4.5.0-302.fc24.x86_64+debugkdump.img | grep
"Arguments"
Arguments: --hostonly -o 'plymouth dash resume ifcfg' --mount
'/dev/disk/by-uuid/d249a4ec-0603-49d0-8d6b-a19314081f35 /kdumproot//mnt ext4
rw,relatime,seclabel,stripe=256,data=ordered,x-initrd.mount' -f
Now mount /dev/md0 to another directory.
# umount /mnt;mount /dev/md0 /dump/;kdumpctl restart
# lsinitrd /boot/initramfs-4.5.0-302.fc24.x86_64+debugkdump.img | grep
# "Arguments"
Arguments: --hostonly -o 'plymouth dash resume ifcfg' --mount
'/dev/disk/by-uuid/d249a4ec-0603-49d0-8d6b-a19314081f35 /kdumproot//dump ext4
rw,relatime,seclabel,stripe=256,data=ordered,x-initrd.mount' -f
So, here we did not do any change in kdump.conf, however when mount target dir
is changed, dracut is passed with different arguments (if rebuild).
So, IMHO we should rebuild if any condition is triggered which may cause change
in mntpoint dracut argument.
Pratyush, I got your points, it make sense.
I was just confused why using /dev/md0 as an example because one should always
use persistent device names for dm/lvm devices.
We do not need to fix it if it is only for /dev/md*, but as you said it also
fit for /dev/mapper/* device nodes so the changes will be fine.
Thanks
Dave