From owner-freebsd-questions@FreeBSD.ORG Wed Apr 30 05:55:10 2014 Return-Path: Delivered-To: freebsd-questions@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 ESMTPS id 49547237; Wed, 30 Apr 2014 05:55:10 +0000 (UTC) Received: from relay2.tomsk.ru (mail.sibptus.tomsk.ru [212.73.124.5]) by mx1.freebsd.org (Postfix) with ESMTP id 3CE501131; Wed, 30 Apr 2014 05:55:08 +0000 (UTC) X-Virus-Scanned: by clamd daemon 0.98.1 for FreeBSD at relay2.tomsk.ru Received: from admin.sibptus.tomsk.ru (account sudakov@sibptus.tomsk.ru [212.73.125.240] verified) by relay2.tomsk.ru (CommuniGate Pro SMTP 5.1.16) with ESMTPSA id 35489046; Wed, 30 Apr 2014 12:55:06 +0700 Received: from admin.sibptus.tomsk.ru (sudakov@localhost [127.0.0.1]) by admin.sibptus.tomsk.ru (8.14.7/8.14.7) with ESMTP id s3U5t3Ab057900; Wed, 30 Apr 2014 12:55:06 +0700 (NOVT) (envelope-from vas@mpeks.tomsk.su) Received: (from sudakov@localhost) by admin.sibptus.tomsk.ru (8.14.7/8.14.7/Submit) id s3U5t30u057899; Wed, 30 Apr 2014 12:55:03 +0700 (NOVT) (envelope-from vas@mpeks.tomsk.su) X-Authentication-Warning: admin.sibptus.tomsk.ru: sudakov set sender to vas@mpeks.tomsk.su using -f Date: Wed, 30 Apr 2014 12:55:03 +0700 From: Victor Sudakov To: Colin Percival , freebsd-questions@freebsd.org Subject: Re: Multiple "/usr/sbin/freebsd-update cron" processes Message-ID: <20140430055503.GA56431@admin.sibptus.tomsk.ru> References: <20140430033402.GA51407@admin.sibptus.tomsk.ru> <536085BF.7010707@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <536085BF.7010707@freebsd.org> Organization: AO "Svyaztransneft", SibPTUS X-PGP-Key: http://www.dreamwidth.org/pubkey?user=victor_sudakov X-PGP-Fingerprint: 10E3 1171 1273 E007 C2E9 3532 0DA4 F259 9B5E C634 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Apr 2014 05:55:10 -0000 Colin Percival wrote: > On 04/29/14 20:34, Victor Sudakov wrote: > > I wonder why the "/usr/sbin/freebsd-update cron" process sometimes > > runs in several copies (possibly corrupting the database). > > > > It's started from cron at 6am every day, why should it multiply like > > that? > > The only thing I can think of is if some of those are running inside jails. There are no jails on that host. In fact, there is pretty much nothing on that host (8.4-RELEASE-p7 i386), it is just a slave nameserver for a dozen zones running named from the base system. But even if someone had a crazy idea to run freebsd-update inside a jail (unstead of using the -b option), each process would happily have its own copy of jailed workdir, instead of fighting for the main workdir like this: rm: filelist: No such file or directory cut: INDEX-PRESENT.tmp: No such file or directory join: INDEX-PRESENT.tmp: No such file or directory rm: INDEX-PRESENT.tmp: No such file or directory grep: INDEX-OLD: No such file or directory grep: INDEX-OLD: No such file or directory grep: INDEX-OLD: No such file or directory grep: INDEX-OLD: No such file or directory grep: INDEX-OLD: No such file or directory comm: INDEX-OLD: No such file or directory sort: open failed: INDEX-OLD: No such file or directory -- Victor Sudakov, VAS4-RIPE, VAS47-RIPN sip:sudakov@sibptus.tomsk.ru