X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id A939CD1B8AC for ; Thu, 28 Aug 2003 18:00:01 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 60572-06 for ; Thu, 28 Aug 2003 14:59:30 -0300 (ADT) Received: from harrier.cohaesio.com (harrier.cohaesio.com [212.97.128.50]) by svr1.postgresql.org (Postfix) with ESMTP id A99A8D1B8E7 for ; Thu, 28 Aug 2003 14:59:29 -0300 (ADT) Received: by harrier.cohaesio.com (Postfix, from userid 88) id 5B39987; Thu, 28 Aug 2003 19:59:10 +0200 (CEST) X-Original-To: news2mail@news.cohaesio.com From: "Anders K. Pedersen" Subject: Re: Queries sometimes take 1000 times the normal time Date: Thu, 28 Aug 2003 19:59:09 +0200 Organization: Cohaesio A/S Lines: 28 Message-ID: References: <1062033258.71328.2.camel@jester> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: harrier.cohaesio.com 1062093549 9649 212.97.128.160 (28 Aug 2003 17:59:09 GMT) X-Complaints-To: newsmaster@news.cohaesio.com X-Accept-Language: da, en-us, en To: pgsql-performance@postgresql.org X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200308/427 X-Sequence-Number: 3243 Rod Taylor wrote: >>Currently there's only a few users in the database for testing purposes, >>and most of the time the user lookup's take 2-3 ms (I have syslog'ing of >>queries and duration turned on), but several times per hour the duration >>for one of the queries is 2-3 seconds (1000 times larger), while the >>surrounding lookups take the usual 2-3 ms. > > Are there any other jobs running at the time of these excessive queries? I don't know if you're referring to jobs inside the PostgreSQL database or just jobs on the server, but I'm pretty sure that nothing major is going on inside the database - the only other job using it is doing an insert whenever one of our game admins executes an administrative command (like ban or kick), but this doesn't happen all that often, and according the PostgreSQL log isn't happening at the same times as the long queries. With regards to other jobs on the server, there is a MySQL server on it as well, which from time to time has some multi-second queries generated from a webserver also on this host, but the MySQL is running with nice 10 (PostgreSQL isn't nice'd). Someone else asked about vmstat results, and I've been running this for a while now, and I will report the results shortly. Regards, Anders K. Pedersen