Exception -
Exception
in thread "main" java.lang.OutOfMemoryError: Java heap space
at java.util.Arrays.copyOf(Arrays.java:3236)
at java.io.ByteArrayOutputStream.toByteArray(ByteArrayOutputStream.java:191)
at org.apache.hive.beeline.BeeLine.getConsoleReader(BeeLine.java:905)
at org.apache.hive.beeline.BeeLine.begin(BeeLine.java:792)
Issue - https://issues.apache.org/jira/browse/HIVE-10836
The issue is caused by large Beeline History file (<user_home>/.beeline/history)
Analysis -
1. If we do
“beeline –e “select 1;” then nothing goes to .beeline/history
2. If we do
“beeline –f test.sql” then nothing goes to .beeline/history
3. If we do
“cat test.sql | beeline” then data goes in to .beeline/history
If we do “beeline <<< "select 124;" “ then data goes to .beeline/history
Solution - Cleanup the history.
Comments
Post a Comment