X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 731B7D70AA for ; Thu, 1 Sep 2005 11:03:58 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 16829-08 for ; Thu, 1 Sep 2005 14:03:53 +0000 (GMT) Received: from thor.netera.se (thor.netera.se [85.112.172.11]) by svr1.postgresql.org (Postfix) with ESMTP id 83262D7954 for ; Thu, 1 Sep 2005 11:03:51 -0300 (ADT) Received: from [192.168.2.240] (1-1-1-41a.o.sth.bostream.se [81.26.246.14]) by thor.netera.se (Postfix) with ESMTP id 486A513AC01C; Thu, 1 Sep 2005 16:03:55 +0200 (CEST) Message-ID: <43170ADA.2080002@relevanttraffic.se> Date: Thu, 01 Sep 2005 16:06:18 +0200 From: Ulrich Wisser Organization: Relevant Traffic AB User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Merlin Moncure Cc: pgsql-performance@postgresql.org Subject: Re: Need for speed 3 References: <6EE64EF3AB31D5448D0007DD34EEB3417DD24C@Herge.rcsinc.local> In-Reply-To: <6EE64EF3AB31D5448D0007DD34EEB3417DD24C@Herge.rcsinc.local> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.001 required=5 tests=[AWL=0.001] X-Spam-Level: X-Archive-Number: 200509/6 X-Sequence-Number: 14314 Hi Merlin, > schemas would be helpful. right now I would like to know if my approach to the problem makes sense. Or if I should rework the whole procedure of import and aggregate. > Just a thought: have you considered having apache logs write to a > process that immediately makes insert query(s) to postgresql? Yes we have considered that, but dismissed the idea very soon. We need Apache to be as responsive as possible. It's a two server setup with load balancer and failover. Serving about ones thousand domains and counting. It needs to be as failsafe as possible and under no circumstances can any request be lost. (The click counting is core business and relates directly to our income.) That said it seemed quite save to let Apache write logfiles. And import them later. By that a database downtime wouldn't be mission critical. > You could write small C program which executes advanced query interface > call to the server. How would that improve performance? Ulrich