unable to query the external hive table in which data is being parsed using regex

I am being able to fire select * kind of queries but not the select col1....type of queries. It throws the following exception

   Error during job, obtaining debugging information...
        Examining task ID: task_201305021530_0007_m_000002 (and more) from job job_201305021530_0007
        Exception in thread "Thread-90" java.lang.RuntimeException: Error while reading from task log url
            at org.apache.hadoop.hive.ql.exec.errors.TaskLogProcessor.getStackTraces(TaskLogProcessor.java:240)
            at org.apache.hadoop.hive.ql.exec.JobDebugger.showJobFailDebugInfo(JobDebugger.java:227)
            at org.apache.hadoop.hive.ql.exec.JobDebugger.run(JobDebugger.java:92)
            at java.lang.Thread.run(Thread.java:722)
        Caused by: java.net.UnknownHostException: avishkar-VB
            at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:178)
            at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:391)
            at java.net.Socket.connect(Socket.java:579)
            at java.net.Socket.connect(Socket.java:528)
            at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:378)
            at sun.net.www.http.HttpClient.openServer(HttpClient.java:473)
            at sun.net.www.http.HttpClient.<init>(HttpClient.java:203)
            at sun.net.www.http.HttpClient.New(HttpClient.java:290)
            at sun.net.www.http.HttpClient.New(HttpClient.java:306)
            at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:995)
            at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:931)
            at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:849)
            at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1299)
            at java.net.URL.openStream(URL.java:1037)
            at org.apache.hadoop.hive.ql.exec.errors.TaskLogProcessor.getStackTraces(TaskLogProcessor.java:192)
            ... 3 more
        FAILED: Execution Error, return code 2 from org.apache.hadoop.hive.ql.exec.MapRedTask
        MapReduce Jobs Launched: 

Answers


@Ankur I found the solution to this problem. You need to add the path of hive-contrib-..*.jar in the classPath. Or you can add this path in hive CLI before you fire any query like this :

add jar /home/hadoop/hive/lib/hive-contrib-0.8.1.jar; (mind the version of hive)


Need Your Help

python join the last two indices in a list

python list join indexing

i hope my question makes sense. i am looking to join the last 2 indices if an IF statement proves true but i am getting an error.

HTML Elements as While Conditions

javascript html while-loop boolean condition

I had a question about some code I ran into while learning how to code.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.