From owner-freebsd-arch@FreeBSD.ORG Sun Jun 25 21:40:26 2006 Return-Path: X-Original-To: freebsd-arch@freebsd.org Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A1A2216A413 for ; Sun, 25 Jun 2006 21:40:26 +0000 (UTC) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (gate.funkthat.com [69.17.45.168]) by mx1.FreeBSD.org (Postfix) with ESMTP id 09A7F43D5A for ; Sun, 25 Jun 2006 21:40:24 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (xq3p58a0nzedktv4@localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.13.6/8.13.3) with ESMTP id k5PLeLmN019021; Sun, 25 Jun 2006 14:40:21 -0700 (PDT) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.13.6/8.13.3/Submit) id k5PLeLJt019020; Sun, 25 Jun 2006 14:40:21 -0700 (PDT) (envelope-from jmg) Date: Sun, 25 Jun 2006 14:40:21 -0700 From: John-Mark Gurney To: Andrew Reilly Message-ID: <20060625214021.GJ82074@funkthat.com> Mail-Followup-To: Andrew Reilly , freebsd-arch@freebsd.org References: <20060625011746.GC81052@duncan.reilly.home> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060625011746.GC81052@duncan.reilly.home> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-RELEASE-p6 i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: freebsd-arch@freebsd.org Subject: Re: What's up with our stdout? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Jun 2006 21:40:26 -0000 Andrew Reilly wrote this message on Sun, Jun 25, 2006 at 11:17 +1000: > One interesting problem that I found yesterday was that NetBSD > have added a "-l" option to cat, which is supposed to apply an > exclusive advisory lock with fcntl to the the output file, and > wait until that succeeds: > http://netbsd.gw.com/cgi-bin/man-cgi?cat++NetBSD-current > That seems like a pretty useful idea, > because it means that you can have parallel make jobs all > contributing to a log file or the like (with cat -l >> foo.log), > without getting in eachothers' way. Why not use: lockf -k foo.log cat >> foo.log Should do the same thing... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not."