Re: hive permissions issue on a database

2012-10-01 Thread Sriram Krishnan
In general, Hive authorization is not very secure, as is documented on the wiki: https://cwiki.apache.org/confluence/display/Hive/LanguageManual+Authorization. You are likely running into this issue: https://issues.apache.org/jira/browse/HIVE-2538. Try this as user demo2: "use demo1db; drop ta

Re: Error while reading from task log url

2012-07-20 Thread Sriram Krishnan
What version of Hadoop and Hive are you using? We have seen errors like this in the past – and you can actually replace taskid with attemptid to fetch your logs. So try this: http://lvsaishdc3dn0857.lvs.ebay.com:50060/tasklog?attemptid=attempt_201207172005_14407_r_00_1&all=true But yes, th

Re: HIVE and S3 via EMR?

2012-05-29 Thread Sriram Krishnan
Currently EMR only supports Hive versions 0.7.x AFAIK. Russell, you may have to use Florin's suggestion – however, since your table is not partitioned, you will have to use something like "alter table set location". Note that this will change the location of your Hive table from its default loc

Re: Hive Security

2012-01-31 Thread Sriram Krishnan
I was under the impression that Toad uses JDBC – and AFAIK there is no way to authenticate users via JDBC using the HiveServer. FYI - https://issues.apache.org/jira/browse/HIVE-2539. BTW if anyone has a solution to this, I would be very interested to know as well. Sriram From: Shantian Purkad

Re: Joining between table of different databases

2012-01-31 Thread Sriram Krishnan
Yes, you can do it :). Are you having any problems doing it – if so, what are the errors you are seeing? You should be able to use db.table_name in your joins. HiveQL doesn't seem to like db.table_name.column notation – so you may have to use "db.table_name as foo", and foo.column instead. Othe

Re: move tables into different database

2012-01-30 Thread Sriram Krishnan
On Tue, Jan 31, 2012 at 7:22 AM, Matt Tucker mailto:matthewt...@gmail.com>> wrote: Someone recently posted a command to convert a managed table to an external table. If you also use that command, there's no expensive copy operation. You'd probably want to move the data into a dif

Re: move tables into different database

2012-01-30 Thread Sriram Krishnan
t; Reply-To: mailto:user@hive.apache.org>> Date: Mon, 30 Jan 2012 16:32:03 -0800 To: mailto:user@hive.apache.org>> Subject: Re: move tables into different database If you are on hdfs How about-- use db1; create table table1 like db2.table1; and move the data? Thanks, Aniket On Mon, Jan 30,

Re: move tables into different database

2012-01-30 Thread Sriram Krishnan
AFAIK there is no way in HiveQL to do this. We had a similar requirement in the past, and we wrote a shell script to update the MySQL metastore directly (obviously not the cleanest or recommended way to go). Cheers, Sriram From: hadoop hive mailto:hadooph...@gmail.com>> Reply-To: mailto:user@hi

Re: Mysql metastore configuration error.

2011-11-22 Thread Sriram Krishnan
r@hive.apache.org>> Cc: Sriram Krishnan mailto:skrish...@netflix.com>> Subject: RE: Mysql metastore configuration error. I checked the TBLS table. It contains an entry for abcd. About Hadoop only jobs. Yes I ran examples provided with Hadoop which don’t use hive at all. They ran fin

Re: Mysql metastore configuration error.

2011-11-21 Thread Sriram Krishnan
Hive tables do not have a 1-1 mapping to tables in MySQL. In other words, your hive table "abcd" will NOT be a table within the MySQL "metastore" database. If you want to see what is going on in the MySQL metastore, you can do the following: mysql> use metastore; mysql> show tables; You should

Re: Handling hyphens in table/database/usernames

2011-11-01 Thread Sriram Krishnan
011 00:01:59 -0700 To: "user@hive.apache.org<mailto:user@hive.apache.org>" mailto:user@hive.apache.org>> Subject: Re: Handling hyphens in table/database/usernames OK, I see. You can use "grant all on database default to user `sri-krish`;" to finish your work. On

Re: Handling hyphens in table/database/usernames

2011-10-31 Thread Sriram Krishnan
me, which pattern is "[\\w_]+", so you can use '_' instead On Tue, Nov 1, 2011 at 9:29 AM, Sriram Krishnan mailto:skrish...@netflix.com>> wrote: Hi, Does anyone know how to handle hyphens in any of the following? Specifically, we have a user with a hyphenated username –

Handling hyphens in table/database/usernames

2011-10-31 Thread Sriram Krishnan
Hi, Does anyone know how to handle hyphens in any of the following? Specifically, we have a user with a hyphenated username – and I can't figure out a way to add him to a certain role. No amount of escaping my hyphen seems to help. I am using Hive version 0.7.1. Any ideas would be appreciated.

Re: Problem With HDFS USERS using JDBC

2011-10-27 Thread Sriram Krishnan
I had asked a similar question earlier - http://mail-archives.apache.org/mod_mbox/hive-user/201110.mbox/%3ccab13a97.2c54%25skrish...@netflix.com%3E. But I didn't get any responses. This may be a limitation of Hive JDBC. I would also be curious to know if there is a solution to this. Thanks, Sri

Re: Hive Authorization Bug?

2011-10-24 Thread Sriram Krishnan
011 at 11:07 AM, Ankit Jain mailto:ankitjainc...@gmail.com>> wrote: Hi, I think you are right?? I have one question. How we can create and switch user in hive??. Your grantor name is hadoop and user name is skrishnan. How u login with user skrishnan. Thanks, Ankit Jain On Tue

Re: Hive Authorization Bug?

2011-10-24 Thread Sriram Krishnan
Re: Hive Authorization Bug? Hi, Please try to run the following command and view the grant option. hive> show grant user abc on database default; output : databasedefault principalNameabc principalTypeUSER privilegeAll grantTime1319518326 grantor xyz is skrishnan is

Hive Authorization Bug?

2011-10-24 Thread Sriram Krishnan
Hi, I am finding some inconsistent behavior related to Hive authorization, and I am wondering if it is a bug or something related to my setup. I have our "default" database set up to only allow SELECT for user "skrishnan". But user skrishnan has "ALL" privileges on database "skrishnan". The fo

Hive JDBC Client - username/password

2011-10-04 Thread Sriram Krishnan
Hi, I am following instructions here (https://cwiki.apache.org/Hive/hiveclient.html#HiveClient-JDBCClientSampleCode) to use JDBC to connect to Hive. And I am also able to run queries via JDBC, just fine. However, I notice that the JDBC connection is created as follows - using "" for both the