From: Andreas Dilger Date: Mon, 15 May 2017 21:56:18 +0000 (+0200) Subject: LU-9201 tests: don't check network for localhost X-Git-Tag: 2.10.56~50 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=ee2e79bd389c968db43ebe88814e8b24eb096c3c;p=fs%2Flustre-release.git LU-9201 tests: don't check network for localhost Don't try to check if the network to the local host is up, since this just wastes time and adds noise to the test output logs. Remove ancient 1.8 compatibility check. Test-Parameters: trivial Signed-off-by: Andreas Dilger Change-Id: I6c1f8df613afd657155da1309525e75b9d1c5bae Reviewed-on: https://review.whamcloud.com/29011 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Steve Guminski Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh index be82fec..9874da4 100755 --- a/lustre/tests/test-framework.sh +++ b/lustre/tests/test-framework.sh @@ -4870,17 +4870,19 @@ wait_for_function () { } check_network() { - local host=$1 - local max=$2 - local sleep=${3:-5} + local host=$1 + local max=$2 + local sleep=${3:-5} - echo `date +"%H:%M:%S (%s)"` waiting for $host network $max secs ... - if ! wait_for_function --quiet "ping -c 1 -w 3 $host" $max $sleep ; then - echo "Network not available!" - exit 1 - fi + [ "$host" = "$HOSTNAME" ] && return 0 + + echo "$(date +'%H:%M:%S (%s)') waiting for $host network $max secs ..." + if ! wait_for_function --quiet "ping -c 1 -w 3 $host" $max $sleep ; then + echo "Network not available!" + exit 1 + fi - echo `date +"%H:%M:%S (%s)"` network interface is UP + echo "$(date +'%H:%M:%S (%s)') network interface is UP" } no_dsh() { @@ -6357,10 +6359,7 @@ get_mdtosc_proc_path() { local mdt_label=$(convert_facet2label $mds_facet) local mdt_index=$(echo $mdt_label | sed -e 's/^.*-//') - if [ $(lustre_version_code $mds_facet) -le $(version_code 1.8.0) ] || - mds_on_old_device $mds_facet; then - echo "${ost_label}-osc" - elif [[ $ost_label = *OST* ]]; then + if [[ $ost_label = *OST* ]]; then echo "${ost_label}-osc-${mdt_index}" else echo "${ost_label}-osp-${mdt_index}"