Caused by: org.xml.sax.SAXParseException; systemId: file:/home/hadoop/hive-0.12.0/conf/hive-site.xml; lineNumber: 5; columnNumber: 2; The markup in the document following the root element must be well
1:Hive安装的过程(Hive启动的时候报的错误),贴一下错误,和为什么错,以及解决方法:
[root@master bin]# ./hive
// :: INFO Configuration.deprecation: mapred.input.dir.recursive is deprecated. Instead, use mapreduce.input.fileinputformat.input.dir.recursive
// :: INFO Configuration.deprecation: mapred.max.split.size is deprecated. Instead, use mapreduce.input.fileinputformat.split.maxsize
// :: INFO Configuration.deprecation: mapred.min.split.size is deprecated. Instead, use mapreduce.input.fileinputformat.split.minsize
// :: INFO Configuration.deprecation: mapred.min.split.size.per.rack is deprecated. Instead, use mapreduce.input.fileinputformat.split.minsize.per.rack
// :: INFO Configuration.deprecation: mapred.min.split.size.per.node is deprecated. Instead, use mapreduce.input.fileinputformat.split.minsize.per.node
// :: INFO Configuration.deprecation: mapred.reduce.tasks is deprecated. Instead, use mapreduce.job.reduces
// :: INFO Configuration.deprecation: mapred.reduce.tasks.speculative.execution is deprecated. Instead, use mapreduce.reduce.speculative
[Fatal Error] hive-site.xml::: The markup in the document following the root element must be well-formed.
// :: FATAL conf.Configuration: error parsing conf file:/home/hadoop/hive-0.12./conf/hive-site.xml
org.xml.sax.SAXParseException; systemId: file:/home/hadoop/hive-0.12./conf/hive-site.xml; lineNumber: ; columnNumber: ; The markup in the document following the root element must be well-formed.
at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:)
at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:)
at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:)
at org.apache.hadoop.conf.Configuration.parse(Configuration.java:)
at org.apache.hadoop.conf.Configuration.parse(Configuration.java:)
at org.apache.hadoop.conf.Configuration.loadResource(Configuration.java:)
at org.apache.hadoop.conf.Configuration.loadResources(Configuration.java:)
at org.apache.hadoop.conf.Configuration.getProps(Configuration.java:)
at org.apache.hadoop.conf.Configuration.get(Configuration.java:)
at org.apache.hadoop.hive.conf.HiveConf.initialize(HiveConf.java:)
at org.apache.hadoop.hive.conf.HiveConf.<init>(HiveConf.java:)
at org.apache.hadoop.hive.common.LogUtils.initHiveLog4jCommon(LogUtils.java:)
at org.apache.hadoop.hive.common.LogUtils.initHiveLog4j(LogUtils.java:)
at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:)
at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:)
at java.lang.reflect.Method.invoke(Method.java:)
at org.apache.hadoop.util.RunJar.main(RunJar.java:)
Exception in thread "main" java.lang.RuntimeException: org.xml.sax.SAXParseException; systemId: file:/home/hadoop/hive-0.12./conf/hive-site.xml; lineNumber: ; columnNumber: ; The markup in the document following the root element must be well-formed.
at org.apache.hadoop.conf.Configuration.loadResource(Configuration.java:)
at org.apache.hadoop.conf.Configuration.loadResources(Configuration.java:)
at org.apache.hadoop.conf.Configuration.getProps(Configuration.java:)
at org.apache.hadoop.conf.Configuration.get(Configuration.java:)
at org.apache.hadoop.hive.conf.HiveConf.initialize(HiveConf.java:)
at org.apache.hadoop.hive.conf.HiveConf.<init>(HiveConf.java:)
at org.apache.hadoop.hive.common.LogUtils.initHiveLog4jCommon(LogUtils.java:)
at org.apache.hadoop.hive.common.LogUtils.initHiveLog4j(LogUtils.java:)
at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:)
at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:)
at java.lang.reflect.Method.invoke(Method.java:)
at org.apache.hadoop.util.RunJar.main(RunJar.java:)
Caused by: org.xml.sax.SAXParseException; systemId: file:/home/hadoop/hive-0.12./conf/hive-site.xml; lineNumber: ; columnNumber: ; The markup in the document following the root element must be well-formed.
at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:)
at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:)
at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:)
at org.apache.hadoop.conf.Configuration.parse(Configuration.java:)
at org.apache.hadoop.conf.Configuration.parse(Configuration.java:)
at org.apache.hadoop.conf.Configuration.loadResource(Configuration.java:)
... more
2:我的错误主要是配置Hive-site.xml的时候少写了开头和结尾的<configuration></configuration>,导致的错误,下面贴一下这个配置文件易错的地方:
<!--开头和结尾,一定不要忘记-->
<configuration>
<property>
<name>javax.jdo.option.ConnectionURL</name>
<!--自己的主机名称或者localhost-->
<value>jdbc:mysql://主机名称:3306/hive?createDatabaseIfNotExist=true</value>
</property>
<property>
<name>javax.jdo.option.ConnectionDriverName</name>
<value>com.mysql.jdbc.Driver</value>
</property>
<property>
<name>javax.jdo.option.ConnectionUserName</name>
<!--mysql的账号-->
<value>root</value>
</property>
<property>
<name>javax.jdo.option.ConnectionPassword</name>
<!--自己mysql的密码哦-->
<value></value>
</property>
</configuration>
停更......
天霸动霸tua,加油.....
2017-12-12 15:32:47
Caused by: org.xml.sax.SAXParseException; systemId: file:/home/hadoop/hive-0.12.0/conf/hive-site.xml; lineNumber: 5; columnNumber: 2; The markup in the document following the root element must be well的更多相关文章
- Spring- 异常org.xml.sax.SAXParseException; systemId: http://www.springframework.org/schema/context/; lineNumber: 1; columnNumber: 55; 在 publicId 和 systemId 之间需要有空格。
抛出异常 六月 03, 2018 7:40:44 下午 org.springframework.context.support.AbstractApplicationContext prepareRe ...
- maven web项目的web.xml报错The markup in the document following the root element must be well-formed.
maven项目里面的web.xml开头约束是这样的 <?xml version="1.0" encoding="UTF-8"?> <web-a ...
- The markup in the document following the root element must be well-formed. Quartz.xml .......
这个错误说明是我的Quartz.xml文件的问题 错误描述:错误发生在文档的标记后,文档格式必须是良好的. 错误原因:我这里多写了个 </xml> 文件头的<?xml ?>只是 ...
- Caused by: org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; Content is not allowed in
1.错误描述 严重: Exception sending context initialized event to listener instance of class org.springframe ...
- xml操作-Nested exception: org.xml.sax.SAXParseException: White spaces are required between publicId and systemId. 异常处理
异常如下: org.dom4j.DocumentException: Error on line 2 of document file:///D:/workspaces/struts2/lesson0 ...
- Caused by: org.xml.sax.SAXParseException; lineNumber: 64; columnNumber: 27; The entity name must immediately follow the '&' in the entity reference.
java.lang.IllegalStateException: Failed to load ApplicationContext at org.springframework.test.conte ...
- java读取xml文件报“org.xml.sax.SAXParseException: Premature end of file” .
背景:java读取xml文件,xml文件内容只有“<?xml version="1.0" encoding="UTF-8"?>”一行 java读取该 ...
- spring整合mybatis错误:Caused by: org.xml.sax.SAXParseException; lineNumber: 5; columnNumber: 62; 文档根元素 "mapper" 必须匹配 DOCTYPE 根 "configuration"。
运行环境:jdk1.7.0_17+tomcat 7 + spring:3.2.0 +mybatis:3.2.7+ eclipse 错误:Caused by: org.xml.sax.SAXParseE ...
- Caused by: org.xml.sax.SAXParseException; lineNumber: 4; columnNumber: 49; 前言中不允许有内容。
今天刚开始学习mybatis时,自己去尝试使用mybatis链接数据库,操作数据局时,报了一个下面的错误 Caused by: org.xml.sax.SAXParseException; lineN ...
随机推荐
- Android使用gradle不同配置多项目打包
//build.gradle该配置文件里路径均是相对路径 apply plugin: 'com.android.application' android { def suffix = "su ...
- Linux基础:xargs命令
简介 xargs可以将输入内容(通常通过命令行管道传递),转成后续命令的参数,通常用途有: 命令组合:尤其是一些命令不支持管道输入,比如ls. 避免参数过长:xargs可以通过-nx来将参数分组,避免 ...
- js清除cookie有时无法清除
最近写页面遇到一个问题,退出的时候需要清除cookie,但是刚开始一直清除不掉,代码如下: //清除函数 function delCookie(name) { var date= new Date() ...
- 关于React组件之间如何优雅地传值的探讨
闲话不多说,开篇撸代码,你可以会看到类似如下的结构: import React, { Component } from 'react'; // 父组件 class Parent extends Com ...
- Struts2中validate数据校验的两种常用方法
本文主要介绍Struts2中validate数据校验的两种方法及Struts2常用校验器. 1.Action中的validate()方法 Struts2提供了一个Validateable接口,这个接 ...
- Python笔记·第二章—— Python的编码问题(一)
一.什么是编码 可以说,计算机是一个即聪明又笨蛋的家伙.说它聪明,是因为他可以做很多事情,它的强大无需多说,大家应该都有所了解以及感受.但是为什么说它又是个笨蛋呢,因为我们在电脑上写出的每一个字,保存 ...
- Windows 10 安装 Docker for Windows
Docker for Windows是Docker社区版(CE)应用程序. Docker for Windows安装包包括在Windows系统上运行Docker所需的一切. 本主题介绍了预安装注意事项 ...
- 六、Spring Boot Controller使用
在Controller中使用 @RestController 注解,该注解是spring 4.0引入的.查看源码可知其包含了 @Controller 和 @ResponseBody 注解.我们可以理解 ...
- 三、Spring Boot 多数据源配置
下面一个Java类是已经写好的根据配置文件动态创建多dataSource的代码,其原理也很简单,就是读取配置文件,根据配置文件中配置的数据源数量,动态创建dataSource并注册到Spring中. ...
- 数据加密,android客户端和服务器端可共用
安卓中,不管是内网还是外网,数据的传输首要考虑就是安全问题,尤其是用户信息,以及各种密码等敏感信息. 所以说,对数据的加密是很有必要的,尤其是当下物联网蓬勃发展的今天,数据安全尤为重要. 数据加密的方 ...