Handle net option for nfs in kdump.conf correctly

Resolve: bug 807521

The fix is easy.

Command sed should be called with option -n to remain slience when DUMP_TARGET
is a nfs server like 'nfs.server:/mnt/testarea/nfs'.

Then nfs function check_ssh_config will return 1 to not to config nfs like a
ssh dump

Signed-off-by: Chao Wang <chaowang@redhat.com>
This commit is contained in:
Chao Wang 2012-03-28 16:23:38 +08:00 committed by Cong Wang
parent f7b9767f87
commit f590d235e0

View File

@ -198,7 +198,7 @@ function check_ssh_config()
done < $KDUMP_CONFIG_FILE
#make sure they've configured kdump.conf for ssh dumps
local SSH_TARGET=`echo -n $DUMP_TARGET|sed '/.*@/p'`
local SSH_TARGET=`echo -n $DUMP_TARGET | sed -n '/.*@/p'`
if [ -z "$SSH_TARGET" ]; then
return 1
fi