Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YHNNT-0000Zh-0A for pgsql-performance@arkaria.postgresql.org; Sat, 31 Jan 2015 02:01:39 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1YHNNS-0007mF-1a for pgsql-performance@arkaria.postgresql.org; Sat, 31 Jan 2015 02:01:38 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1YHNNR-0007m9-8S for pgsql-performance@postgresql.org; Sat, 31 Jan 2015 02:01:37 +0000 Received: from mail-bn1bon0668.outbound.protection.outlook.com ([2a01:111:f400:fc10::1:668] helo=na01-bn1-obe.outbound.protection.outlook.com) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1YHNNM-0002TJ-U4 for pgsql-performance@postgresql.org; Sat, 31 Jan 2015 02:01:36 +0000 Received: from decina.local (24.55.12.91) by BY1PR11MB0341.namprd11.prod.outlook.com (25.160.206.154) with Microsoft SMTP Server (TLS) id 15.1.75.20; Sat, 31 Jan 2015 02:01:24 +0000 Message-ID: <54CC376C.9070508@BlueTreble.com> Date: Fri, 30 Jan 2015 20:01:16 -0600 From: Jim Nasby User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: "Cassiano, Marco" , "pgsql-performance@postgresql.org" Subject: Re: Performance of Postgresql Foreign Data Wrapper References: <1361CEF686657C41A139AD8C3145632B44B33A8F@E2010-MB1.manord.com> In-Reply-To: <1361CEF686657C41A139AD8C3145632B44B33A8F@E2010-MB1.manord.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [24.55.12.91] X-ClientProxiedBy: BY1PR00CA0030.namprd00.prod.outlook.com (25.160.102.40) To BY1PR11MB0341.namprd11.prod.outlook.com (25.160.206.154) Authentication-Results: postgresql.org; dkim=none (message not signed) header.d=none; X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;SRVR:BY1PR11MB0341; X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004); SRVR:BY1PR11MB0341; X-Forefront-PRVS: 0473A03F3F X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(24454002)(377454003)(479174004)(51704005)(50466002)(23746002)(40100003)(76176999)(92566002)(33656002)(15975445007)(62966003)(36756003)(77156002)(65806001)(2950100001)(122386002)(83506001)(54356999)(87266999)(19580395003)(42186005)(50986999)(65816999)(64126003)(46102003)(86362001)(47776003)(87976001)(66066001)(59896002)(65956001)(107886001)(85282002)(336755003)(18886065003); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR11MB0341; H:decina.local; FPR:; SPF:None; MLV:sfv; LANG:en; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:BY1PR11MB0341; X-OriginatorOrg: bluetreble.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Jan 2015 02:01:24.9561 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR11MB0341 X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-performance Precedence: bulk Sender: pgsql-performance-owner@postgresql.org On 1/14/15 10:48 AM, Cassiano, Marco wrote: > Both query were issued repeatedly to get rid of disk access and database > connection overhead time. > > Activating duration and statement logging on the remote server I can see > that the query issued through the fdw from the LOCAL SERVER > > is actually performed by opening a cursor : I don't think the cursor is the issue here, but can you try running those same commands directly on the remote server to make sure? It looks like it's the fetch itself that's slow, which makes me wonder if there's some network or other problem. -- Jim Nasby, Data Architect, Blue Treble Consulting Data in Trouble? Get it in Treble! http://BlueTreble.com -- Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance