Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 6D9CD9FB79F for ; Sun, 17 Jun 2007 01:30:26 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 78240-09 for ; Sun, 17 Jun 2007 01:30:12 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from vms044pub.verizon.net (vms044pub.verizon.net [206.46.252.44]) by postgresql.org (Postfix) with ESMTP id 9D4D49FB799 for ; Sun, 17 Jun 2007 01:30:22 -0300 (ADT) Received: from new-host-4.home ([72.91.21.73]) by vms044.mailsrvcs.net (Sun Java System Messaging Server 6.2-6.01 (built Apr 3 2006)) with ESMTPA id <0JJR009KVJ6HP2I0@vms044.mailsrvcs.net> for pgsql-hackers@postgresql.org; Sat, 16 Jun 2007 23:30:17 -0500 (CDT) Date: Sun, 17 Jun 2007 00:30:15 -0400 From: Robert Treat Subject: Re: Performance Monitoring In-reply-to: To: pgsql-hackers@postgresql.org Cc: Greg Smith Message-id: <200706170030.16112.xzilla@users.sourceforge.net> MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-transfer-encoding: 7bit Content-disposition: inline References: User-Agent: KMail/1.9.1 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200706/683 X-Sequence-Number: 104472 On Friday 15 June 2007 13:29, Greg Smith wrote: > On Fri, 15 Jun 2007, Umar Farooq wrote: > > Surprisingly, no matter what type of query I execute, when I use strace > > to monitor the system calls generated they turn out to be the same for > > ALL sorts of queries. > > How are you calling strace? The master postgres progress forks off new > processes for each of the clients, you need to make sure you include stats > from all of them as well to get anything. > > I normally use > > strace -c -f -p [main postgres process] > > which is helpful to collecte basic info, but even that's not quite right; > you don't get the work done by the other proceses (logger, writer, stats > collector). To get everything, you need to start some process that you > attach strace to like this, then have that process start the server. > > I haven't found strace to be a great tool for this type of work. You > might take at look at systemtap instead ( > http://sourceware.org/systemtap/wiki ) which is a bit immature but is > going the right direction. > > I will now bow my head and wait for someone to suggest you move to an OS > that supports dtrace. > You know that's what I was thinking :-) -- Robert Treat Build A Brighter LAMP :: Linux Apache {middleware} PostgreSQL