From owner-freebsd-questions@freebsd.org Fri Jul 26 15:10:04 2019 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7257AA30B3 for ; Fri, 26 Jul 2019 15:10:04 +0000 (UTC) (envelope-from jjohnstone.nospamfreebsd@tridentusa.com) Received: from mail.tridentusa.com (mail.tridentusa.com [96.225.19.3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2E5546DA44 for ; Fri, 26 Jul 2019 15:10:02 +0000 (UTC) (envelope-from jjohnstone.nospamfreebsd@tridentusa.com) Received: (qmail 37934 invoked from network); 26 Jul 2019 15:03:21 -0000 Received: from mailout.tridentusa.com (HELO mail.tridentusa.com) (172.16.0.32) de/crypted with TLSv1: DHE-RSA-AES256-SHA [256/256] DN=none by smtprelay.tridentusa.com with ESMTPS; 26 Jul 2019 15:03:21 -0000 Received: (qmail 93846 invoked from network); 26 Jul 2019 11:03:21 -0400 Received: from pool-108-53-192-121.nwrknj.fios.verizon.net (HELO ?192.168.1.156?) (jjohnstone@tridentusa.com@108.53.192.121) by mail.tridentusa.com with SMTP; 26 Jul 2019 11:03:21 -0400 Subject: Re: Help:: Listen queue overflow killing servers To: freebsd-questions@freebsd.org References: <3a62375a-432c-3533-a7bc-e5573c26fa9c@ifdnrg.com> <92866b76-5f11-2523-cc8f-0d92cc91a50e@bytecamp.net> <22f7262b-eda8-f9d1-8836-61bcea8e1c5f@gmail.com> From: John Johnstone Message-ID: <71a77de7-7822-7543-a852-9280316c8aeb@tridentusa.com> Date: Fri, 26 Jul 2019 11:03:22 -0400 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <22f7262b-eda8-f9d1-8836-61bcea8e1c5f@gmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 2E5546DA44 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of jjohnstone.nospamfreebsd@tridentusa.com designates 96.225.19.3 as permitted sender) smtp.mailfrom=jjohnstone.nospamfreebsd@tridentusa.com X-Spamd-Result: default: False [-5.90 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[tridentusa.com]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_TLS_LAST(0.00)[]; MX_GOOD(-0.01)[mail1.tridentusa.com,mail.tridentusa.com]; NEURAL_HAM_SHORT(-0.90)[-0.897,0]; IP_SCORE(-2.69)[ip: (-9.53), ipnet: 96.225.0.0/17(-4.77), asn: 701(0.89), country: US(-0.05)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:701, ipnet:96.225.0.0/17, country:US]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Jul 2019 15:10:04 -0000 On 7/26/19 9:24 AM, MJ wrote: > > On 26/07/2019 11:08 pm, Paul Macdonald via freebsd-questions wrote: >> >> On 26/07/2019 13:52, Robert Schulze wrote: >> One of the things we do (whihc may be bad)  is to log to a single file >> ( e.g all.sites.log, this doesn;t seem to cause problems in general , >> but i can see how if there's X child processes then they may all need >> write locks) >> > Unless it's hammering the log and there's locks on it. > > >> Is that a really bad idea? ( Often handy to have one file for >> differnet vhosts, but maybe that needs a rethink) > > Syslog works this way. With syslog there are multiple processes all their messages to port 514. There is just a single process syslogd which then writes to its files. The situation here seems to be that all.sites.log is opened for writing with shared access by multiple processes which would be different from syslog. Maybe that approach should also be taken here. With any approach, with one log file there is a serialization of everything written to that file. The throughput of the method that does that becomes a limiting factor. Maybe that limit is being reached. - John J.