From nobody Sun May 08 07:56:50 2022 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id ED70D1AC8F5D; Sun, 8 May 2022 07:56:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KwxTZ6Kmcz3qTD; Sun, 8 May 2022 07:56:50 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1651996610; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jmHXUAzgsh+3w05vTxI25vlZP6AS7ZmMWysI/Cut4rI=; b=ZZo+bjLPkKC0JeI96PSH1KnGnitVgZRALKaesoEhRusKfdHHwQGcOYmOOROca8oDJ5M4zX HI1gyxpDL3FpH2V78VuJeUGyzJonCjSF+/QSAr4kSkhNVNzPn1mYcAQ7ilq51JR23AmwVb vUs96+eLrBFbYFSc7GWCfODh8/nIMWobwhxqp+JozuHbsQVKKuD7bCEKpzCP80Vfjpmsl1 LiAOp1XdHWaPOQnjUDb4RRneVz5KSjzyDQM+zA5BROUYPtcUSfB7X1eAmFQoeYFL5epdU1 vyrL8HEzhg915+TiaD6N4tEExMKBKzoAyf4qejohKXmCJJFUSWEi6o0mcQZiHA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B517521105; Sun, 8 May 2022 07:56:50 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2487uo4V012614; Sun, 8 May 2022 07:56:50 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2487uo6A012613; Sun, 8 May 2022 07:56:50 GMT (envelope-from git) Date: Sun, 8 May 2022 07:56:50 GMT Message-Id: <202205080756.2487uo6A012613@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Peter Holm Subject: git: 13aacd0c0cb6 - main - stress2: Added a test scenario List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pho X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 13aacd0c0cb6c1e6da41c0d10bf41c1ed51a28d2 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1651996610; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jmHXUAzgsh+3w05vTxI25vlZP6AS7ZmMWysI/Cut4rI=; b=hRDkoCyOEm4rOStH4HoWnpf0l3QF/SlnVfsQC6zFJaEXlhWsTbOk3VLbQG+ThyFwti3Cdj xeE3W/f3gZkFdeCGKrO/eNqLIQZP49gvvMaQhs+maEAeCF2f0pno1OlomSy2yh07pPAL4J WeZGHtp0gMonqQ4LVlaosq0kPZRRYL3OcSbmwO7MdcTUbcOaPvqwp+fSFo8vxIF3nicbb5 VGC6NEzoOpYXFk2zkv/9a3Sm6GF+bgwh4Gq3Id727TkUyc0FUoOnC5axvVFx5p/mdzCV+8 zRWI8INE1F8TnPjpGlmWQ99yieK5/cUfa7Y3fJXu+vZRREQtN2agVdB9V/l+RA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1651996610; a=rsa-sha256; cv=none; b=lkKxgZcbyrXdpAXgbRR1RfkVNcjZk4UHenMtjzJvBj8n2VcBEKsuTuCBDFlD9YA4WDJD4M juvjgnud+Qq8DNKd3bLw6GR9Q8p8oC+aLJCZ9QWHn346ljh4wWnJVE61kwlzsvSHiYHLbY usBz8CkAKYtv+U94jIe7uzV0e5hzRtMooaGmYU221MJbzg+cU2ZZbo3r3lIXIMg782jTMD F3ubLBPjD7RDvocZ6hRH8qZnerSNp/ZeR/AZFgRre2kuePP1dHnT24foqJVcmIR4NmYsE4 xsNEsnig58d5aTFrNGVEMq0THPt/GZ1OO9whbFElSwE/J1ri46e12PnbHvBu2A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by pho: URL: https://cgit.FreeBSD.org/src/commit/?id=13aacd0c0cb6c1e6da41c0d10bf41c1ed51a28d2 commit 13aacd0c0cb6c1e6da41c0d10bf41c1ed51a28d2 Author: Peter Holm AuthorDate: 2022-05-08 07:54:54 +0000 Commit: Peter Holm CommitDate: 2022-05-08 07:54:54 +0000 stress2: Added a test scenario --- tools/test/stress2/misc/all.exclude | 1 + tools/test/stress2/misc/mdconfig5.sh | 55 ++++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) diff --git a/tools/test/stress2/misc/all.exclude b/tools/test/stress2/misc/all.exclude index df687f47cfb0..986daf714d0d 100644 --- a/tools/test/stress2/misc/all.exclude +++ b/tools/test/stress2/misc/all.exclude @@ -28,6 +28,7 @@ lockf5.sh Spinning threads seen 20160718 ifconfig.sh Bug 253824 20210322 ifconfig2.sh https://people.freebsd.org/~pho/stress/log/log0051.txt 20210210 maxvnodes2.sh https://people.freebsd.org/~pho/stress/log/log0083.txt 20210329 +mdconfig5.sh https://people.freebsd.org/~pho/stress/log/log0159.txt 20220508 memguard.sh https://people.freebsd.org/~pho/stress/log/log0088.txt 20210402 memguard2.sh Waiting for fix commit memguard3.sh Waiting for fix commit diff --git a/tools/test/stress2/misc/mdconfig5.sh b/tools/test/stress2/misc/mdconfig5.sh new file mode 100755 index 000000000000..b0b25cc5d64b --- /dev/null +++ b/tools/test/stress2/misc/mdconfig5.sh @@ -0,0 +1,55 @@ +#!/bin/sh + +# +# SPDX-License-Identifier: BSD-2-Clause-FreeBSD +# +# Copyright (c) 2022 Peter Holm +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# + +[ `id -u ` -ne 0 ] && echo "Must be root!" && exit 1 + +# Bug 257557 Garbage on disk (or USB memory stick) can cause GEOM taste ffs_sbget() to crash. +# "panic: wrong length 4352 for sectorsize 512" seen: +# https://people.freebsd.org/~pho/stress/log/log0159.txt + +. ../default.cfg + +mdconfig -l | grep -q md$mdstart && mdconfig -d -u $mdstart +cc -o /tmp/flip -Wall -Wextra -O2 ../tools/flip.c || exit 1 +start=`date +%s` +while [ $((`date +%s` - start)) -lt 120 ]; do + dd if=/dev/zero of=$diskimage bs=8m count=1 status=none + mdconfig -a -t vnode -f $diskimage -u $mdstart + newfs $newfs_flags /dev/md$mdstart > /dev/null + mdconfig -d -u $mdstart + for i in `jot 10`; do + /tmp/flip -n 4 $diskimage + mdconfig -a -t vnode -f $diskimage -u $mdstart && + mdconfig -d -u $mdstart + done +done + +mdconfig -l | grep -q md$mdstart && mdconfig -d -u $mdstart +rm -f $diskimage /tmp/flip +exit 0