From owner-freebsd-hackers Thu Aug 17 18:53:11 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.129.65]) by hub.freebsd.org (Postfix) with ESMTP id EFC1D37BC4C for ; Thu, 17 Aug 2000 18:50:59 -0700 (PDT) Received: from rover.village.org (rover.village.org [204.144.255.49]) by mx1.FreeBSD.org (Postfix) with ESMTP id 26D7C6E3D6E for ; Thu, 17 Aug 2000 14:42:08 -0700 (PDT) Received: from harmony.village.org (harmony.village.org [10.0.0.6]) by rover.village.org (8.9.3/8.9.3) with ESMTP id PAA36890; Thu, 17 Aug 2000 15:40:56 -0600 (MDT) (envelope-from imp@harmony.village.org) Received: from harmony.village.org (localhost.village.org [127.0.0.1]) by harmony.village.org (8.9.3/8.8.3) with ESMTP id PAA14347; Thu, 17 Aug 2000 15:40:05 -0600 (MDT) Message-Id: <200008172140.PAA14347@harmony.village.org> To: Karl Pielorz Subject: Re: Critical (or equivalent) section in Userland? Cc: hackers@FreeBSD.ORG In-reply-to: Your message of "Thu, 17 Aug 2000 21:58:41 BST." <399C5201.5B6911CE@tdx.co.uk> References: <399C5201.5B6911CE@tdx.co.uk> <399BA212.A84240AE@tdx.co.uk> <200008171723.LAA12924@harmony.village.org> Date: Thu, 17 Aug 2000 15:40:05 -0600 From: Warner Losh Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message <399C5201.5B6911CE@tdx.co.uk> Karl Pielorz writes: : I don't think advisory locks will work - the other process is sendmail... I : have to keep it from opening any of it's config files, whilst I 'rename' out : of place the old ones (keeping any fd's to them intact) and rename in the new : ones... Don't fight sendmail.... :-) : Killing / stopping the root sendmail doesn't work (as children making multiple : deliveries still apparently open these files at will) - and killing all of : them isn't really an option either (as too many emails will be dropped, this : means junking say, a 90% of the way through 3mb email delivery - only to have : to resend/process it again from scratch). Kill sendmail's root process. That's the best you can do. It won't impact anything, it will prevent the reading of the queue files (and the config files) and the children will just run with the old copies. then you wait for all the children to die (with a reasonable timeout). Then you do your change, then restart sendmail. That's the best you can hope for. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message