Return-Path: X-Original-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 12BE8E92E for ; Mon, 14 Jan 2013 02:06:05 +0000 (UTC) Received: (qmail 44416 invoked by uid 500); 14 Jan 2013 02:06:00 -0000 Delivered-To: apmail-hadoop-hdfs-user-archive@hadoop.apache.org Received: (qmail 44241 invoked by uid 500); 14 Jan 2013 02:05:59 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 44233 invoked by uid 99); 14 Jan 2013 02:05:59 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Jan 2013 02:05:59 +0000 X-ASF-Spam-Status: No, hits=-3.3 required=5.0 tests=DEAR_SOMETHING,RCVD_IN_DNSWL_HI,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [192.55.52.88] (HELO mga01.intel.com) (192.55.52.88) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 14 Jan 2013 02:05:54 +0000 Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga101.fm.intel.com with ESMTP; 13 Jan 2013 18:05:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.84,465,1355126400"; d="scan'208";a="273344082" Received: from fmsmsx104.amr.corp.intel.com ([10.19.9.35]) by fmsmga001.fm.intel.com with ESMTP; 13 Jan 2013 18:05:32 -0800 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX104.amr.corp.intel.com (10.19.9.35) with Microsoft SMTP Server (TLS) id 14.1.355.2; Sun, 13 Jan 2013 18:05:31 -0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.85]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.74]) with mapi id 14.01.0355.002; Mon, 14 Jan 2013 10:05:25 +0800 From: "Chen, Haifeng" To: "user@hadoop.apache.org" Subject: RE: Some mappers are much slower than others in reading data from HDFS Thread-Topic: Some mappers are much slower than others in reading data from HDFS Thread-Index: Ac3tTUbrGnKMGldGSWOTl57LrCSEjQAWSqyAART0hqA= Date: Mon, 14 Jan 2013 02:05:25 +0000 Message-ID: <3E657120E422654A9EB626F537B8AA910FDB9214@SHSMSX102.ccr.corp.intel.com> References: <3E657120E422654A9EB626F537B8AA910FDB5622@SHSMSX102.ccr.corp.intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org Thank for your response, Andy. I think node2 has more mappers than others because the mappers on node2 mov= e on faster and finish earlier than the mappers on node3 and node4. When th= e first wave of mappers on node2 (00018, 00019, ...) finished and there are= more mappers to run, then the resource manager allocated another wave of t= he mappers to node2 (00025, 00026, ...). And still, the mappers on node2 ar= e the ones runs fastest. Is it possible that it is because of cache distribution(disk cache?) Does d= ata node hold any cache of recently accessed data? Regards, Haifeng -----Original Message----- From: Andy Isaacson [mailto:adi@cloudera.com]=20 Sent: Wednesday, January 09, 2013 5:46 AM To: user@hadoop.apache.org Subject: Re: Some mappers are much slower than others in reading data from = HDFS Your output shows that node2 has 13 mappers and the reducer, while node3 and node4 had only 8 mappers each. So I'd expect some disparity. Since it's hard to correlate the mapper throughput against the reducer throughput, it's possible that node3 got just as much work done. That doesn't explain why node4 is slower than node3, though. -andy On Mon, Jan 7, 2013 at 7:07 PM, Chen, Haifeng wrot= e: > Dear sir, > > I encountered a strange problem that all the mappers on some nodes are mu= ch > slower than the mappers on other nodes as following some times (not alway= s). > I didn't see any reasons why they should slow down in this pattern. > > > > 000013(MAP on node4): --------(8.115) > > 000014(MAP on node4): --------(8.570) > > 000011(MAP on node4): --------(8.5) > > 000016(MAP on node4): --------(8.344) > > 000010(MAP on node4): --------(8.585) > > 000015(MAP on node4): --------(8.179) > > 000017(MAP on node4): --------(8.445) > > 000012(MAP on node4): --------(8.312) > > 000018(MAP on node2): ---(3.367) > > 000020(MAP on node2): ---(3.335) > > 000019(MAP on node2): ---(3.320) > > 000023(MAP on node2): ---(3.91) > > 000022(MAP on node2): ---(3.371) > > 000021(MAP on node2): ---(3.458) > > 000004(MAP on node3): -------------------(19.624) > > 000007(MAP on node3): -------------------(19.92) > > 000005(MAP on node3): --------------------(20.613) > > 000008(MAP on node3): --------------------(20.316) > > 000003(MAP on node3): --------------------(20.574) > > 000006(MAP on node3): --------------------(20.654) > > 000002(MAP on node3): -------------------(19.935) > > 000009(MAP on node3): --------------------(20.489) > > 000025(MAP on node2): --(2.877) > > 000026(MAP on node2): ---(3.112) > > 000027(MAP on node2): --(2.959) > > 000024(MAP on node2): --(2.845) > > 000029(MAP on node2): --(2.863) > > 000028(MAP on node2): --(2.933) > > 000031(MAP on node2): --(2.596) > > 000030(RED on node2): -------------(13.378) > > > > The testing is as following: > > I have a 4 nodes cluster and all of them has the same hardware and softwa= re > configurations. One node acts as name node and yarn resource manager. Ot= her > three nodes act as both data node and yarn node manager. > > > > The test input file is around 7GB file on the HDFS cluster and the > replication number is 3. (This means that each data node has a copy of ev= ery > block of the file) > > > > The mapper did nothing and didn't write out any records: > > > > public static class KeyMapper > > extends Mapper{ > > public void map(Object key, Text value, Context context > > ) throws IOException, InterruptedException { > > > > } > > } > > > > So this mapper logically is reading and iterating through its splits of d= ata > and then finish the job. > > I didn't see any factors in the above configurations that will cause the > above phenomenon. > > I turned on the debug log for each mapper task and it also showed that al= l > the mapper's DFSClient read data from its local data node. > > > > Can any experts help give some hints for this? I attached the log and cli= ent > code for analysis. > > > > Thanks, > > Haifeng