From patchwork Wed Jan 9 12:57:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Kodanev X-Patchwork-Id: 1022416 X-Patchwork-Delegate: petr.vorel@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=lists.linux.it (client-ip=2001:1418:10:5::2; helo=picard.linux.it; envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=oracle.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=oracle.com header.i=@oracle.com header.b="FiQTO+Mp"; dkim-atps=neutral Received: from picard.linux.it (picard.linux.it [IPv6:2001:1418:10:5::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43ZTRk30YWz9sDL for ; Wed, 9 Jan 2019 23:47:29 +1100 (AEDT) Received: from picard.linux.it (localhost [IPv6:::1]) by picard.linux.it (Postfix) with ESMTP id 2B16F294A74 for ; Wed, 9 Jan 2019 13:47:26 +0100 (CET) X-Original-To: ltp@lists.linux.it Delivered-To: ltp@picard.linux.it Received: from in-5.smtp.seeweb.it (in-5.smtp.seeweb.it [IPv6:2001:4b78:1:20::5]) by picard.linux.it (Postfix) with ESMTP id 1D7C4294A6F for ; Wed, 9 Jan 2019 13:47:23 +0100 (CET) Received: from userp2130.oracle.com (userp2130.oracle.com [156.151.31.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by in-5.smtp.seeweb.it (Postfix) with ESMTPS id 4EEB6600965 for ; Wed, 9 Jan 2019 13:47:23 +0100 (CET) Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id x09Ci534074621; Wed, 9 Jan 2019 12:47:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id; s=corp-2018-07-02; bh=6DAQ4EvwEYOXWqbm1d+ICbxS6dJfksPjw4+9a1nh5Hc=; b=FiQTO+MpvDkNkGhsPagU3iYyW7jzAURe9El0hakdUZEInbHLqPWI0jDS9A9gHAqye9yJ 84kXyAMPAlPSSt25b1W7yaLwBK1djRIGUcigxoi3++sWBDlBPn/zVWQpu/Zb6Md9Qn/X 6ZLvCYxKCZd5SNddhfy3hEy+G20D67RDszYBgtnhHys3sWfooqBOoQ4f/ZWlQ6ixZehP eyGuS6mMx+zi33mlE8ynvJkLfHJPFfluS1JAUzKUmX4HxMM0noMUYP4MjA5N7+gVdYD5 lnluqF+766NDwpLX29s1c5HgxYqOp/lFawBkU0q0UKIuamDLH7VgZclTkFAkJJmzxdke Rg== Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by userp2130.oracle.com with ESMTP id 2ptm0u954h-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 09 Jan 2019 12:47:20 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserv0022.oracle.com (8.14.4/8.14.4) with ESMTP id x09ClJk9012942 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 9 Jan 2019 12:47:19 GMT Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x09ClIGm012919; Wed, 9 Jan 2019 12:47:19 GMT Received: from ak.ru.oracle.com (/10.162.80.29) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 09 Jan 2019 04:47:18 -0800 From: Alexey Kodanev To: ltp@lists.linux.it Date: Wed, 9 Jan 2019 15:57:40 +0300 Message-Id: <1547038660-14008-1-git-send-email-alexey.kodanev@oracle.com> X-Mailer: git-send-email 1.7.1 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9130 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=467 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901090107 X-Virus-Scanned: clamav-milter 0.99.2 at in-5.smtp.seeweb.it X-Virus-Status: Clean X-Spam-Status: No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU, SPF_HELO_PASS, SPF_PASS autolearn=disabled version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on in-5.smtp.seeweb.it Subject: [LTP] [PATCH] lib/tst_net.sh: fix tst_set_sysctl() for non-netns setup X-BeenThere: ltp@lists.linux.it X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux Test Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it Sender: "ltp" When we don't use netns setup, $rparam is empty in tst_set_sysctl(), and tst_net_run() mistakenly set sysctl command to $rparam. This results to the following error, $cmd is empty: bbr01 1 TINFO: timeout per run is 0h 20m 0s bbr01 1 TINFO: emulate congestion with packet loss 0.5% bbr01 1 TINFO: compare 'cubic' and 'bbr' congestion alg. results bbr01 1 TINFO: setting cubic bbr01 1 TBROK: tst_net_run: command not defined Signed-off-by: Alexey Kodanev --- testcases/lib/tst_net.sh | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/testcases/lib/tst_net.sh b/testcases/lib/tst_net.sh index 209cf9b..eca616f 100644 --- a/testcases/lib/tst_net.sh +++ b/testcases/lib/tst_net.sh @@ -718,9 +718,9 @@ tst_set_sysctl() [ "$3" = "safe" ] && safe="-s" local rparam= - [ "$TST_USE_NETNS" = "yes" ] && rparam="-e" + [ "$TST_USE_NETNS" = "yes" ] && rparam="-r -e" - tst_net_run $safe -r $rparam "sysctl -q -w $name=$value" + tst_net_run $safe $rparam "sysctl -q -w $name=$value" } tst_cleanup_rhost()