X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 077DAD1D544 for ; Wed, 14 Jan 2004 03:11:01 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 99185-03 for ; Tue, 13 Jan 2004 23:10:33 -0400 (AST) Received: from mail1.panix.com (mail1.panix.com [166.84.1.72]) by svr1.postgresql.org (Postfix) with ESMTP id B640BD1B44A for ; Tue, 13 Jan 2004 23:10:28 -0400 (AST) Received: from panix1.panix.com (panix1.panix.com [166.84.1.1]) by mail1.panix.com (Postfix) with ESMTP id 5E0BC48825 for ; Tue, 13 Jan 2004 22:10:31 -0500 (EST) Received: (from adler@localhost) by panix1.panix.com (8.11.6p2-a/8.8.8/PanixN1.1) id i0E3AVv29759 for pgsql-admin@postgresql.org; Tue, 13 Jan 2004 22:10:31 -0500 (EST) Date: Tue, 13 Jan 2004 22:10:31 -0500 From: Michael Adler To: pgsql-admin@postgresql.org Subject: vacuum slowed by syslogd Message-ID: <20040114031030.GA18188@pobox.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.1i X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/112 X-Sequence-Number: 11975 On many occasions, I've noticed that some PostgreSQL activity takes far longer than it previously did and that disabling syslogd addresses the symptoms. Most recently, it took 20-60 seconds to VACUUM a small, heavily updated table, while it used to take a fraction of a second. I found syslog entries like these: 13:19:53 --Relation sometable-- 13:20:03 Removed 2 tuples in 1 pages. 13:20:23 ^ICPU 0.00s/0.00u sec elapsed 0.00 sec. 13:20:54 Pages 1: Changed 1, Empty 0; Tup 4: Vac 2, Keep 0, UnUsed 13. 13:20:54 ^ITotal CPU 0.00s/0.00u sec elapsed 60.12 sec. It took almost-exactly 60 seconds, but virtually no CPU time was used (and no disk IO). Many similar examples have "real" times that are near perfect multiples of 10 seconds (e.g. 50.09, 40.07). This is not every single VACUUM, but it is frequent. The problem disappears when syslogd is stopped or when PostgreSQL disables syslog usage. This is very consistent and I can reproduce the problem in some installations by toggling these factors on and off. The other way to toggle the problem on/off is to disable syslogd's udp socket (though this is a feature we'd still like to use). This evidence normally indicates a name resolution issue, but I'm not sure how to test for that beyond using "hostname -v -i". This has happened at several installations. We use both 7.2.1 (Debian stable) and 7.3.2 (Debian testing). I would guess that this is not the result of a PostgreSQL deficiency, but it is most sharply affected by it. Perhaps someone can offer insight? Thanks, Mike Adler