From patchwork Fri Mar 20 10:16:56 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eryu Guan X-Patchwork-Id: 6055431 Return-Path: X-Original-To: patchwork-fstests@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 270C9BF90F for ; Fri, 20 Mar 2015 10:17:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6B387204D1 for ; Fri, 20 Mar 2015 10:17:45 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8280C201C0 for ; Fri, 20 Mar 2015 10:17:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751728AbbCTKRo (ORCPT ); Fri, 20 Mar 2015 06:17:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44152 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751747AbbCTKRn (ORCPT ); Fri, 20 Mar 2015 06:17:43 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t2KAHglp021710 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Fri, 20 Mar 2015 06:17:43 -0400 Received: from localhost (dhcp-12-136.nay.redhat.com [10.66.12.136]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t2KAHfBm005945; Fri, 20 Mar 2015 06:17:42 -0400 From: Eryu Guan To: fstests@vger.kernel.org Cc: Eryu Guan Subject: [PATCH 7/9] common: recognise NFS export over IPv6 in _require_scratch_nocheck() Date: Fri, 20 Mar 2015 18:16:56 +0800 Message-Id: <1426846618-23413-8-git-send-email-eguan@redhat.com> In-Reply-To: <1426846618-23413-1-git-send-email-eguan@redhat.com> References: <1426846618-23413-1-git-send-email-eguan@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This commit 73dfa4a common: Fixes for testing NFS over IPv6 adds NFS over IPv6 support, and commit 76c5f3c common: re-enable tests that require scratch dev on NFS enables NFS tests on scratch device. Now do the same updates to _require_scratch_nocheck() to enable NFS over IPv6 support on scratch device. Signed-off-by: Eryu Guan Reviewed-by: Brian Foster --- common/rc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/common/rc b/common/rc index 857308a..fbb19c2 100644 --- a/common/rc +++ b/common/rc @@ -1111,10 +1111,12 @@ _require_scratch_nocheck() esac # mounted? - if _mount | grep -q $SCRATCH_DEV + # Note that we use -F here so grep doesn't try to interpret an NFS over + # IPv6 server as a regular expression. + if _mount | grep -F -q $SCRATCH_DEV then # if it's mounted, make sure its on $SCRATCH_MNT - if ! _mount | grep $SCRATCH_DEV | grep -q $SCRATCH_MNT + if ! _mount | grep -F $SCRATCH_DEV | grep -q $SCRATCH_MNT then echo "\$SCRATCH_DEV is mounted but not on \$SCRATCH_MNT - aborting" exit 1