Return-Path: X-Original-To: apmail-hadoop-mapreduce-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-mapreduce-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 3ACB311BCD for ; Sat, 23 Aug 2014 00:40:11 +0000 (UTC) Received: (qmail 20713 invoked by uid 500); 23 Aug 2014 00:40:01 -0000 Delivered-To: apmail-hadoop-mapreduce-user-archive@hadoop.apache.org Received: (qmail 20594 invoked by uid 500); 23 Aug 2014 00:40:01 -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 20584 invoked by uid 99); 23 Aug 2014 00:40:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 23 Aug 2014 00:40:01 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of shahab.yunus@gmail.com designates 209.85.215.47 as permitted sender) Received: from [209.85.215.47] (HELO mail-la0-f47.google.com) (209.85.215.47) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 23 Aug 2014 00:39:56 +0000 Received: by mail-la0-f47.google.com with SMTP id mc6so10572091lab.20 for ; Fri, 22 Aug 2014 17:39:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=ci+SorYTjV/Vdr9l0hzLDGw5SQq8qPWmBoqMpNT+axc=; b=Dv7jw0y9djR9tJijcZ8fegEFj5u5BA3NSVWVg6gDb/RB/NidHH/TbnjVbC+tzoBeFe N87vNit+mUdc9ygrXNsQg/U09fAWRQOuL4qc8Z0uKL+r0KZc4BIkJ1D/Vw98c0jheiHO lzMsls6SONHZBnvY5GYmnD1GhyA2T2UDEhZEjnwQlRH+07FKVmxAfa+LVY6ke4mRYbjY lL1Jj4r4xRTmkBdluMlW4uJq4JZ6jfsqtXrPIOVmnQtaoSkr6ifSbKYpAom2HoDsZ2tU xTezMg84YOBMokwBKlurEMARREYnniMbLr8/o/ZtPRtJkODaNTFhD7khnxFRxVrK3Bme gVvQ== MIME-Version: 1.0 X-Received: by 10.152.5.194 with SMTP id u2mr7342945lau.68.1408754374756; Fri, 22 Aug 2014 17:39:34 -0700 (PDT) Received: by 10.25.33.80 with HTTP; Fri, 22 Aug 2014 17:39:34 -0700 (PDT) In-Reply-To: References: Date: Fri, 22 Aug 2014 20:39:34 -0400 Message-ID: Subject: Re: job.getCounters returns null in Yarn-based job From: Shahab Yunus To: "user@hadoop.apache.org" Content-Type: multipart/alternative; boundary=089e013d173a154f0305014130e7 X-Virus-Checked: Checked by ClamAV on apache.org --089e013d173a154f0305014130e7 Content-Type: text/plain; charset=UTF-8 For those who are interested, this got resolved. The issue was that I was creating more counters than what was configured in the settings. I upped mapreduce.job.counters.max property to a larger number. The default was 120. The job finishes now and I am able to print and get counters as well. One minor thing that now the job history UI does not show the history with the error message that max counter increased. Regards, Shahab On Fri, Aug 22, 2014 at 7:59 AM, Shahab Yunus wrote: > Hello. > > I am trying to access custom counters that I have created in an mapreduce > job on Yarn. > > After job.waitForCompletion(true) call, I try to do job.getCounters() but > I get a null. > > This only happens if I run a heavy job meaning a) a lot of data and b) lot > of reducers. > > E.g. for 10million records with 20 reducers on a 10 node cluster it works. > But on 60million records with 70 reducers on a 10 node cluster it doesn't. > > The job itself competes successfully. > > I did see the following related JIRAs. But the first one is for old > version, pre-Yarn and those properties I think are not valid anymore. > > The second one does not seem to provide a solution? I tried using the > suggested trick on the client side but no success there either. > > MAPREDUCE-1920 > MAPREDUCE-4442 > > Please advise, how can I retrieve my custom counters after jobs > completion. Am I missing something? Do I need to configure some job history > stuff? I do a mention of ATS as well but I don't know how much that is > applicable here. > > Thanks a lot. > > My version is: 2.3.0-cdh5.1.0 > > Regards, > Shahab > --089e013d173a154f0305014130e7 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
For those who are interested, this got resolved.

<= /div>
The issue was that I was creating more counters than what was con= figured in the settings.
I upped mapreduce.job.counters.max prope= rty to a larger number. The default was 120.

The job finishes now and I am able to print and get cou= nters as well.

One minor thing that now the job hi= story UI does not show the history with the error message that max counter = increased.

Regards,
Shahab


On Fri, Aug 22, 2014 at 7:59 AM= , Shahab Yunus <shahab.yunus@gmail.com> wrote:
Hello.

I= am trying to access custom counters that I have created in an mapreduce jo= b on Yarn.

After job.waitForCompletion(true) call, I try to do job= .getCounters() but I get a null.

This only happens if I run a heavy job meaning a) a lot= of data and b) lot of reducers.

E.g. for 10millio= n records with 20 reducers on a 10 node cluster it works. But on 60million = records with 70 reducers on a 10 node cluster it doesn't.=C2=A0

The job itself competes successfully.

I did see the following related JIRAs. But the first one is for old= version, pre-Yarn and those properties I think are not valid anymore.

The second one does not seem to provide a solution? I t= ried using the suggested trick on the client side but no success there eith= er.


Please advise, how= can I retrieve my custom counters after jobs completion. Am I missing some= thing? Do I need to configure some job history stuff? =C2=A0I do a mention = of ATS as well but I don't know how much that is applicable here.

Thanks a lot.

My version i= s:=C2=A02.3.0-cdh5.1.0

Regards,
Shahab

--089e013d173a154f0305014130e7--