Hi,
On 08/02/17 at 05:56pm, Ziyue Yang wrote:
This commit makes dump_ssh to add 'kdump-' prefix to ipv6
hosts with 'eth*' like interfaces before dumping to the host.
Pingfan said the known_hosts file also has issues, it is not a problem
in your test?
Signed-off-by: Ziyue Yang <ziyang(a)redhat.com>
---
dracut-kdump.sh | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/dracut-kdump.sh b/dracut-kdump.sh
index b75c2a5..a50eb60 100755
--- a/dracut-kdump.sh
+++ b/dracut-kdump.sh
@@ -75,6 +75,16 @@ dump_ssh()
local _dir="$KDUMP_PATH/$HOST_IP-$DATEDIR"
local _host=$2
+ # figure out "kdump- prefixed network interface name for
+ # link-local ipv6 address
+ if [[ $_host == *":"* ]]; then
is_ipv6_address?
+ local _host_prefix=${_host%\%*}
+ local _ifname=${_host##*\%}
+ if [[ $_ifname == "eth"* ]]; then
It could be other kernel names? how about just add kdump prefix without
the checking.
+ _host="$_host_prefix%kdump-$_ifname"
+ fi
+ fi
+
echo "kdump: saving to $_host:$_dir"
cat /var/lib/random-seed > /dev/urandom
--
2.9.3
_______________________________________________
kexec mailing list -- kexec(a)lists.fedoraproject.org
To unsubscribe send an email to kexec-leave(a)lists.fedoraproject.org
Thanks
Dave