Return-Path: X-Original-To: apmail-hive-user-archive@www.apache.org Delivered-To: apmail-hive-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id ECE6EC1CB for ; Tue, 2 Dec 2014 02:12:57 +0000 (UTC) Received: (qmail 87389 invoked by uid 500); 2 Dec 2014 02:12:55 -0000 Delivered-To: apmail-hive-user-archive@hive.apache.org Received: (qmail 87303 invoked by uid 500); 2 Dec 2014 02:12:55 -0000 Mailing-List: contact user-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hive.apache.org Delivered-To: mailing list user@hive.apache.org Received: (qmail 87293 invoked by uid 99); 2 Dec 2014 02:12:55 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 02 Dec 2014 02:12:55 +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 nagarjuna.viss@gmail.com designates 209.85.220.176 as permitted sender) Received: from [209.85.220.176] (HELO mail-vc0-f176.google.com) (209.85.220.176) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 02 Dec 2014 02:12:51 +0000 Received: by mail-vc0-f176.google.com with SMTP id hq12so5197864vcb.7 for ; Mon, 01 Dec 2014 18:11:45 -0800 (PST) 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=SHhgotSpem0AHCYTiyiosOTrTxi8R7+2yFXzwFCLWi0=; b=eDbGNeaPglMk8ZCTohgsi7y4AoS5LyiUwKnZ4f4+ynbA66b6G55+cpq2FowZtgF4gU tfOt4KZNqXs5vxmcQz6mkD/QDk5vzbT2P4+9Pr0/xmFbqPj11WT9qTAxKgI6Kxyg1oyK +t7WMpQwvUPumiv2ulpKcYhgRLk5+ltNtoVMv5gPc9VcDIw/WCfG8oLmamfR6vThcjrS QKh3sNegt6lXdd5jq/Hjv4hC0z9HVsmOlNkJcRSD1WQpQDWgPvfejL38IvzyVLdBGnRu 4y/5BZBy+U04/byK6IYBuUjASSfPv20rCfsQTV2jakjIt2jIujlpRRow3VdqO1folY5Z ouEA== MIME-Version: 1.0 X-Received: by 10.52.12.234 with SMTP id b10mr1535629vdc.0.1417486305775; Mon, 01 Dec 2014 18:11:45 -0800 (PST) Received: by 10.31.142.149 with HTTP; Mon, 1 Dec 2014 18:11:45 -0800 (PST) Received: by 10.31.142.149 with HTTP; Mon, 1 Dec 2014 18:11:45 -0800 (PST) In-Reply-To: References: Date: Tue, 2 Dec 2014 07:41:45 +0530 Message-ID: Subject: Re: dynamic partitioning issues in hive 0.13.0 From: Nagarjuna Vissarapu To: user@hive.apache.org Content-Type: multipart/alternative; boundary=20cf302ef9f8bad4590509323f84 X-Virus-Checked: Checked by ClamAV on apache.org --20cf302ef9f8bad4590509323f84 Content-Type: text/plain; charset=ISO-8859-1 Can you please check you mysql service which stores metada On Dec 2, 2014 4:18 AM, "Viral Bajaria" wrote: > Hi, > > I have been running into 2 issues with dynamic partitioning queries. > > The query runs fine and I get errors like: > > *Failed with exception > MetaException(message:javax.jdo.JDODataStoreException: Insert of object > "org.apache.hadoop.hive.metastore.model.MPartition@5bbd373e" using > statement "INSERT INTO `PARTITIONS` > (`PART_ID`,`LAST_ACCESS_TIME`,`TBL_ID`,`SD_ID`,`CREATE_TIME`,`PART_NAME`) > VALUES (?,?,?,?,?,?)" failed : Deadlock found when trying to get lock; try > restarting transaction* > > Detailed exception: https://gist.github.com/vbajaria/aead8eb4597f31df4807 > > Why would there be a deadlock on adding a new partition info to the > metastore ? It seems weird that would even happen given that the partition > did not even exist prior to this query run. > > I am thinking it could be an issue because I have 100s of such queries > running and the INDEX on that table might be causing the issue ? > > > The 2nd issue is more painful. After the 1st error mentioned above, I have > a process which figures out what failed and then re-runs the data for that > month. After the query finishes successfully, it ends up adding only 1 > partition instead of partition for each day in that month. If I run the > query manually and look at the data returned then it returns data for all > partitions, yet for some reason dynamic partition does not ad all. The > query is an "INSERT OVERWRITE" query. > > In the end I have to drop all partitions for that month before re-running > the query and then everything works fine. Without that the partitions that > were missed on first attempt don't show up. > > The missing partitions are in itself a mystery. > > Any points on how to debug this ? > > Thanks, > Viral > > > --20cf302ef9f8bad4590509323f84 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

Can you please check you mysql service which stores metada

On Dec 2, 2014 4:18 AM, "Viral Bajaria"= ; <viral.bajaria@gmail.com> wrote:
Hi,

I have been running into 2 issues with dyn= amic partitioning queries.

The query runs fine and= I get errors like:

Failed with exception = MetaException(message:javax.jdo.JDODataStoreException: Insert of object &qu= ot;org.apache.hadoop.hive.metastore.model.MPartition@5bbd373e" using s= tatement "INSERT INTO `PARTITIONS` (`PART_ID`,`LAST_ACCESS_TIME`,`TBL_= ID`,`SD_ID`,`CREATE_TIME`,`PART_NAME`) VALUES (?,?,?,?,?,?)" failed : = Deadlock found when trying to get lock; try restarting transaction


Why would= there be a deadlock on adding a new partition info to the metastore ? It s= eems weird that would even happen given that the partition did not even exi= st prior to this query run.

I am thinking it could= be an issue because I have 100s of such queries running and the INDEX on t= hat table might be causing the issue ?


<= div>The 2nd issue is more painful. After the 1st error mentioned above, I h= ave a process which figures out what failed and then re-runs the data for t= hat month. After the query finishes successfully, it ends up adding only 1 = partition instead of partition for each day in that month. If I run the que= ry manually and look at the data returned then it returns data for all part= itions, yet for some reason dynamic partition does not ad all. The query is= an "INSERT OVERWRITE" query.

In the end= I have to drop all partitions for that month before re-running the query a= nd then everything works fine. Without that the partitions that were missed= on first attempt don't show up.

The missing p= artitions are in itself a mystery.

Any points on h= ow to debug this ?

Thanks,
Viral


--20cf302ef9f8bad4590509323f84--