From owner-svn-src-user@FreeBSD.ORG Wed Sep 18 18:02:02 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7340F336; Wed, 18 Sep 2013 18:02:02 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 46EB92B79; Wed, 18 Sep 2013 18:02:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8II22I0056959; Wed, 18 Sep 2013 18:02:02 GMT (envelope-from sbruno@svn.freebsd.org) Received: (from sbruno@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8II21n1056957; Wed, 18 Sep 2013 18:02:01 GMT (envelope-from sbruno@svn.freebsd.org) Message-Id: <201309181802.r8II21n1056957@svn.freebsd.org> From: Sean Bruno Date: Wed, 18 Sep 2013 18:02:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255674 - in user/sbruno: mfid mptd X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Sep 2013 18:02:02 -0000 Author: sbruno Date: Wed Sep 18 18:02:01 2013 New Revision: 255674 URL: http://svnweb.freebsd.org/changeset/base/255674 Log: Nuke license from rc scripts. Modified: user/sbruno/mfid/mfid.rc user/sbruno/mptd/mptd.rc Modified: user/sbruno/mfid/mfid.rc ============================================================================== --- user/sbruno/mfid/mfid.rc Wed Sep 18 17:58:03 2013 (r255673) +++ user/sbruno/mfid/mfid.rc Wed Sep 18 18:02:01 2013 (r255674) @@ -1,30 +1,3 @@ -/*- - * Copyright (c) 2011 Yahoo! Inc. - * All rights reserved. - * - * 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. - * - */ - #!/bin/sh # PROVIDE: mfid Modified: user/sbruno/mptd/mptd.rc ============================================================================== --- user/sbruno/mptd/mptd.rc Wed Sep 18 17:58:03 2013 (r255673) +++ user/sbruno/mptd/mptd.rc Wed Sep 18 18:02:01 2013 (r255674) @@ -1,7 +1,4 @@ #!/bin/sh -# -# $Yahoo: //depot/yahoo/ybsd_9/src/etc/rc.d/mptd#1 $ -# # PROVIDE: mptd # REQUIRE: dumpon root ldconfig devfs syslogd mail From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 07:39:09 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 0A128275; Thu, 19 Sep 2013 07:39:09 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id ECE882A56; Thu, 19 Sep 2013 07:39:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8J7d86u094185; Thu, 19 Sep 2013 07:39:08 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8J7d8w3094184; Thu, 19 Sep 2013 07:39:08 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309190739.r8J7d8w3094184@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 07:39:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255697 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 07:39:09 -0000 Author: pho Date: Thu Sep 19 07:39:08 2013 New Revision: 255697 URL: http://svnweb.freebsd.org/changeset/base/255697 Log: Added msync(2) regression test. Sponsored by: EMC / Isilon storage division Added: user/pho/stress2/misc/msync2.sh (contents, props changed) Added: user/pho/stress2/misc/msync2.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ user/pho/stress2/misc/msync2.sh Thu Sep 19 07:39:08 2013 (r255697) @@ -0,0 +1,126 @@ +#!/bin/sh + +# +# Copyright (c) 2013 EMC Corp. +# All rights reserved. +# +# 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. +# +# $FreeBSD$ +# + +# "panic: vm_pageout_flush: partially invalid page xx index 0/1" seen. +# Fixed in r255566. + +dir=/tmp +odir=`pwd` +cd $dir +sed '1,/^EOF/d' < $odir/$0 > $dir/msync2.c +cc -o msync2 -Wall -Wextra msync2.c || exit 1 +rm -f msync2.c +cd $odir + +dd if=/dev/zero bs=$((4096 + 1)) of=/tmp/msync2.inputfile count=1 2>&1 | + egrep -v "records|transferred" +/tmp/msync2 /tmp/msync2.inputfile +rm -f /tmp/msync2 /tmp/msync2.inputfile +exit + +EOF +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +const char *file; +char c; + +void +wr(void) +{ + struct stat st; + char *p1; + size_t len; + int error, fd; + + if ((fd = open(file, O_RDWR)) == -1) + err(1, "open %s", file); + if ((error = fstat(fd, &st)) == -1) + err(1, "stat(%s)", file); + len = round_page(st.st_size); + if ((p1 = mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0)) == MAP_FAILED) + err(1, "mmap"); +// p1[len - 1] = 1; /* No panic with this */ + p1[arc4random() % len] = 1; /* Need this for the panic */ + + if ((error = msync(p1, len, MS_SYNC | MS_INVALIDATE)) == -1) + if (errno != EBUSY) + err(1, "msync"); + + if (munmap(p1, len) == -1) + err(1, "unmap()"); + close(fd); + + _exit(0); +} + +void +test(void) +{ +#if 1 + int i; + + for (i = 0; i < 3; i++) + if (fork() == 0) + wr(); + for (i = 0; i < 3; i++) + wait(NULL); +#else + wr(); /* No problem here */ +#endif + + _exit(0); +} + +int +main(int argc, char *argv[]) +{ + int i; + + if (argc != 2) + errx(1, "Usage: %s ", argv[0]); + file = argv[1]; + + for (i = 0; i < 30000; i++) { + if (fork() == 0) + test(); + wait(NULL); + } + + return (0); +} From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 08:04:51 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 12919F31; Thu, 19 Sep 2013 08:04:51 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 0112C2BFD; Thu, 19 Sep 2013 08:04:51 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8J84oPo008775; Thu, 19 Sep 2013 08:04:50 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8J84oOR008774; Thu, 19 Sep 2013 08:04:50 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309190804.r8J84oOR008774@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 08:04:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255698 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 08:04:51 -0000 Author: pho Date: Thu Sep 19 08:04:50 2013 New Revision: 255698 URL: http://svnweb.freebsd.org/changeset/base/255698 Log: Added timeout to kevent(2) call. Sponsored by: EMC / Isilon storage division Modified: user/pho/stress2/misc/kevent5.sh Modified: user/pho/stress2/misc/kevent5.sh ============================================================================== --- user/pho/stress2/misc/kevent5.sh Thu Sep 19 07:39:08 2013 (r255697) +++ user/pho/stress2/misc/kevent5.sh Thu Sep 19 08:04:50 2013 (r255698) @@ -37,12 +37,12 @@ odir=`pwd` cd /tmp sed '1,/^EOF/d' < $odir/$0 > kevent5.c -cc -o kevent5 -Wall -Wextra kevent5.c || exit 1 +cc -o kevent5 -Wall -Wextra -O2 -g kevent5.c || exit 1 rm -f kevent5.c [ -d $RUNDIR ] || mkdir -p $RUNDIR cd $RUNDIR -/tmp/kevent5 kevent5.xxx kevent5.yyy +/tmp/kevent5 kevent5.xxx kevent5.yyy > /dev/null 2>&1 rm -f /tmp/kevent5 kevent.xxx kevent.yyy @@ -72,6 +72,7 @@ test(void) { int kq = -1; int n; struct kevent ev[2]; + struct timespec ts; int fd; if ((fd = open(file1, O_RDONLY, 0)) == -1) @@ -85,7 +86,10 @@ test(void) { NOTE_DELETE, 0, 0); n++; - if (kevent(kq, ev, n, NULL, 0, NULL) < 0) + ts.tv_sec = 5; + ts.tv_nsec = 0; + + if (kevent(kq, ev, n, NULL, 0, &ts) < 0) err(1, "kevent()"); memset(&ev, 0, sizeof(ev)); @@ -111,7 +115,7 @@ test(void) { err(1, "kevent()"); memset(&ev, 0, sizeof(ev)); - n = kevent(kq, NULL, 0, ev, 1, NULL); + n = kevent(kq, NULL, 0, ev, 1, &ts); // printf("Event 2\n"); close(fd); close(kq); @@ -130,7 +134,6 @@ main(int argc, char **argv) { file1 = argv[1]; file2 = argv[2]; - alarm(600); for (j = 0; j < 100; j++) { if ((fd = open(file1, O_CREAT | O_TRUNC | O_RDWR, 0660)) == -1) err(1, "open(%s)", file1); From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 11:06:59 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 2D6D4295; Thu, 19 Sep 2013 11:06:59 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 1BAA725C5; Thu, 19 Sep 2013 11:06:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8JB6w5q005002; Thu, 19 Sep 2013 11:06:58 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8JB6wDW005001; Thu, 19 Sep 2013 11:06:58 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309191106.r8JB6wDW005001@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 11:06:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255700 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 11:06:59 -0000 Author: pho Date: Thu Sep 19 11:06:58 2013 New Revision: 255700 URL: http://svnweb.freebsd.org/changeset/base/255700 Log: Use getpwnam() get switch to user "nobody". Sponsored by: EMC / Isilon storage division Modified: user/pho/stress2/misc/syscall4.sh Modified: user/pho/stress2/misc/syscall4.sh ============================================================================== --- user/pho/stress2/misc/syscall4.sh Thu Sep 19 10:56:36 2013 (r255699) +++ user/pho/stress2/misc/syscall4.sh Thu Sep 19 11:06:58 2013 (r255700) @@ -78,6 +78,7 @@ EOF #include #include #include +#include #include #include #include @@ -114,9 +115,6 @@ int fd[900], fds[2], socketpr[2]; u_int32_t r[N]; int syscallno; -#define UID_NOBODY 65534 -#define GID_NOBODY 65534 - static int random_int(int mi, int ma) { @@ -240,13 +238,18 @@ calls(void *arg __unused) int main(int argc, char **argv) { + struct passwd *pw; pthread_t rp, cp[50]; int i, j; - if (setgid(GID_NOBODY) == -1) - err(1, "setgid(%d)", GID_NOBODY); - if (setuid(UID_NOBODY) == -1) - err(1, "setuid(%d)", UID_NOBODY); + if ((pw = getpwnam("nobody")) == NULL) + err(1, "no such user: nobody"); + + if (setgroups(1, &pw->pw_gid) || + setegid(pw->pw_gid) || setgid(pw->pw_gid) || + seteuid(pw->pw_uid) || setuid(pw->pw_uid)) + err(1, "Can't drop privileges to \"nobody\""); + endpwent(); signal(SIGALRM, hand); signal(SIGILL, hand); From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 12:10:48 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 5B067D1; Thu, 19 Sep 2013 12:10:48 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4963B2965; Thu, 19 Sep 2013 12:10:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8JCAmVh039541; Thu, 19 Sep 2013 12:10:48 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8JCAmBu039540; Thu, 19 Sep 2013 12:10:48 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309191210.r8JCAmBu039540@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 12:10:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255701 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 12:10:48 -0000 Author: pho Date: Thu Sep 19 12:10:47 2013 New Revision: 255701 URL: http://svnweb.freebsd.org/changeset/base/255701 Log: Check syscall argument against ignore list. Added support for LP64. Sponsored by: EMC / Isilon storage division Modified: user/pho/stress2/misc/syscall4.sh Modified: user/pho/stress2/misc/syscall4.sh ============================================================================== --- user/pho/stress2/misc/syscall4.sh Thu Sep 19 11:06:58 2013 (r255700) +++ user/pho/stress2/misc/syscall4.sh Thu Sep 19 12:10:47 2013 (r255701) @@ -108,6 +108,7 @@ static int ignore[] = { SYS_mac_syscall, SYS_sigtimedwait, SYS_sigwaitinfo, + SYS_pdfork, }; int fd[900], fds[2], socketpr[2]; @@ -129,7 +130,8 @@ hand(int i __unused) { /* handler */ unsigned long makearg(void) { - unsigned int i, val; + unsigned int i; + unsigned long val; val = arc4random(); i = arc4random() % 100; @@ -138,7 +140,14 @@ makearg(void) if (i >= 20 && i < 40) val = val & 0xffff; if (i >= 40 && i < 60) - val = (unsigned long)(r) + (val & 0xffff); + val = (unsigned long)(r) | (val & 0xffff); +#if defined(__LP64__) + if (i >= 60) { + val = (val << 32) | arc4random(); + if (i > 80) + val = val & 0x00007fffffffffffUL; + } +#endif return(val); } @@ -208,7 +217,7 @@ calls(void *arg __unused) num = syscallno; while (num == 0) { num = random_int(0, SYS_MAXSYSCALL); - for (j = 0; j < (int)sizeof(ignore) / (int)sizeof(ignore[0]); j++) + for (j = 0; j < (int)nitems(ignore); j++) if (num == ignore[j]) { num = 0; break; @@ -260,8 +269,12 @@ main(int argc, char **argv) signal(SIGSYS, hand); signal(SIGTRAP, hand); - if (argc == 2) + if (argc == 2) { syscallno = atoi(argv[1]); + for (j = 0; j < (int)nitems(ignore); j++) + if (syscallno == ignore[j]) + errx(0, "syscall #%d is on the ignore list.", syscallno); + } for (i = 0; i < 100000; i++) { if (fork() == 0) { From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 12:29:00 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 6FC204A1; Thu, 19 Sep 2013 12:29:00 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 5DD6E2A43; Thu, 19 Sep 2013 12:29:00 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8JCT0wR048115; Thu, 19 Sep 2013 12:29:00 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8JCT0w6048114; Thu, 19 Sep 2013 12:29:00 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201309191229.r8JCT0w6048114@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Thu, 19 Sep 2013 12:29:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255702 - user/des/tinderbox X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 12:29:00 -0000 Author: des Date: Thu Sep 19 12:28:59 2013 New Revision: 255702 URL: http://svnweb.freebsd.org/changeset/base/255702 Log: Only run svn cleanup + svn update if the source directory has a .svn subdirectory. The source directory might already exist but be empty; for instance, it could be a tmpfs mount. Modified: user/des/tinderbox/tinderbox.pl Modified: user/des/tinderbox/tinderbox.pl ============================================================================== --- user/des/tinderbox/tinderbox.pl Thu Sep 19 12:10:47 2013 (r255701) +++ user/des/tinderbox/tinderbox.pl Thu Sep 19 12:28:59 2013 (r255702) @@ -600,7 +600,7 @@ MAIN:{ my $svncmd = [grep({ -x } @svncmds)]->[0] or error("unable to locate svn binary"); cd("$sandbox"); - if (-d $srcdir) { + if (-d "$srcdir/.svn") { spawn($svncmd, "cleanup", $srcdir); push(@svnargs, "update", $srcdir); } else { From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 13:01:32 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 02426E57; Thu, 19 Sep 2013 13:01:32 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E4E3C2C7E; Thu, 19 Sep 2013 13:01:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8JD1Vfu068777; Thu, 19 Sep 2013 13:01:31 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8JD1VZr068776; Thu, 19 Sep 2013 13:01:31 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309191301.r8JD1VZr068776@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 13:01:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255703 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 13:01:32 -0000 Author: pho Date: Thu Sep 19 13:01:31 2013 New Revision: 255703 URL: http://svnweb.freebsd.org/changeset/base/255703 Log: Limit run time to 2 minutes. ftsoptions must be non zero. Sponsored by: EMC / Isilon storage division Modified: user/pho/stress2/misc/syscall4.sh Modified: user/pho/stress2/misc/syscall4.sh ============================================================================== --- user/pho/stress2/misc/syscall4.sh Thu Sep 19 12:28:59 2013 (r255702) +++ user/pho/stress2/misc/syscall4.sh Thu Sep 19 13:01:31 2013 (r255703) @@ -163,7 +163,6 @@ test(void *arg __unused) int i; ftsoptions = FTS_PHYSICAL; - ftsoptions = 0; args[0] = "/dev"; args[1] = "/proc"; args[2] = "/usr/compat/linux/proc"; @@ -188,8 +187,6 @@ test(void *arg __unused) i = i % 900; } - if (errno != 0 && errno != ENOENT) - warn("fts_read"); if (fts_close(fts) == -1) err(1, "fts_close()"); if (pipe(fds) == -1) @@ -249,7 +246,8 @@ main(int argc, char **argv) { struct passwd *pw; pthread_t rp, cp[50]; - int i, j; + time_t start; + int j; if ((pw = getpwnam("nobody")) == NULL) err(1, "no such user: nobody"); @@ -276,7 +274,8 @@ main(int argc, char **argv) errx(0, "syscall #%d is on the ignore list.", syscallno); } - for (i = 0; i < 100000; i++) { + start = time(NULL); + while ((time(NULL) - start) < 120) { if (fork() == 0) { arc4random_stir(); if (pthread_create(&rp, NULL, test, NULL) != 0) From owner-svn-src-user@FreeBSD.ORG Thu Sep 19 13:49:56 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 05F10AB5; Thu, 19 Sep 2013 13:49:56 +0000 (UTC) (envelope-from pho@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id E87B92F0C; Thu, 19 Sep 2013 13:49:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8JDntHS092899; Thu, 19 Sep 2013 13:49:55 GMT (envelope-from pho@svn.freebsd.org) Received: (from pho@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8JDntWZ092898; Thu, 19 Sep 2013 13:49:55 GMT (envelope-from pho@svn.freebsd.org) Message-Id: <201309191349.r8JDntWZ092898@svn.freebsd.org> From: Peter Holm Date: Thu, 19 Sep 2013 13:49:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255704 - user/pho/stress2/misc X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Sep 2013 13:49:56 -0000 Author: pho Date: Thu Sep 19 13:49:55 2013 New Revision: 255704 URL: http://svnweb.freebsd.org/changeset/base/255704 Log: Make it possible to configure sleep time for single syscall tests. Sponsored by: EMC / Isilon storage division Modified: user/pho/stress2/misc/syscall4.sh Modified: user/pho/stress2/misc/syscall4.sh ============================================================================== --- user/pho/stress2/misc/syscall4.sh Thu Sep 19 13:01:31 2013 (r255703) +++ user/pho/stress2/misc/syscall4.sh Thu Sep 19 13:49:55 2013 (r255704) @@ -57,9 +57,11 @@ newfs -U md${mdstart}$part > /dev/null mount /dev/md${mdstart}$part $mntpoint chmod 777 $mntpoint +sleeptime=${sleeptime:-12} for i in `jot 10`; do +echo "Loop #$i" (cd $mntpoint; /tmp/syscall4 $* < /dev/null) & - sleep 180 + [ $# -eq 1 ] && sleep $sleeptime || sleep 180 killall -9 syscall4 ipcs | awk '/^(q|m|s)/ {print " -" $1, $2}' | xargs -L 1 ipcrm done @@ -287,7 +289,7 @@ main(int argc, char **argv) for (j = 0; j < 50; j++) pthread_join(cp[j], NULL); - exit(0); + _exit(0); } wait(NULL); } From owner-svn-src-user@FreeBSD.ORG Sat Sep 21 09:17:14 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id EAD48CC0; Sat, 21 Sep 2013 09:17:14 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id D8B6B2348; Sat, 21 Sep 2013 09:17:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8L9HEvq088233; Sat, 21 Sep 2013 09:17:14 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8L9HEPB088232; Sat, 21 Sep 2013 09:17:14 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201309210917.r8L9HEPB088232@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Sat, 21 Sep 2013 09:17:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255758 - user/des/tinderbox X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Sep 2013 09:17:15 -0000 Author: des Date: Sat Sep 21 09:17:14 2013 New Revision: 255758 URL: http://svnweb.freebsd.org/changeset/base/255758 Log: %INITIAL_CONFIG contains arrayrefs, so we need to deep-clone it into %CONFIG; otherwise, modifying e.g. %CONFIG{ENV} will actually modify %INITIAL_CONFIG{ENV} and thereby contaminate the next job. Modified: user/des/tinderbox/tbmaster.pl Modified: user/des/tinderbox/tbmaster.pl ============================================================================== --- user/des/tinderbox/tbmaster.pl Sat Sep 21 04:11:51 2013 (r255757) +++ user/des/tinderbox/tbmaster.pl Sat Sep 21 09:17:14 2013 (r255758) @@ -32,6 +32,7 @@ use strict; use Fcntl qw(:DEFAULT :flock); use POSIX; use Getopt::Long; +use Storable qw(dclone); my $VERSION = "2.10"; my $COPYRIGHT = "Copyright (c) 2003-2012 Dag-Erling Smørgrav. " . @@ -147,7 +148,7 @@ sub expand($) { # sub clearconf() { - %CONFIG = %INITIAL_CONFIG; + %CONFIG = %{dclone(\%INITIAL_CONFIG)}; } # From owner-svn-src-user@FreeBSD.ORG Sat Sep 21 22:11:10 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 276B1619; Sat, 21 Sep 2013 22:11:10 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 159282B86; Sat, 21 Sep 2013 22:11:10 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8LMB9Dt005362; Sat, 21 Sep 2013 22:11:09 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8LMB9A1005361; Sat, 21 Sep 2013 22:11:09 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201309212211.r8LMB9A1005361@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Sat, 21 Sep 2013 22:11:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255771 - user/des/tinderbox/www X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Sep 2013 22:11:10 -0000 Author: des Date: Sat Sep 21 22:11:09 2013 New Revision: 255771 URL: http://svnweb.freebsd.org/changeset/base/255771 Log: Support variant builds, where everything after the first hyphen in the config name (except for an optional -build suffix) indicates a variant. Modified: user/des/tinderbox/www/index.cgi Modified: user/des/tinderbox/www/index.cgi ============================================================================== --- user/des/tinderbox/www/index.cgi Sat Sep 21 22:10:02 2013 (r255770) +++ user/des/tinderbox/www/index.cgi Sat Sep 21 22:11:09 2013 (r255771) @@ -84,10 +84,10 @@ sub do_config($) { my %branches = %{$CONFIGS{$config}}; - my $prettyconfig = $config; - $prettyconfig =~ s/^(.*?)-build$/$1/; + $config =~ m/^(\w+)((?:-\w+)*?)(-build)?$/; + my $variant = join(' ', split('-', $2)); print " - $prettyconfig +   "; foreach my $arch (sort(keys(%ARCHES))) { foreach my $machine (sort(keys(%{$ARCHES{$arch}}))) { @@ -108,7 +108,7 @@ sub do_config($) { $prettybranch =~ s@^RELENG_(\d+)_(\d+)$@/releng/$1.$2@; $prettybranch =~ s@^RELENG_(\d+)$@/stable/$1@; print " - $prettybranch + $prettybranch$variant "; foreach my $arch (sort(keys(%ARCHES))) { foreach my $machine (sort(keys(%{$ARCHES{$arch}}))) { From owner-svn-src-user@FreeBSD.ORG Sat Sep 21 22:12:10 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 352E86FF; Sat, 21 Sep 2013 22:12:10 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 142BB2B8D; Sat, 21 Sep 2013 22:12:10 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r8LMC9i9006269; Sat, 21 Sep 2013 22:12:09 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r8LMC9nc006261; Sat, 21 Sep 2013 22:12:09 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201309212212.r8LMC9nc006261@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Sat, 21 Sep 2013 22:12:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r255772 - user/des/tinderbox X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 21 Sep 2013 22:12:10 -0000 Author: des Date: Sat Sep 21 22:12:09 2013 New Revision: 255772 URL: http://svnweb.freebsd.org/changeset/base/255772 Log: It makes a lot more sense to read site.rc after the config than before it. This allows site.rc to override existing settings, e.g. disable email reports by clearing RECIPIENTS. Also bump version and copyright. Modified: user/des/tinderbox/tbmaster.1 user/des/tinderbox/tbmaster.pl user/des/tinderbox/tinderbox.pl Modified: user/des/tinderbox/tbmaster.1 ============================================================================== --- user/des/tinderbox/tbmaster.1 Sat Sep 21 22:11:09 2013 (r255771) +++ user/des/tinderbox/tbmaster.1 Sat Sep 21 22:12:09 2013 (r255772) @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2003-2012 Dag-Erling Smørgrav +.\" Copyright (c) 2003-2013 Dag-Erling Smørgrav .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 18, 2012 +.Dd September 22, 2013 .Dt TBMASTER 1 .Os .Sh NAME @@ -94,8 +94,9 @@ attempts to read .Pa default.rc and .Pa site.rc -before reading the actual configuration file; thus, these files may be -used to specify default values shared by multiple configurations. +before and after the actual configuration file, respectively; thus, +they can be used to specify default values shared by multiple +configurations. .Pp The configuration consists of a list of single- or multiple-value variable assignments: Modified: user/des/tinderbox/tbmaster.pl ============================================================================== --- user/des/tinderbox/tbmaster.pl Sat Sep 21 22:11:09 2013 (r255771) +++ user/des/tinderbox/tbmaster.pl Sat Sep 21 22:12:09 2013 (r255772) @@ -1,6 +1,6 @@ #!/usr/bin/perl -Tw #- -# Copyright (c) 2003-2012 Dag-Erling Smørgrav +# Copyright (c) 2003-2013 Dag-Erling Smørgrav # All rights reserved. # # Redistribution and use in source and binary forms, with or without @@ -34,8 +34,8 @@ use POSIX; use Getopt::Long; use Storable qw(dclone); -my $VERSION = "2.10"; -my $COPYRIGHT = "Copyright (c) 2003-2012 Dag-Erling Smørgrav. " . +my $VERSION = "2.11"; +my $COPYRIGHT = "Copyright (c) 2003-2013 Dag-Erling Smørgrav. " . "All rights reserved."; my $BACKLOG = 8; @@ -518,9 +518,9 @@ sub tbmaster($) { clearconf(); readconf('default.rc'); - readconf('site.rc'); readconf("$config.rc") or die("$config.rc: $!\n"); + readconf('site.rc'); $CONFIG{'CONFIG'} = $config; $CONFIG{'ETCDIR'} = $etcdir; Modified: user/des/tinderbox/tinderbox.pl ============================================================================== --- user/des/tinderbox/tinderbox.pl Sat Sep 21 22:11:09 2013 (r255771) +++ user/des/tinderbox/tinderbox.pl Sat Sep 21 22:12:09 2013 (r255772) @@ -1,6 +1,6 @@ #!/usr/bin/perl -Tw #- -# Copyright (c) 2003-2012 Dag-Erling Smørgrav +# Copyright (c) 2003-2013 Dag-Erling Smørgrav # All rights reserved. # # Redistribution and use in source and binary forms, with or without @@ -33,7 +33,7 @@ use Fcntl qw(:DEFAULT :flock); use POSIX; use Getopt::Long; -my $VERSION = "2.10"; +my $VERSION = "2.11"; my $COPYRIGHT = "Copyright (c) 2003-2012 Dag-Erling Smørgrav. " . "All rights reserved.";