<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Getting java.io.IOException: Schema script failed, errorcode 2 while starting Hive metastore in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Getting-java-io-IOException-Schema-script-failed-errorcode-2/m-p/205116#M167102</link>
    <description>&lt;P&gt;I am also having same issue, &lt;/P&gt;&lt;P&gt;the o/p of  /usr/hdp/current/hive-server2-hive2/bin/schematool -dbType mysql -initSchema -verbose is as follows,&lt;/P&gt;&lt;P&gt;SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/hdp/2.5.5.0-157/hive2/lib/log4j-slf4j-impl-2.6.2.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/hdp/2.5.5.0-157/hadoop/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See &lt;A href="http://www.slf4j.org/codes.html#multiple_bindings" target="_blank"&gt;http://www.slf4j.org/codes.html#multiple_bindings&lt;/A&gt; for an explanation.
SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]
Metastore connection URL:        jdbc:derby:;databaseName=/var/lib/hive/metastore/metastore_db;create=true
Metastore Connection Driver :    org.apache.derby.jdbc.EmbeddedDriver
Metastore connection User:       APP
Starting metastore schema initialization to 2.1.0
Initialization script hive-schema-2.1.0.mysql.sql
Connecting to jdbc:derby:;databaseName=/var/lib/hive/metastore/metastore_db;create=true
Connected to: Apache Derby (version 10.10.2.0 - (1582446))
Driver: Apache Derby Embedded JDBC Driver (version 10.10.2.0 - (1582446))
Transaction isolation: TRANSACTION_READ_COMMITTED
0: jdbc:derby:&amp;gt; !autocommit on
Autocommit status: true
0: jdbc:derby:&amp;gt; /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */
Error: Syntax error: Encountered "&amp;lt;EOF&amp;gt;" at line 1, column 64. (state=42X01,code
Closing: 0: jdbc:derby:;databaseName=/var/lib/hive/metastore/metastore_db;create
org.apache.hadoop.hive.metastore.HiveMetaException: Schema initialization FAILED
Underlying cause: java.io.IOException : Schema script failed, errorcode 2
org.apache.hadoop.hive.metastore.HiveMetaException: Schema initialization FAILED
        at org.apache.hive.beeline.HiveSchemaTool.doInit(HiveSchemaTool.java:304
        at org.apache.hive.beeline.HiveSchemaTool.doInit(HiveSchemaTool.java:277
        at org.apache.hive.beeline.HiveSchemaTool.main(HiveSchemaTool.java:526)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.hadoop.util.RunJar.run(RunJar.java:233)
        at org.apache.hadoop.util.RunJar.main(RunJar.java:148)
Caused by: java.io.IOException: Schema script failed, errorcode 2
        at org.apache.hive.beeline.HiveSchemaTool.runBeeLine(HiveSchemaTool.java
        at org.apache.hive.beeline.HiveSchemaTool.runBeeLine(HiveSchemaTool.java
        at org.apache.hive.beeline.HiveSchemaTool.doInit(HiveSchemaTool.java:300
        ... 8 more
*** schemaTool failed ***&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;What does this means??&lt;/P&gt;</description>
    <pubDate>Fri, 01 Sep 2017 14:02:41 GMT</pubDate>
    <dc:creator>girish28mane</dc:creator>
    <dc:date>2017-09-01T14:02:41Z</dc:date>
  </channel>
</rss>

