diff options
| author | CoprDistGit <infra@openeuler.org> | 2024-07-26 17:19:39 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2024-07-26 17:19:39 +0000 |
| commit | 5be00af7c80ed4972c1f3379e6db9937e1a8b7bd (patch) | |
| tree | 7938404f19676c304f68d0d47e475fe4a1440452 /dracut-kdump-wait-for-target.sh | |
| parent | ad07ec0c7538028e4d732f63e34d58150f5ffd42 (diff) | |
automatic import of kexec-tools
Diffstat (limited to 'dracut-kdump-wait-for-target.sh')
| -rwxr-xr-x | dracut-kdump-wait-for-target.sh | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/dracut-kdump-wait-for-target.sh b/dracut-kdump-wait-for-target.sh new file mode 100755 index 0000000..ce984d0 --- /dev/null +++ b/dracut-kdump-wait-for-target.sh @@ -0,0 +1,23 @@ +#!/bin/sh + +# only wait if it's kdump kernel +if [ -f /etc/fadump.initramfs ] && [ ! -f /proc/device-tree/rtas/ibm,kernel-dump ]; then + exit 0 +fi + +. /lib/dracut-lib.sh +. /lib/kdump-lib-initramfs.sh + +# For SSH/NFS target, need to wait for the network to setup +if is_nfs_dump_target; then + get_host_ip + exit $? +fi + +if is_ssh_dump_target; then + get_host_ip + exit $? +fi + +# No need to wait for dump target +exit 0 |
