From owner-freebsd-performance@FreeBSD.ORG Wed Dec 7 18:41:18 2005 Return-Path: X-Original-To: freebsd-performance@freebsd.org Delivered-To: freebsd-performance@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 56CF316A429 for ; Wed, 7 Dec 2005 18:41:18 +0000 (GMT) (envelope-from sean@sean.gigave.com) Received: from mailhost.gigave.com (mailhost.gigave.com [38.113.228.14]) by mx1.FreeBSD.org (Postfix) with ESMTP id 80F8543DA5 for ; Wed, 7 Dec 2005 18:41:04 +0000 (GMT) (envelope-from sean@sean.gigave.com) Date: Wed, 7 Dec 2005 10:41:03 -0800 From: Sean Chittenden To: Imri Zvik Message-ID: <20051207184103.GD56998@sean.gigave.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Cc: freebsd-performance@freebsd.org Subject: Re: very busy syslog server X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Dec 2005 18:41:18 -0000 > I'm trying to setup a syslog server to serve a large group of > servers. For the syslog daemon, I have chosen rsyslogd, and the > backend is mysql (on a different machine). > > The machine has 2 Intel Xeon 2.80GHz CPUs, and 1GB of RAM, and it is > running FreeBSD 6 (6.0-STABLE). > > The problem is, that I see a lot of UDP packets being dropped: > > udp: > 390202 datagrams received > 0 with incomplete header > 0 with bad data length field > 0 with bad checksum > 6 with no checksum > 0 dropped due to no socket > 0 broadcast/multicast datagrams dropped due to no socket > ->>> 123677 dropped due to full socket buffers > 0 not for hashed pcb > 266525 delivered > 133260 datagrams output > > I have tried to increase net.inet.udp.recvspace, but it didn't solve > the problem. > > I would appreciate any hint or tips. When you're doing a large number of packets per second, you may want to look into enabling device polling(4). Right now, every packet results in an interrupt. With device polling, you can handle more than one packet per interrupt. See the man page for details. If your syslogd's are blocking, waiting for the MySQL INSERT to complete, you may be dropping UDP packets and polling won't help you. I'd write messages out to a file then process them once a minute. *shrug* -sc -- Sean Chittenden