首页 文章 精选 留言 我的

精选列表

搜索[教程],共10000篇文章
优秀的个人博客,低调大师

云服务器 ECS 建站教程:快速使用AMH建站

快速使用AMH建站 AMH 是一套通过 Web 控制和管理服务器的 Linux 服务器管理系统以及虚拟主机管理系统。使用阿里云的云服务器 ECS 安装 AMH 可以快速地搭建出任意 PHP 网站。阿里云云市场包含大量的镜像资源,您只需简单购买所需的镜像环境就可快速搭建出应用环境。 准备工作 提前创建好 ECS 实例,详情请参考创建实例。 镜像部署 说明:这里的镜像部署只针对还未购买 ECS 服务器的用户。 操作步骤 1.登录阿里云云市场,搜索关键字 AMH4.2。 2.选择 PHP运行环境,单击 立即购买。 3.配置 ECS 服务器,同时也会把 AMH 镜像环境安装进去,最后单击 立即购买,完成支付。 手动部署 AMH 4.2 编译安装 AMH 4.2 为独立的一套 LNMP/Nginx 虚拟主机面板,安装请使用纯净系统。 1.使用 root 账号登录 L

优秀的个人博客,低调大师

云服务器 ECS 建站教程:镜像部署Windows环境

镜像部署Windows环境 您可以根据业务需要,选择下列任意一种方式部署云服务器 ECS 实例的使用环境: 镜像部署 手动部署 下表列出了两种部署方式的特点。一般推荐镜像部署。如果您需要个性化定制部署,建议使用手动部署。 对比项 镜像部署 手动部署 部署所需时间 3-5分钟,快速部署上云 1-2天。选择适合的操作系统、中间件、数据库、各类软件、插件、脚本,再进行安装和配置 专业性 IOPS 由运维过万级用户的优质服务商提供 依赖开发人员的开发水平 个性化 支持主流应用场景 可满足个性化的部署要求 安全性 经过严格安全审核,集成最稳定安全的版本 依赖开发人员的开发水平 售后服务 专业售后工程师团队支持 依赖运维人员的经验,或由外包团队支持 注意: 本文档只介绍通用的操作步骤。一般镜像软件安装包都包含了操作指南,请阅读镜像操作指南进行具体的安装和配置。 阿里云的云市场提供了丰富的镜

优秀的个人博客,低调大师

云服务器 ECS 建站教程:手动建站(Windows环境)

手动建站(Windows环境) 本节介绍如何使用阿里云镜像,一键部署 Web 环境,包括安装 IIS 组件(不包括 FTP 组件)、PHP 环境、重定向 Rewrite、MySQL、phpwind。该示例不需要更换系统盘。 部署之前,请确保您的实例可以连接公网。 在浏览器中打开阿里云的云市场。 搜索 阿里云windows一键安装web环境,然后购买该软件。 登录阿里云管理控制台。打开 产品与服务 > 云市场。 单击 已购买的服务。在 阿里云Windows一键安装Web环境 的右侧,单击 管理。 点击 下载地址,一键下载安装包。 解压缩安装包。通过远程桌面连接,将安装包拷贝到云服务器 ECS 实例上。 安装包启动后,单击 下一步。 指定安装目录,默认使用 C:websoft 。然后单击 安装。 系统会依次自动安装 IIS 组件(不包括 FTP 组件

优秀的个人博客,低调大师

云服务器 ECS 建站教程:快速搭建 ThinkPHP 框架

快速搭建 ThinkPHP 框架 ThinkPHP 是一款免费开源的,快速、简单的面向对象的轻量级 PHP 开发框架,遵循 Apache2 开源协议发布,是为了敏捷 Web 应用开发和简化企业应用开发而诞生的。 适用对象 本文档介绍如何使用云市场的 ThinkPHP 框架(含智慧云虚机面板) 快速搭建 ThinkPHP 框架。适用于正在学习 PHP 或者已经基于 ThinkPHP 框架研发的开发者。 基本流程 购买 ThinkPHP 框架镜像。 上传您的程序。 切换 PHP 脚本适应您的程序。 开启 pathinfo。 绑定域名。 1. 购买 ThinkPHP 框架镜像 单击 ThinkPHP 框架(含智慧云虚机面板) 进入镜像详情页。 单击 立即购买,按提示步骤根据您的实际业务需求购买 ECS 实例。 登录 ECS 管理控制台。 在左边导航栏里,单击 实例

优秀的个人博客,低调大师

安卓逆向系列教程 4.11 优酷 APK 去广告

4.11 优酷 APK 去广告 作者:飞龙 软件下载:http://app.cnmo.com/android/235159/ 这次要破解优酷的 APK,去掉播放视频开头的广告: 我们先抓包,看到了api.mobile.youku.com,这个就是广告所在的域名。 我们载入 AK: 将所有api.mobile.youku.com都换成127.0.0.1即可: 然后,在回编译的时候,会有如下问题。 >D:\Wizard破解工具包\Tool\Android\AndroidKiller_v1.3.1\projects\Youku\Project\res\values-v23\styles.xml:6: error: Error retrieving parent for item: No resource found that matches the given name '@android:style/WindowTitleBackground'. >D:\Wizard破解工具包\Tool\Android\AndroidKiller_v1.3.1\projects\Youku\Project\res\values-v23\styles.xml:6: error: Error retrieving parent for item: No resource found that matches the given name '@android:style/WindowTitleBackground'. 我们找到res/value-v23/styles.xml,把resources下的东西注释掉: <?xml version="1.0" encoding="utf-8"?> <resources> <!-- ... --> </resources> 在找到res/value/public.xml,把所有带Base.V23的东西(两个)注释掉: <!-- <public type="style" name="Base.V23.Theme.AppCompat" id="0x7f0d00a6" /> <public type="style" name="Base.V23.Theme.AppCompat.Light" id="0x7f0d00a7" /> --> 即可成功编译: 当前 Apktool 使用版本:Android Killer Default APKTOOL 正在编译 APK,请稍等... >I: 使用 ShakaApktool 2.0.0-20150914 >I: 编译 smali 到 classes.dex... >I: 编译 smali_classes2 到 classes2.dex... >I: 正在编译资源... >I: 正在拷贝libs目录... (/lib) >I: 正在编译apk文件... >I: 复制未知文件/目录... APK 编译完成! 正在对 APK 进行签名,请稍等... APK 签名完成! --------------------------- APK 所有编译工作全部完成!!! 生成路径: file:D:\Wizard破解工具包\Tool\Android\AndroidKiller_v1.3.1\projects\Youku\Bin\Youku_killer.apk

优秀的个人博客,低调大师

官方教程:教你用好微信JS-SDK接口

微信开放JS-SDK接口,开发者和行业用户可谓是欢欣鼓舞、奔走相告,目测将激起一大波第三方开发商的创新产品!真真是H5开发者的利好!但也有用户表示,还不了解JS-SDK接口到底是啥,究竟怎么用。现在,小编就通过大量实战案例为大家逐一讲解,争取让大家都会用、且用好JS-SDK接口,赶紧往下看吧! 1、分享类接口:支持获取“分享到朋友圈”、“发送给朋友”、“分享到QQ”和“分享到微博”按钮的用户点击状态,同时支持自定义分享内容。 小编解读:说起分享接口应用,最常见的莫过于公众号文章分享。通过分享按钮,用户可以将自己喜欢的文章分享给微信好友,也可分享到微信朋友圈。 通过此次开放的分享接口,开发者获得了新的能力: 可以在用户分享时,为其设置个性化的分享图片、标题、描述等,从而使分享的内容更生动有趣,以获得更好的传播效果。 同时,通过此接口,开发者还可以获知用户是否分享了网页,帮助其更好地评估网页服务是否受用户喜爱等。 2、图像类接口:支持拍照,并从手机相册选择、上传、下载和预览图片。 小编解读:“云打印”已开通了图像类接口,用户可以自由选择、打印手机相册中已有的照片,或是即时拍摄一张照片。打印前,可通过大图预览确认照片选择是否有误。 这实际上帮助开发者在网页上流畅、低成本地实现了选图或拍照的功能,也为用户带去了更好的使用体验。 大家熟悉的“印美图”,就是通过图像类接口,接收用户上传的照片,从而帮助用户完成打印服务。今后,运营者、商家通过H5页面发起照片征集等活动时,图像类接口也能帮上忙了。 3、音频类接口:支持语音的录制、播放和暂停播放,同时支持将语音快速上传到云端服务器,或从云端服务器将语音快速下载到网页。 小编解读:“微邮筒”早前已开通了音频类接口,用户在制作明信片时,可以同时录一段语音。当亲朋好友或自己收到明信片时,扫一扫明信片上的二维码,即可收听该段语音。 如此一来,语音就脱离了手机存储的限制,用户在任何时候、通过任何帐号,只要打开微信扫码即可获取语音片段,让记忆更坚固、长久。 4、智能类接口:支持将语音快速地转换成文字。开发者无需掌握语音识别相关技术,只需简单引用微信JS-SDK提供的方法即可实现。 小编解读:微信的语音输入、语音转文字功能已上线有段时间了,受到用户的广泛好评。 事实上,TA能做的还有更多。比如“付费通账单查缴”就借此为用户提供了“语音缴费”服务。用户不用按键,对着手机说出账单户号,就像平时用微信跟朋友聊天一样,然后点击“确认”即缴费成功,可谓是“躺着都可以完成”。便捷的缴费体验赢得了用户的青睐,该帐号上线仅仅5天,就拥了11539名用户,交易成功1862笔,交易金额达到20万元。 因此,语音识别等智能类接口的开放,对一些开发能力稍弱的运营方来说,无疑是重大利好。 5、设备信息类接口:支持获取当前手机设备的网络状态,如2G、3G、4G或Wi-Fi,为用户提供流畅的浏览体验。 小编解读:精心设计的界面、互动体验,如果因为用户手机网络原因而无法呈现,出现跳转迟缓、显示不全等状况,不仅白白浪费了运营者的前期努力,也容易挫伤用户参与积极性,留下不佳的印象。如果能够获取用户当前手机设备状态,通过技术手段加以干预,比如根据设备网络状态推送合适的网页版本,那么将大大减少此类状况的发生,用户体验也将更有保障。 6、地理位置类接口:支持获取用户的地理位置信息(前提是获得用户同意),支持使用微信的内置地图查看器,查看地理位置或导航。 小编解读:“大众点评”已将地理位置功能应用得相当成熟,当用户发起团购美食、电影票、订酒店等需求时,“大众点评”可以立即根据用户实时位置,向用户展示其位置周边相应商家。用户打开相关商品、服务详情页后,还可点击商家地址,调出地图、查询导航指引。 7、界面操作类接口:支持隐藏或显示微信内置浏览器“右上角菜单”、“分享到朋友圈”、“发送给朋友”、“复制链接”等指定按钮,支持关闭当前网页窗口并返回公众号会话。 小编解读:众所周知,点击微信界面右上角的“···”,将打开微信所有的菜单按钮,但对不同类型的商家、活动来说,并非所有菜单按钮都有用,冗余的按钮反而会耽误时间,干扰用户选择。界面操作类接口的开放,能帮助运营者关闭不需要的按钮,优化选择界面,也能提升用户操作效率。 8、微信扫一扫接口:支持使用微信扫一扫,扫描一维码或二维码,并将用户扫码内容交由微信处理或返回给网页由网页处理。 小编解读:除了扫街景、翻译,微信扫一扫在购物中的应用也已十分广泛,京东、当当等许多网站均支持微信扫码支付结算,用户在逛街时,通过微信扫描商品条形码,亦可即时查询到线上购买价格。 除此之外,微信扫一扫亦可扫实物。微信与Panda.W在广州花城大道开展的“微信扫熊猫”图象识别合作,首创通过实物、3D图形加入微信扫码新功能,用户直接扫描实物,就能进入相应的商品售卖页面,开始购物。从看见到购买、售后无缝对接,大大缩短用户犹豫期,帮助商家有效促进了销售。 9、微信小店接口:支持从网页跳转到指定的微信小店商品页,支持浏览商品的详细信息,支持完整的购买、客服等流程。 小编解读:花心思做了H5推广页面,用户还得通过扫码、加关注、找入口,才能开始购买商品?太慢了!今后,用户只需轻轻一点,就能直接打开相应微信小店的商品详情页,光速完成详情查询和咨询、购买。 10、微信卡券接口:支持批量添加卡券、调起使用门店卡券列表及获取用户选择列表。 小编解读:简而言之,通过这个能力,商家能批量添加多种卡券,并直接为用户展示其附近的门店能够使用那些卡券,引导其选择领取。同时,通过对后台“用户选择列表”进行数据分析,能够快速了解相应商圈的用户喜好、整体产品受欢迎程度等,比如XX小区附近用户更爱“牛堡+姜饮”,以便后期的商品调配与优化经营。 11、微信支付接口:支持有支付权限的公众号在网页发起一个微信支付请求。 小编解读:在某些场景下,相对于图文消息,网页多样化的呈现形式更能满足运营者的需求。如“腾讯公益”,需要向用户介绍项目进程、项目详情等,信息量较大,同时又需要兼顾用户捐款的便捷性,因此,在网页能够直接发起微信支付请求的需求非常迫切。如今,用户在查看完“腾讯公益”各项目介绍内容后,已能直接在网页底部点击捐款按钮,就能立即通过微信支付进行捐款。 附微信开放JS-SDK接口权限列表:

优秀的个人博客,低调大师

大数据工具篇之Hive与MySQL整合完整教程

一、引言 Hive元数据存储可以放到RDBMS数据库中,本文以Hive与MySQL数据库的整合为目标,详细说明Hive与MySQL的整合方法。 二、安装驱动 MySQL最新的Java驱动版本为:mysql-connector-java-5.1.28-bin.jar,下载后拷贝到:Hive/Lib目录。 三、安装MySQL 3.1 版本 RHEL5+mysql-5.5.35-1.i386.rpm 3.2 顺序 MySQL-shared-compat-5.5.35-1.rhel15.i386.rpm MySQL-server-5.5.35-1.rhel5.i386.rpm MySQL-client-5.5.35-1.rhel5.i386.rpm 四、配置文件 修改Hive配置文件Hive-site.xml,修改后的结果如下所示: 1 <property> 2 <name>javax.jdo.option.ConnectionURL</name> 3 <value>jdbc:mysql://localhost:3306/hivedb?characterEncoding=UTF-8</value> 4 <description>JDBC connect string for a JDBC metastore</description> 5 </property> 6 7 <property> 8 <name>javax.jdo.option.ConnectionDriverName</name> 9 <value>com.mysql.jdbc.Driver</value> 10 <description>Driver class name for a JDBC metastore</description> 11 </property> 12 13 <property> 14 <name>javax.jdo.PersistenceManagerFactoryClass</name> 15 <value>org.datanucleus.jdo.JDOPersistenceManagerFactory</value> 16 <description>class implementing the jdo persistence</description> 17 </property> 18 19 <property> 20 <name>javax.jdo.option.DetachAllOnCommit</name> 21 <value>true</value> 22 <description>detaches all objects from session so that they can be used after transaction is committed</description> 23 </property> 24 25 <property> 26 <name>javax.jdo.option.NonTransactionalRead</name> 27 <value>true</value> 28 <description>reads outside of transactions</description> 29 </property> 30 31 <property> 32 <name>javax.jdo.option.ConnectionUserName</name> 33 <value>root</value> 34 <description>username to use against metastore database</description> 35 </property> 36 37 <property> 38 <name>javax.jdo.option.ConnectionPassword</name> 39 <value>root</value> 40 <description>password to use against metastore database</description> 41 </property> 五、结果展示 安装完成以后,通过访问mysql客户端,可以用来验证是否安装成功。注意与普通关系型数据创建表格后的区别。 mysql>show tables; 1 +----------------+ 2 | Tables_in_hive | 3 +----------------+ 4 | BUCKETING_COLS | 5 | COLUMNS | 6 | DBS | 7 | PARTITION_KEYS | 8 | SDS | 9 | SD_PARAMS | 10 | SEQUENCE_TABLE | 11 | SERDES | 12 | SERDE_PARAMS | 13 | SORT_COLS | 14 | TABLE_PARAMS | 15 | TBLS | 16 +----------------+ 六、注意事项 曾经有人单独找我咨询过这个问题:为何无法在Hive中指定使用哪个MySQL数据库?这里面有一个需要说明的地方是Hive的数据库的概念不同于RDBMS数据库,MySQL数据库的指定是基于配置文件的,但是Hive的数据库只是一个命名空间号,类似分组的概念。hive中的数据库可以在使用MySQL数据库中,通过Select * from DBS查看到。 作者:张子良 出处:http://www.cnblogs.com/hadoopdev 本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。

优秀的个人博客,低调大师

大数据工具篇之Hive与HBase整合完整教程

一、引言 最近的一次培训,用户特意提到Hadoop环境下HDFS中存储的文件如何才能导入到HBase,关于这部分基于HBase Java API的写入方式,之前曾经有过技术文章共享,本文就不再说明。本文基于Hive执行HDFS批量向HBase导入数据,讲解Hive与HBase的整合问题。这方面的文章已经很多,但是由于版本差异,可操作性不大,本文采用的版本均基于以下版本说明中的版本。 二、版本说明 序号 软件 版本 1 Hive 0.10.0 2 HBase 0.94.0 3 Hadoop 1.0.1 三、配置指南 3.1 创建配置文件 cp conf/hive-default.xml.templatehive-default.xml cp conf/hive-default.xml.templatehive-site.xml 3.2 修改配置文件 基于hive-default.xml.template进行拷贝复制的hive-site.xml文件有问题,主要集中在<description></description>标签不配对的情况,需要根据错误提示进行修改,修改完成后的配置文件如下所示: 1 <?xml version="1.0"?> 2 <?xml-stylesheet type="text/xsl" href="configuration.xsl"?> 3 <!-- 4 Licensed to the Apache Software Foundation (ASF) under one or more 5 contributor license agreements. See the NOTICE file distributed with 6 this work for additional information regarding copyright ownership. 7 The ASF licenses this file to You under the Apache License, Version 2.0 8 (the "License"); you may not use this file except in compliance with 9 the License. You may obtain a copy of the License at 10 11 http://www.apache.org/licenses/LICENSE-2.0 12 13 Unless required by applicable law or agreed to in writing, software 14 distributed under the License is distributed on an "AS IS" BASIS, 15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 See the License for the specific language governing permissions and 17 limitations under the License. 18 --> 19 20 <configuration> 21 22 <!-- WARNING!!! This file is provided for documentation purposes ONLY! --> 23 <!-- WARNING!!! Any changes you make to this file will be ignored by Hive. --> 24 <!-- WARNING!!! You must make your changes in hive-site.xml instead. --> 25 26 27 <!-- Hive Execution Parameters --> 28 <property> 29 <name>mapred.reduce.tasks</name> 30 <value>-1</value> 31 <description>The default number of reduce tasks per job. Typically set 32 to a prime close to the number of available hosts. Ignored when 33 mapred.job.tracker is "local". Hadoop set this to 1 by default, whereas hive uses -1 as its default value. 34 By setting this property to -1, Hive will automatically figure out what should be the number of reducers. 35 </description> 36 </property> 37 38 <property> 39 <name>hive.exec.reducers.bytes.per.reducer</name> 40 <value>1000000000</value> 41 <description>size per reducer.The default is 1G, i.e if the input size is 10G, it will use 10 reducers.</description> 42 </property> 43 44 <property> 45 <name>hive.exec.reducers.max</name> 46 <value>999</value> 47 <description>max number of reducers will be used. If the one 48 specified in the configuration parameter mapred.reduce.tasks is 49 negative, hive will use this one as the max number of reducers when 50 automatically determine number of reducers.</description> 51 </property> 52 53 <property> 54 <name>hive.cli.print.header</name> 55 <value>false</value> 56 <description>Whether to print the names of the columns in query output.</description> 57 </property> 58 59 <property> 60 <name>hive.cli.print.current.db</name> 61 <value>false</value> 62 <description>Whether to include the current database in the hive prompt.</description> 63 </property> 64 65 <property> 66 <name>hive.cli.prompt</name> 67 <value>hive</value> 68 <description>Command line prompt configuration value. Other hiveconf can be used in 69 this configuration value. Variable substitution will only be invoked at the hive 70 cli startup.</description> 71 </property> 72 73 <property> 74 <name>hive.exec.scratchdir</name> 75 <value>/tmp/hive-${user.name}</value> 76 <description>Scratch space for Hive jobs</description> 77 </property> 78 79 <property> 80 <name>hive.exec.local.scratchdir</name> 81 <value>/tmp/${user.name}</value> 82 <description>Local scratch space for Hive jobs</description> 83 </property> 84 85 <property> 86 <name>hive.test.mode</name> 87 <value>false</value> 88 <description>whether hive is running in test mode. If yes, it turns on sampling and prefixes the output tablename</description> 89 </property> 90 91 <property> 92 <name>hive.test.mode.prefix</name> 93 <value>test_</value> 94 <description>if hive is running in test mode, prefixes the output table by this string</description> 95 </property> 96 97 <!-- If the input table is not bucketed, the denominator of the tablesample is determinied by the parameter below --> 98 <!-- For example, the following query: --> 99 <!-- INSERT OVERWRITE TABLE dest --> 100 <!-- SELECT col1 from src --> 101 <!-- would be converted to --> 102 <!-- INSERT OVERWRITE TABLE test_dest --> 103 <!-- SELECT col1 from src TABLESAMPLE (BUCKET 1 out of 32 on rand(1)) --> 104 <property> 105 <name>hive.test.mode.samplefreq</name> 106 <value>32</value> 107 <description>if hive is running in test mode and table is not bucketed, sampling frequency</description> 108 </property> 109 110 <property> 111 <name>hive.test.mode.nosamplelist</name> 112 <value></value> 113 <description>if hive is running in test mode, dont sample the above comma seperated list of tables</description> 114 </property> 115 116 <property> 117 <name>hive.metastore.uris</name> 118 <value></value> 119 <description>Thrift uri for the remote metastore. Used by metastore client to connect to remote metastore.</description> 120 </property> 121 122 <property> 123 <name>javax.jdo.option.ConnectionURL</name> 124 <value>jdbc:derby:;databaseName=metastore_db;create=true</value> 125 <description>JDBC connect string for a JDBC metastore</description> 126 </property> 127 128 <property> 129 <name>javax.jdo.option.ConnectionDriverName</name> 130 <value>org.apache.derby.jdbc.EmbeddedDriver</value> 131 <description>Driver class name for a JDBC metastore</description> 132 </property> 133 134 <property> 135 <name>javax.jdo.PersistenceManagerFactoryClass</name> 136 <value>org.datanucleus.jdo.JDOPersistenceManagerFactory</value> 137 <description>class implementing the jdo persistence</description> 138 </property> 139 140 <property> 141 <name>javax.jdo.option.DetachAllOnCommit</name> 142 <value>true</value> 143 <description>detaches all objects from session so that they can be used after transaction is committed</description> 144 </property> 145 146 <property> 147 <name>javax.jdo.option.NonTransactionalRead</name> 148 <value>true</value> 149 <description>reads outside of transactions</description> 150 </property> 151 152 <property> 153 <name>javax.jdo.option.ConnectionUserName</name> 154 <value>APP</value> 155 <description>username to use against metastore database</description> 156 </property> 157 158 <property> 159 <name>javax.jdo.option.ConnectionPassword</name> 160 <value>mine</value> 161 <description>password to use against metastore database</description> 162 </property> 163 164 <property> 165 <name>javax.jdo.option.Multithreaded</name> 166 <value>true</value> 167 <description>Set this to true if multiple threads access metastore through JDO concurrently.</description> 168 </property> 169 170 <property> 171 <name>datanucleus.connectionPoolingType</name> 172 <value>DBCP</value> 173 <description>Uses a DBCP connection pool for JDBC metastore</description> 174 </property> 175 176 <property> 177 <name>datanucleus.validateTables</name> 178 <value>false</value> 179 <description>validates existing schema against code. turn this on if you want to verify existing schema </description> 180 </property> 181 182 <property> 183 <name>datanucleus.validateColumns</name> 184 <value>false</value> 185 <description>validates existing schema against code. turn this on if you want to verify existing schema </description> 186 </property> 187 188 <property> 189 <name>datanucleus.validateConstraints</name> 190 <value>false</value> 191 <description>validates existing schema against code. turn this on if you want to verify existing schema </description> 192 </property> 193 194 <property> 195 <name>datanucleus.storeManagerType</name> 196 <value>rdbms</value> 197 <description>metadata store type</description> 198 </property> 199 200 <property> 201 <name>datanucleus.autoCreateSchema</name> 202 <value>true</value> 203 <description>creates necessary schema on a startup if one doesn't exist. set this to false, after creating it once</description> 204 </property> 205 206 <property> 207 <name>datanucleus.autoStartMechanismMode</name> 208 <value>checked</value> 209 <description>throw exception if metadata tables are incorrect</description> 210 </property> 211 212 <property> 213 <name>datanucleus.transactionIsolation</name> 214 <value>read-committed</value> 215 <description>Default transaction isolation level for identity generation. </description> 216 </property> 217 218 <property> 219 <name>datanucleus.cache.level2</name> 220 <value>false</value> 221 <description>Use a level 2 cache. Turn this off if metadata is changed independently of hive metastore server</description> 222 </property> 223 224 <property> 225 <name>datanucleus.cache.level2.type</name> 226 <value>SOFT</value> 227 <description>SOFT=soft reference based cache, WEAK=weak reference based cache.</description> 228 </property> 229 230 <property> 231 <name>datanucleus.identifierFactory</name> 232 <value>datanucleus</value> 233 <description>Name of the identifier factory to use when generating table/column names etc. 'datanucleus' is used for backward compatibility</description> 234 </property> 235 236 <property> 237 <name>datanucleus.plugin.pluginRegistryBundleCheck</name> 238 <value>LOG</value> 239 <description>Defines what happens when plugin bundles are found and are duplicated [EXCEPTION|LOG|NONE]</description> 240 </property> 241 242 <property> 243 <name>hive.metastore.warehouse.dir</name> 244 <value>/user/hive/warehouse</value> 245 <description>location of default database for the warehouse</description> 246 </property> 247 248 <property> 249 <name>hive.metastore.execute.setugi</name> 250 <value>false</value> 251 <description>In unsecure mode, setting this property to true will cause the metastore to execute DFS operations using the client's reported user and group permissions. Note that this property must be set on both the client and server sides. Further note that its best effort. If client sets its to true and server sets it to false, client setting will be ignored.</description> 252 </property> 253 254 <property> 255 <name>hive.metastore.event.listeners</name> 256 <value></value> 257 <description>list of comma seperated listeners for metastore events.</description> 258 </property> 259 260 <property> 261 <name>hive.metastore.partition.inherit.table.properties</name> 262 <value></value> 263 <description>list of comma seperated keys occurring in table properties which will get inherited to newly created partitions. * implies all the keys will get inherited.</description> 264 </property> 265 266 <property> 267 <name>hive.metadata.export.location</name> 268 <value></value> 269 <description>When used in conjunction with the org.apache.hadoop.hive.ql.parse.MetaDataExportListener pre event listener, it is the location to which the metadata will be exported. The default is an empty string, which results in the metadata being exported to the current user's home directory on HDFS.</description> 270 </property> 271 272 <property> 273 <name>hive.metadata.move.exported.metadata.to.trash</name> 274 <value></value> 275 <description>When used in conjunction with the org.apache.hadoop.hive.ql.parse.MetaDataExportListener pre event listener, this setting determines if the metadata that is exported will subsequently be moved to the user's trash directory alongside the dropped table data. This ensures that the metadata will be cleaned up along with the dropped table data.</description> 276 </property> 277 278 <property> 279 <name>hive.metastore.partition.name.whitelist.pattern</name> 280 <value></value> 281 <description>Partition names will be checked against this regex pattern and rejected if not matched. To use, enable hive.metastore.pre.event.listeners=org.apache.hadoop.hive.metastore.PartitionNameWhitelistPreEventListener Listener will not register if this property value is empty.</description> 282 </property> 283 284 <property> 285 <name>hive.metastore.end.function.listeners</name> 286 <value></value> 287 <description>list of comma separated listeners for the end of metastore functions.</description> 288 </property> 289 290 <property> 291 <name>hive.metastore.event.expiry.duration</name> 292 <value>0</value> 293 <description>Duration after which events expire from events table (in seconds)</description> 294 </property> 295 296 <property> 297 <name>hive.metastore.event.clean.freq</name> 298 <value>0</value> 299 <description>Frequency at which timer task runs to purge expired events in metastore(in seconds).</description> 300 </property> 301 302 <property> 303 <name>hive.metastore.connect.retries</name> 304 <value>5</value> 305 <description>Number of retries while opening a connection to metastore</description> 306 </property> 307 308 <property> 309 <name>hive.metastore.failure.retries</name> 310 <value>3</value> 311 <description>Number of retries upon failure of Thrift metastore calls</description> 312 </property> 313 314 <property> 315 <name>hive.metastore.client.connect.retry.delay</name> 316 <value>1</value> 317 <description>Number of seconds for the client to wait between consecutive connection attempts</description> 318 </property> 319 320 <property> 321 <name>hive.metastore.client.socket.timeout</name> 322 <value>20</value> 323 <description>MetaStore Client socket timeout in seconds</description> 324 </property> 325 326 <property> 327 <name>hive.metastore.rawstore.impl</name> 328 <value>org.apache.hadoop.hive.metastore.ObjectStore</value> 329 <description>Name of the class that implements org.apache.hadoop.hive.metastore.rawstore interface. This class is used to store and retrieval of raw metadata objects such as table, database</description> 330 </property> 331 332 <property> 333 <name>hive.metastore.batch.retrieve.max</name> 334 <value>300</value> 335 <description>Maximum number of objects (tables/partitions) can be retrieved from metastore in one batch. The higher the number, the less the number of round trips is needed to the Hive metastore server, but it may also cause higher memory requirement at the client side.</description> 336 </property> 337 338 <property> 339 <name>hive.metastore.batch.retrieve.table.partition.max</name> 340 <value>1000</value> 341 <description>Maximum number of table partitions that metastore internally retrieves in one batch.</description> 342 </property> 343 344 <property> 345 <name>hive.default.fileformat</name> 346 <value>TextFile</value> 347 <description>Default file format for CREATE TABLE statement. Options are TextFile and SequenceFile. Users can explicitly say CREATE TABLE ... STORED AS &lt;TEXTFILE|SEQUENCEFILE&gt; to override</description> 348 </property> 349 350 <property> 351 <name>hive.fileformat.check</name> 352 <value>true</value> 353 <description>Whether to check file format or not when loading data files</description> 354 </property> 355 356 <property> 357 <name>hive.map.aggr</name> 358 <value>true</value> 359 <description>Whether to use map-side aggregation in Hive Group By queries</description> 360 </property> 361 362 <property> 363 <name>hive.groupby.skewindata</name> 364 <value>false</value> 365 <description>Whether there is skew in data to optimize group by queries</description> 366 </property> 367 368 <property> 369 <name>hive.groupby.mapaggr.checkinterval</name> 370 <value>100000</value> 371 <description>Number of rows after which size of the grouping keys/aggregation classes is performed</description> 372 </property> 373 374 <property> 375 <name>hive.mapred.local.mem</name> 376 <value>0</value> 377 <description>For local mode, memory of the mappers/reducers</description> 378 </property> 379 380 <property> 381 <name>hive.mapjoin.followby.map.aggr.hash.percentmemory</name> 382 <value>0.3</value> 383 <description>Portion of total memory to be used by map-side grup aggregation hash table, when this group by is followed by map join</description> 384 </property> 385 386 <property> 387 <name>hive.map.aggr.hash.force.flush.memory.threshold</name> 388 <value>0.9</value> 389 <description>The max memory to be used by map-side grup aggregation hash table, if the memory usage is higher than this number, force to flush data</description> 390 </property> 391 392 <property> 393 <name>hive.map.aggr.hash.percentmemory</name> 394 <value>0.5</value> 395 <description>Portion of total memory to be used by map-side grup aggregation hash table</description> 396 </property> 397 398 <property> 399 <name>hive.map.aggr.hash.min.reduction</name> 400 <value>0.5</value> 401 <description>Hash aggregation will be turned off if the ratio between hash 402 table size and input rows is bigger than this number. Set to 1 to make sure 403 hash aggregation is never turned off.</description> 404 </property> 405 406 <property> 407 <name>hive.optimize.cp</name> 408 <value>true</value> 409 <description>Whether to enable column pruner</description> 410 </property> 411 412 <property> 413 <name>hive.optimize.index.filter</name> 414 <value>false</value> 415 <description>Whether to enable automatic use of indexes</description> 416 </property> 417 418 <property> 419 <name>hive.optimize.index.groupby</name> 420 <value>false</value> 421 <description>Whether to enable optimization of group-by queries using Aggregate indexes.</description> 422 </property> 423 424 <property> 425 <name>hive.optimize.ppd</name> 426 <value>true</value> 427 <description>Whether to enable predicate pushdown</description> 428 </property> 429 430 <property> 431 <name>hive.optimize.ppd.storage</name> 432 <value>true</value> 433 <description>Whether to push predicates down into storage handlers. Ignored when hive.optimize.ppd is false.</description> 434 </property> 435 436 <property> 437 <name>hive.ppd.recognizetransivity</name> 438 <value>true</value> 439 <description>Whether to transitively replicate predicate filters over equijoin conditions.</description> 440 </property> 441 442 <property> 443 <name>hive.optimize.groupby</name> 444 <value>true</value> 445 <description>Whether to enable the bucketed group by from bucketed partitions/tables.</description> 446 </property> 447 448 <property> 449 <name>hive.optimize.skewjoin.compiletime</name> 450 <value>false</value> 451 <description>Whether to create a separate plan for skewed keys for the tables in the join. 452 This is based on the skewed keys stored in the metadata. At compile time, the plan is broken 453 into different joins: one for the skewed keys, and the other for the remaining keys. And then, 454 a union is performed for the 2 joins generated above. So unless the same skewed key is present 455 in both the joined tables, the join for the skewed key will be performed as a map-side join. 456 457 The main difference between this paramater and hive.optimize.skewjoin is that this parameter 458 uses the skew information stored in the metastore to optimize the plan at compile time itself. 459 If there is no skew information in the metadata, this parameter will not have any affect. 460 Both hive.optimize.skewjoin.compiletime and hive.optimize.skewjoin should be set to true. 461 Ideally, hive.optimize.skewjoin should be renamed as hive.optimize.skewjoin.runtime, but not doing 462 so for backward compatibility. 463 464 If the skew information is correctly stored in the metadata, hive.optimize.skewjoin.compiletime 465 would change the query plan to take care of it, and hive.optimize.skewjoin will be a no-op. 466 </description> 467 </property> 468 469 <property> 470 <name>hive.optimize.union.remove</name> 471 <value>false</value> 472 <description> 473 Whether to remove the union and push the operators between union and the filesink above 474 union. This avoids an extra scan of the output by union. This is independently useful for union 475 queries, and specially useful when hive.optimize.skewjoin.compiletime is set to true, since an 476 extra union is inserted. 477 478 The merge is triggered if either of hive.merge.mapfiles or hive.merge.mapredfiles is set to true. 479 If the user has set hive.merge.mapfiles to true and hive.merge.mapredfiles to false, the idea was the 480 number of reducers are few, so the number of files anyway are small. However, with this optimization, 481 we are increasing the number of files possibly by a big margin. So, we merge aggresively. 482 </description> 483 </property> 484 485 <property> 486 <name>hive.mapred.supports.subdirectories</name> 487 <value>false</value> 488 <description>Whether the version of hadoop which is running supports sub-directories for tables/partitions. 489 Many hive optimizations can be applied if the hadoop version supports sub-directories for 490 tables/partitions. It was added by MAPREDUCE-1501 491 </description> 492 </property> 493 494 <property> 495 <name>hive.multigroupby.singlemr</name> 496 <value>false</value> 497 <description>Whether to optimize multi group by query to generate single M/R 498 job plan. If the multi group by query has common group by keys, it will be 499 optimized to generate single M/R job.</description> 500 </property> 501 502 <property> 503 <name>hive.map.groupby.sorted</name> 504 <value>false</value> 505 <description>If the bucketing/sorting properties of the table exactly match the grouping key, whether to 506 perform the group by in the mapper by using BucketizedHiveInputFormat. The only downside to this 507 is that it limits the number of mappers to the number of files. 508 </description> 509 </property> 510 511 <property> 512 <name>hive.join.emit.interval</name> 513 <value>1000</value> 514 <description>How many rows in the right-most join operand Hive should buffer before emitting the join result. </description> 515 </property> 516 517 <property> 518 <name>hive.join.cache.size</name> 519 <value>25000</value> 520 <description>How many rows in the joining tables (except the streaming table) should be cached in memory. </description> 521 </property> 522 523 <property> 524 <name>hive.mapjoin.bucket.cache.size</name> 525 <value>100</value> 526 <description>How many values in each keys in the map-joined table should be cached in memory. </description> 527 </property> 528 529 <property> 530 <name>hive.mapjoin.cache.numrows</name> 531 <value>25000</value> 532 <description>How many rows should be cached by jdbm for map join. </description> 533 </property> 534 535 <property> 536 <name>hive.optimize.skewjoin</name> 537 <value>false</value> 538 <description>Whether to enable skew join optimization. 539 The algorithm is as follows: At runtime, detect the keys with a large skew. Instead of 540 processing those keys, store them temporarily in a hdfs directory. In a follow-up map-reduce 541 job, process those skewed keys. The same key need not be skewed for all the tables, and so, 542 the follow-up map-reduce job (for the skewed keys) would be much faster, since it would be a 543 map-join. 544 </description> 545 </property> 546 547 <property> 548 <name>hive.exec.list.bucketing.default.dir</name> 549 <value>HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME</value> 550 <description>Default directory name used in list bucketing. 551 List bucketing feature will create sub-directory for each skewed-value and a default directory 552 for non-skewed value. This config specifies the default name for the default directory. 553 Sub-directory is created by list bucketing DML and under partition directory. User doesn't need 554 to know how to construct the canonical path. It just gives user choice if they want to change 555 the default directory name. 556 For example, there are 2 skewed column c1 and c2. 2 skewed value: (1,a) and (2,b). subdirectory: 557 <partition-dir>/c1=1/c2=a/</partition-dir> 558 <partition-dir>/c1=2/c2=b/</partition-dir> 559 <partition-dir>/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/HIVE_DEFAULT_LIST_BUCKETING_DIR_NAME/</partition-dir> 560 Note: This config won't impact users if they don't list bucketing. 561 </description> 562 </property> 563 564 <property> 565 <name>hive.skewjoin.key</name> 566 <value>100000</value> 567 <description>Determine if we get a skew key in join. If we see more 568 than the specified number of rows with the same key in join operator, 569 we think the key as a skew join key. </description> 570 </property> 571 572 <property> 573 <name>hive.skewjoin.mapjoin.map.tasks</name> 574 <value>10000</value> 575 <description> Determine the number of map task used in the follow up map join job 576 for a skew join. It should be used together with hive.skewjoin.mapjoin.min.split 577 to perform a fine grained control.</description> 578 </property> 579 580 <property> 581 <name>hive.skewjoin.mapjoin.min.split</name> 582 <value>33554432</value> 583 <description> Determine the number of map task at most used in the follow up map join job 584 for a skew join by specifying the minimum split size. It should be used together with 585 hive.skewjoin.mapjoin.map.tasks to perform a fine grained control.</description> 586 </property> 587 588 <property> 589 <name>hive.mapred.mode</name> 590 <value>nonstrict</value> 591 <description>The mode in which the hive operations are being performed. 592 In strict mode, some risky queries are not allowed to run. They include: 593 Cartesian Product. 594 No partition being picked up for a query. 595 Comparing bigints and strings. 596 Comparing bigints and doubles. 597 Orderby without limit. 598 </description> 599 </property> 600 601 <property> 602 <name>hive.enforce.bucketmapjoin</name> 603 <value>false</value> 604 <description>If the user asked for bucketed map-side join, and it cannot be performed, 605 should the query fail or not ? For eg, if the buckets in the tables being joined are 606 not a multiple of each other, bucketed map-side join cannot be performed, and the 607 query will fail if hive.enforce.bucketmapjoin is set to true. 608 </description> 609 </property> 610 611 <property> 612 <name>hive.exec.script.maxerrsize</name> 613 <value>100000</value> 614 <description>Maximum number of bytes a script is allowed to emit to standard error (per map-reduce task). This prevents runaway scripts from filling logs partitions to capacity </description> 615 </property> 616 617 <property> 618 <name>hive.exec.script.allow.partial.consumption</name> 619 <value>false</value> 620 <description> When enabled, this option allows a user script to exit successfully without consuming all the data from the standard input. 621 </description> 622 </property> 623 624 <property> 625 <name>hive.script.operator.id.env.var</name> 626 <value>HIVE_SCRIPT_OPERATOR_ID</value> 627 <description> Name of the environment variable that holds the unique script operator ID in the user's transform function (the custom mapper/reducer that the user has specified in the query) 628 </description> 629 </property> 630 631 <property> 632 <name>hive.script.operator.truncate.env</name> 633 <value>false</value> 634 <description>Truncate each environment variable for external script in scripts operator to 20KB (to fit system limits)</description> 635 </property> 636 637 <property> 638 <name>hive.exec.compress.output</name> 639 <value>false</value> 640 <description> This controls whether the final outputs of a query (to a local/hdfs file or a hive table) is compressed. The compression codec and other options are determined from hadoop config variables mapred.output.compress* </description> 641 </property> 642 643 <property> 644 <name>hive.exec.compress.intermediate</name> 645 <value>false</value> 646 <description> This controls whether intermediate files produced by hive between multiple map-reduce jobs are compressed. The compression codec and other options are determined from hadoop config variables mapred.output.compress* </description> 647 </property> 648 649 <property> 650 <name>hive.exec.parallel</name> 651 <value>false</value> 652 <description>Whether to execute jobs in parallel</description> 653 </property> 654 655 <property> 656 <name>hive.exec.parallel.thread.number</name> 657 <value>8</value> 658 <description>How many jobs at most can be executed in parallel</description> 659 </property> 660 661 <property> 662 <name>hive.exec.rowoffset</name> 663 <value>false</value> 664 <description>Whether to provide the row offset virtual column</description> 665 </property> 666 667 <property> 668 <name>hive.task.progress</name> 669 <value>false</value> 670 <description>Whether Hive should periodically update task progress counters during execution. Enabling this allows task progress to be monitored more closely in the job tracker, but may impose a performance penalty. This flag is automatically set to true for jobs with hive.exec.dynamic.partition set to true.</description> 671 </property> 672 673 <property> 674 <name>hive.hwi.war.file</name> 675 <value>lib/hive-hwi-0.10.0.war</value> 676 <description>This sets the path to the HWI war file, relative to ${HIVE_HOME}. </description> 677 </property> 678 679 <property> 680 <name>hive.hwi.listen.host</name> 681 <value>0.0.0.0</value> 682 <description>This is the host address the Hive Web Interface will listen on</description> 683 </property> 684 685 <property> 686 <name>hive.hwi.listen.port</name> 687 <value>9999</value> 688 <description>This is the port the Hive Web Interface will listen on</description> 689 </property> 690 691 <property> 692 <name>hive.exec.pre.hooks</name> 693 <value></value> 694 <description>Comma-separated list of pre-execution hooks to be invoked for each statement. A pre-execution hook is specified as the name of a Java class which implements the org.apache.hadoop.hive.ql.hooks.ExecuteWithHookContext interface.</description> 695 </property> 696 697 <property> 698 <name>hive.exec.post.hooks</name> 699 <value></value> 700 <description>Comma-separated list of post-execution hooks to be invoked for each statement. A post-execution hook is specified as the name of a Java class which implements the org.apache.hadoop.hive.ql.hooks.ExecuteWithHookContext interface.</description> 701 </property> 702 703 <property> 704 <name>hive.exec.failure.hooks</name> 705 <value></value> 706 <description>Comma-separated list of on-failure hooks to be invoked for each statement. An on-failure hook is specified as the name of Java class which implements the org.apache.hadoop.hive.ql.hooks.ExecuteWithHookContext interface.</description> 707 </property> 708 709 <property> 710 <name>hive.client.stats.publishers</name> 711 <value></value> 712 <description>Comma-separated list of statistics publishers to be invoked on counters on each job. A client stats publisher is specified as the name of a Java class which implements the org.apache.hadoop.hive.ql.stats.ClientStatsPublisher interface.</description> 713 </property> 714 715 <property> 716 <name>hive.client.stats.counters</name> 717 <value></value> 718 <description>Subset of counters that should be of interest for hive.client.stats.publishers (when one wants to limit their publishing). Non-display names should be used</description> 719 </property> 720 721 <property> 722 <name>hive.merge.mapfiles</name> 723 <value>true</value> 724 <description>Merge small files at the end of a map-only job</description> 725 </property> 726 727 <property> 728 <name>hive.merge.mapredfiles</name> 729 <value>false</value> 730 <description>Merge small files at the end of a map-reduce job</description> 731 </property> 732 733 <property> 734 <name>hive.mergejob.maponly</name> 735 <value>true</value> 736 <description>Try to generate a map-only job for merging files if CombineHiveInputFormat is supported.</description> 737 </property> 738 739 <property> 740 <name>hive.heartbeat.interval</name> 741 <value>1000</value> 742 <description>Send a heartbeat after this interval - used by mapjoin and filter operators</description> 743 </property> 744 745 <property> 746 <name>hive.merge.size.per.task</name> 747 <value>256000000</value> 748 <description>Size of merged files at the end of the job</description> 749 </property> 750 751 <property> 752 <name>hive.merge.smallfiles.avgsize</name> 753 <value>16000000</value> 754 <description>When the average output file size of a job is less than this number, Hive will start an additional map-reduce job to merge the output files into bigger files. This is only done for map-only jobs if hive.merge.mapfiles is true, and for map-reduce jobs if hive.merge.mapredfiles is true.</description> 755 </property> 756 757 <property> 758 <name>hive.mapjoin.smalltable.filesize</name> 759 <value>25000000</value> 760 <description>The threshold for the input file size of the small tables; if the file size is smaller than this threshold, it will try to convert the common join into map join</description> 761 </property> 762 763 <property> 764 <name>hive.mapjoin.localtask.max.memory.usage</name> 765 <value>0.90</value> 766 <description>This number means how much memory the local task can take to hold the key/value into in-memory hash table; If the local task's memory usage is more than this number, the local task will be abort by themself. It means the data of small table is too large to be hold in the memory.</description> 767 </property> 768 769 <property> 770 <name>hive.mapjoin.followby.gby.localtask.max.memory.usage</name> 771 <value>0.55</value> 772 <description>This number means how much memory the local task can take to hold the key/value into in-memory hash table when this map join followed by a group by; If the local task's memory usage is more than this number, the local task will be abort by themself. It means the data of small table is too large to be hold in the memory.</description> 773 </property> 774 775 <property> 776 <name>hive.mapjoin.check.memory.rows</name> 777 <value>100000</value> 778 <description>The number means after how many rows processed it needs to check the memory usage</description> 779 </property> 780 781 <property> 782 <name>hive.auto.convert.join</name> 783 <value>false</value> 784 <description>Whether Hive enable the optimization about converting common join into mapjoin based on the input file size</description> 785 </property> 786 787 788 <property> 789 <name>hive.script.auto.progress</name> 790 <value>false</value> 791 <description>Whether Hive Tranform/Map/Reduce Clause should automatically send progress information to TaskTracker to avoid the task getting killed because of inactivity. Hive sends progress information when the script is outputting to stderr. This option removes the need of periodically producing stderr messages, but users should be cautious because this may prevent infinite loops in the scripts to be killed by TaskTracker. </description> 792 </property> 793 794 <property> 795 <name>hive.script.serde</name> 796 <value>org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe</value> 797 <description>The default serde for trasmitting input data to and reading output data from the user scripts. </description> 798 </property> 799 800 <property> 801 <name>hive.binary.record.max.length</name> 802 <value>1000</value> 803 <description>Read from a binary stream and treat each hive.binary.record.max.length bytes as a record. 804 The last record before the end of stream can have less than hive.binary.record.max.length bytes</description> 805 </property> 806 807 808 <property> 809 <name>hive.script.recordreader</name> 810 <value>org.apache.hadoop.hive.ql.exec.TextRecordReader</value> 811 <description>The default record reader for reading data from the user scripts. </description> 812 </property> 813 814 <property> 815 <name>hive.script.recordwriter</name> 816 <value>org.apache.hadoop.hive.ql.exec.TextRecordWriter</value> 817 <description>The default record writer for writing data to the user scripts. </description> 818 </property> 819 820 <property> 821 <name>hive.input.format</name> 822 <value>org.apache.hadoop.hive.ql.io.CombineHiveInputFormat</value> 823 <description>The default input format. Set this to HiveInputFormat if you encounter problems with CombineHiveInputFormat.</description> 824 </property> 825 826 <property> 827 <name>hive.udtf.auto.progress</name> 828 <value>false</value> 829 <description>Whether Hive should automatically send progress information to TaskTracker when using UDTF's to prevent the task getting killed because of inactivity. Users should be cautious because this may prevent TaskTracker from killing tasks with infinte loops. </description> 830 </property> 831 832 <property> 833 <name>hive.mapred.reduce.tasks.speculative.execution</name> 834 <value>true</value> 835 <description>Whether speculative execution for reducers should be turned on. </description> 836 </property> 837 838 <property> 839 <name>hive.exec.counters.pull.interval</name> 840 <value>1000</value> 841 <description>The interval with which to poll the JobTracker for the counters the running job. The smaller it is the more load there will be on the jobtracker, the higher it is the less granular the caught will be.</description> 842 </property> 843 844 <property> 845 <name>hive.querylog.location</name> 846 <value>/tmp/${user.name}</value> 847 <description> 848 Location of Hive run time structured log file 849 </description> 850 </property> 851 852 <property> 853 <name>hive.querylog.enable.plan.progress</name> 854 <value>true</value> 855 <description> 856 Whether to log the plan's progress every time a job's progress is checked. 857 These logs are written to the location specified by hive.querylog.location 858 </description> 859 </property> 860 861 <property> 862 <name>hive.querylog.plan.progress.interval</name> 863 <value>60000</value> 864 <description> 865 The interval to wait between logging the plan's progress in milliseconds. 866 If there is a whole number percentage change in the progress of the mappers or the reducers, 867 the progress is logged regardless of this value. 868 The actual interval will be the ceiling of (this value divided by the value of 869 hive.exec.counters.pull.interval) multiplied by the value of hive.exec.counters.pull.interval 870 I.e. if it is not divide evenly by the value of hive.exec.counters.pull.interval it will be 871 logged less frequently than specified. 872 This only has an effect if hive.querylog.enable.plan.progress is set to true. 873 </description> 874 </property> 875 876 <property> 877 <name>hive.enforce.bucketing</name> 878 <value>false</value> 879 <description>Whether bucketing is enforced. If true, while inserting into the table, bucketing is enforced. </description> 880 </property> 881 882 <property> 883 <name>hive.enforce.sorting</name> 884 <value>false</value> 885 <description>Whether sorting is enforced. If true, while inserting into the table, sorting is enforced. </description> 886 </property> 887 888 <property> 889 <name>hive.enforce.sortmergebucketmapjoin</name> 890 <value>false</value> 891 <description>If the user asked for sort-merge bucketed map-side join, and it cannot be performed, 892 should the query fail or not ? 893 </description> 894 </property> 895 896 <property> 897 <name>hive.metastore.ds.connection.url.hook</name> 898 <value></value> 899 <description>Name of the hook to use for retriving the JDO connection URL. If empty, the value in javax.jdo.option.ConnectionURL is used </description> 900 </property> 901 902 <property> 903 <name>hive.metastore.ds.retry.attempts</name> 904 <value>1</value> 905 <description>The number of times to retry a metastore call if there were a connection error</description> 906 </property> 907 908 <property> 909 <name>hive.metastore.ds.retry.interval</name> 910 <value>1000</value> 911 <description>The number of miliseconds between metastore retry attempts</description> 912 </property> 913 914 <property> 915 <name>hive.metastore.server.min.threads</name> 916 <value>200</value> 917 <description>Minimum number of worker threads in the Thrift server's pool.</description> 918 </property> 919 920 <property> 921 <name>hive.metastore.server.max.threads</name> 922 <value>100000</value> 923 <description>Maximum number of worker threads in the Thrift server's pool.</description> 924 </property> 925 926 <property> 927 <name>hive.metastore.server.tcp.keepalive</name> 928 <value>true</value> 929 <description>Whether to enable TCP keepalive for the metastore server. Keepalive will prevent accumulation of half-open connections.</description> 930 </property> 931 932 <property> 933 <name>hive.metastore.sasl.enabled</name> 934 <value>false</value> 935 <description>If true, the metastore thrift interface will be secured with SASL. Clients must authenticate with Kerberos.</description> 936 </property> 937 938 <property> 939 <name>hive.metastore.thrift.framed.transport.enabled</name> 940 <value>false</value> 941 <description>If true, the metastore thrift interface will use TFramedTransport. When false (default) a standard TTransport is used.</description> 942 </property> 943 944 <property> 945 <name>hive.metastore.kerberos.keytab.file</name> 946 <value></value> 947 <description>The path to the Kerberos Keytab file containing the metastore thrift server's service principal.</description> 948 </property> 949 950 <property> 951 <name>hive.metastore.kerberos.principal</name> 952 <value>hive-metastore/_HOST@EXAMPLE.COM</value> 953 <description>The service principal for the metastore thrift server. The special string _HOST will be replaced automatically with the correct host name.</description> 954 </property> 955 956 <property> 957 <name>hive.cluster.delegation.token.store.class</name> 958 <value>org.apache.hadoop.hive.thrift.MemoryTokenStore</value> 959 <description>The delegation token store implementation. Set to org.apache.hadoop.hive.thrift.ZooKeeperTokenStore for load-balanced cluster.</description> 960 </property> 961 962 <property> 963 <name>hive.cluster.delegation.token.store.zookeeper.connectString</name> 964 <value>localhost:2181</value> 965 <description>The ZooKeeper token store connect string.</description> 966 </property> 967 968 <property> 969 <name>hive.cluster.delegation.token.store.zookeeper.znode</name> 970 <value>/hive/cluster/delegation</value> 971 <description>The root path for token store data.</description> 972 </property> 973 974 <property> 975 <name>hive.cluster.delegation.token.store.zookeeper.acl</name> 976 <value>sasl:hive/host1@EXAMPLE.COM:cdrwa,sasl:hive/host2@EXAMPLE.COM:cdrwa</value> 977 <description>ACL for token store entries. List comma separated all server principals for the cluster.</description> 978 </property> 979 980 <property> 981 <name>hive.metastore.cache.pinobjtypes</name> 982 <value>Table,StorageDescriptor,SerDeInfo,Partition,Database,Type,FieldSchema,Order</value> 983 <description>List of comma separated metastore object types that should be pinned in the cache</description> 984 </property> 985 986 <property> 987 <name>hive.optimize.reducededuplication</name> 988 <value>true</value> 989 <description>Remove extra map-reduce jobs if the data is already clustered by the same key which needs to be used again. This should always be set to true. Since it is a new feature, it has been made configurable.</description> 990 </property> 991 992 <property> 993 <name>hive.exec.dynamic.partition</name> 994 <value>true</value> 995 <description>Whether or not to allow dynamic partitions in DML/DDL.</description> 996 </property> 997 998 <property> 999 <name>hive.exec.dynamic.partition.mode</name> 1000 <value>strict</value> 1001 <description>In strict mode, the user must specify at least one static partition in case the user accidentally overwrites all partitions.</description> 1002 </property> 1003 1004 <property> 1005 <name>hive.exec.max.dynamic.partitions</name> 1006 <value>1000</value> 1007 <description>Maximum number of dynamic partitions allowed to be created in total.</description> 1008 </property> 1009 1010 <property> 1011 <name>hive.exec.max.dynamic.partitions.pernode</name> 1012 <value>100</value> 1013 <description>Maximum number of dynamic partitions allowed to be created in each mapper/reducer node.</description> 1014 </property> 1015 1016 <property> 1017 <name>hive.exec.max.created.files</name> 1018 <value>100000</value> 1019 <description>Maximum number of HDFS files created by all mappers/reducers in a MapReduce job.</description> 1020 </property> 1021 1022 <property> 1023 <name>hive.exec.default.partition.name</name> 1024 <value>__HIVE_DEFAULT_PARTITION__</value> 1025 <description>The default partition name in case the dynamic partition column value is null/empty string or anyother values that cannot be escaped. This value must not contain any special character used in HDFS URI (e.g., ':', '%', '/' etc). The user has to be aware that the dynamic partition value should not contain this value to avoid confusions.</description> 1026 </property> 1027 1028 <property> 1029 <name>hive.stats.dbclass</name> 1030 <value>jdbc:derby</value> 1031 <description>The default database that stores temporary hive statistics.</description> 1032 </property> 1033 1034 <property> 1035 <name>hive.stats.autogather</name> 1036 <value>true</value> 1037 <description>A flag to gather statistics automatically during the INSERT OVERWRITE command.</description> 1038 </property> 1039 1040 <property> 1041 <name>hive.stats.jdbcdriver</name> 1042 <value>org.apache.derby.jdbc.EmbeddedDriver</value> 1043 <description>The JDBC driver for the database that stores temporary hive statistics.</description> 1044 </property> 1045 1046 <property> 1047 <name>hive.stats.dbconnectionstring</name> 1048 <value>jdbc:derby:;databaseName=TempStatsStore;create=true</value> 1049 <description>The default connection string for the database that stores temporary hive statistics.</description> 1050 </property> 1051 1052 <property> 1053 <name>hive.stats.default.publisher</name> 1054 <value></value> 1055 <description>The Java class (implementing the StatsPublisher interface) that is used by default if hive.stats.dbclass is not JDBC or HBase.</description> 1056 </property> 1057 1058 <property> 1059 <name>hive.stats.default.aggregator</name> 1060 <value></value> 1061 <description>The Java class (implementing the StatsAggregator interface) that is used by default if hive.stats.dbclass is not JDBC or HBase.</description> 1062 </property> 1063 1064 <property> 1065 <name>hive.stats.jdbc.timeout</name> 1066 <value>30</value> 1067 <description>Timeout value (number of seconds) used by JDBC connection and statements.</description> 1068 </property> 1069 1070 <property> 1071 <name>hive.stats.retries.max</name> 1072 <value>0</value> 1073 <description>Maximum number of retries when stats publisher/aggregator got an exception updating intermediate database. Default is no tries on failures.</description> 1074 </property> 1075 1076 <property> 1077 <name>hive.stats.retries.wait</name> 1078 <value>3000</value> 1079 <description>The base waiting window (in milliseconds) before the next retry. The actual wait time is calculated by baseWindow * failues + baseWindow * (failure + 1) * (random number between [0.0,1.0]).</description> 1080 </property> 1081 1082 <property> 1083 <name>hive.stats.reliable</name> 1084 <value>false</value> 1085 <description>Whether queries will fail because stats cannot be collected completely accurately. 1086 If this is set to true, reading/writing from/into a partition may fail becuase the stats 1087 could not be computed accurately. 1088 </description> 1089 </property> 1090 1091 <property> 1092 <name>hive.stats.collect.tablekeys</name> 1093 <value>false</value> 1094 <description>Whether join and group by keys on tables are derived and maintained in the QueryPlan. 1095 This is useful to identify how tables are accessed and to determine if they should be bucketed. 1096 </description> 1097 </property> 1098 1099 <property> 1100 <name>hive.stats.ndv.error</name> 1101 <value>20.0</value> 1102 <description>Standard error expressed in percentage. Provides a tradeoff between accuracy and compute cost.A lower value for error indicates higher accuracy and a higher compute cost. 1103 </description> 1104 </property> 1105 1106 <property> 1107 <name>hive.support.concurrency</name> 1108 <value>false</value> 1109 <description>Whether hive supports concurrency or not. A zookeeper instance must be up and running for the default hive lock manager to support read-write locks.</description> 1110 </property> 1111 1112 <property> 1113 <name>hive.lock.numretries</name> 1114 <value>100</value> 1115 <description>The number of times you want to try to get all the locks</description> 1116 </property> 1117 1118 <property> 1119 <name>hive.unlock.numretries</name> 1120 <value>10</value> 1121 <description>The number of times you want to retry to do one unlock</description> 1122 </property> 1123 1124 <property> 1125 <name>hive.lock.sleep.between.retries</name> 1126 <value>60</value> 1127 <description>The sleep time (in seconds) between various retries</description> 1128 </property> 1129 1130 <property> 1131 <name>hive.zookeeper.quorum</name> 1132 <value></value> 1133 <description>The list of zookeeper servers to talk to. This is only needed for read/write locks.</description> 1134 </property> 1135 1136 <property> 1137 <name>hive.zookeeper.client.port</name> 1138 <value>2181</value> 1139 <description>The port of zookeeper servers to talk to. This is only needed for read/write locks.</description> 1140 </property> 1141 1142 <property> 1143 <name>hive.zookeeper.session.timeout</name> 1144 <value>600000</value> 1145 <description>Zookeeper client's session timeout. The client is disconnected, and as a result, all locks released, if a heartbeat is not sent in the timeout.</description> 1146 </property> 1147 1148 <property> 1149 <name>hive.zookeeper.namespace</name> 1150 <value>hive_zookeeper_namespace</value> 1151 <description>The parent node under which all zookeeper nodes are created.</description> 1152 </property> 1153 1154 <property> 1155 <name>hive.zookeeper.clean.extra.nodes</name> 1156 <value>false</value> 1157 <description>Clean extra nodes at the end of the session.</description> 1158 </property> 1159 1160 <property> 1161 <name>fs.har.impl</name> 1162 <value>org.apache.hadoop.hive.shims.HiveHarFileSystem</value> 1163 <description>The implementation for accessing Hadoop Archives. Note that this won't be applicable to Hadoop vers less than 0.20</description> 1164 </property> 1165 1166 <property> 1167 <name>hive.archive.enabled</name> 1168 <value>false</value> 1169 <description>Whether archiving operations are permitted</description> 1170 </property> 1171 1172 <property> 1173 <name>hive.fetch.output.serde</name> 1174 <value>org.apache.hadoop.hive.serde2.DelimitedJSONSerDe</value> 1175 <description>The serde used by FetchTask to serialize the fetch output.</description> 1176 </property> 1177 1178 <property> 1179 <name>hive.exec.mode.local.auto</name> 1180 <value>false</value> 1181 <description> Let hive determine whether to run in local mode automatically </description> 1182 </property> 1183 1184 <property> 1185 <name>hive.exec.drop.ignorenonexistent</name> 1186 <value>true</value> 1187 <description> 1188 Do not report an error if DROP TABLE/VIEW specifies a non-existent table/view 1189 </description> 1190 </property> 1191 1192 <property> 1193 <name>hive.exec.show.job.failure.debug.info</name> 1194 <value>true</value> 1195 <description> 1196 If a job fails, whether to provide a link in the CLI to the task with the 1197 most failures, along with debugging hints if applicable. 1198 </description> 1199 </property> 1200 1201 <property> 1202 <name>hive.auto.progress.timeout</name> 1203 <value>0</value> 1204 <description> 1205 How long to run autoprogressor for the script/UDTF operators (in seconds). 1206 Set to 0 for forever. 1207 </description> 1208 </property> 1209 1210 <!-- HBase Storage Handler Parameters --> 1211 1212 <property> 1213 <name>hive.hbase.wal.enabled</name> 1214 <value>true</value> 1215 <description>Whether writes to HBase should be forced to the write-ahead log. Disabling this improves HBase write performance at the risk of lost writes in case of a crash.</description> 1216 </property> 1217 1218 <property> 1219 <name>hive.table.parameters.default</name> 1220 <value></value> 1221 <description>Default property values for newly created tables</description> 1222 </property> 1223 1224 <property> 1225 <name>hive.entity.separator</name> 1226 <value>@</value> 1227 <description>Separator used to construct names of tables and partitions. For example, dbname@tablename@partitionname</description> 1228 </property> 1229 1230 <property> 1231 <name>hive.ddl.createtablelike.properties.whitelist</name> 1232 <value></value> 1233 <description>Table Properties to copy over when executing a Create Table Like.</description> 1234 </property> 1235 1236 <property> 1237 <name>hive.variable.substitute</name> 1238 <value>true</value> 1239 <description>This enables substitution using syntax like ${var} ${system:var} and ${env:var}.</description> 1240 </property> 1241 1242 <property> 1243 <name>hive.variable.substitute.depth</name> 1244 <value>40</value> 1245 <description>The maximum replacements the substitution engine will do.</description> 1246 </property> 1247 1248 <property> 1249 <name>hive.conf.validation</name> 1250 <value>true</value> 1251 <description>Eables type checking for registered hive configurations</description> 1252 </property> 1253 1254 <property> 1255 <name>hive.security.authorization.enabled</name> 1256 <value>false</value> 1257 <description>enable or disable the hive client authorization</description> 1258 </property> 1259 1260 <property> 1261 <name>hive.security.authorization.manager</name> 1262 <value>org.apache.hadoop.hive.ql.security.authorization.DefaultHiveAuthorizationProvider</value> 1263 <description>the hive client authorization manager class name. 1264 The user defined authorization class should implement interface org.apache.hadoop.hive.ql.security.authorization.HiveAuthorizationProvider. 1265 </description> 1266 </property> 1267 1268 <property> 1269 <name>hive.security.metastore.authorization.manager</name> 1270 <value>org.apache.hadoop.hive.ql.security.authorization.DefaultHiveMetastoreAuthorizationProvider</value> 1271 <description>authorization manager class name to be used in the metastore for authorization. 1272 The user defined authorization class should implement interface org.apache.hadoop.hive.ql.security.authorization.HiveMetastoreAuthorizationProvider. 1273 </description> 1274 </property> 1275 1276 <property> 1277 <name>hive.security.metastore.authorization.manager</name> 1278 <value>org.apache.hadoop.hive.ql.security.authorization.DefaultHiveMetastoreAuthorizationProvider</value> 1279 <description>authorization manager class name to be used in the metastore for authorization. 1280 The user defined authorization class should implement interface org.apache.hadoop.hive.ql.security.authorization.HiveMetastoreAuthorizationProvider. 1281 </description> 1282 </property> 1283 1284 <property> 1285 <name>hive.security.authenticator.manager</name> 1286 <value>org.apache.hadoop.hive.ql.security.HadoopDefaultAuthenticator</value> 1287 <description>hive client authenticator manager class name. 1288 The user defined authenticator should implement interface org.apache.hadoop.hive.ql.security.HiveAuthenticationProvider.</description> 1289 </property> 1290 1291 <property> 1292 <name>hive.security.metastore.authenticator.manager</name> 1293 <value>org.apache.hadoop.hive.ql.security.HadoopDefaultMetastoreAuthenticator</value> 1294 <description>authenticator manager class name to be used in the metastore for authentication. 1295 The user defined authenticator should implement interface org.apache.hadoop.hive.ql.security.HiveAuthenticationProvider.</description> 1296 </property> 1297 1298 <property> 1299 <name>hive.security.metastore.authenticator.manager</name> 1300 <value>org.apache.hadoop.hive.ql.security.HadoopDefaultMetastoreAuthenticator</value> 1301 <description>authenticator manager class name to be used in the metastore for authentication. 1302 The user defined authenticator should implement interface org.apache.hadoop.hive.ql.security.HiveAuthenticationProvider.</description> 1303 </property> 1304 1305 <property> 1306 <name>hive.security.authorization.createtable.user.grants</name> 1307 <value></value> 1308 <description>the privileges automatically granted to some users whenever a table gets created. 1309 An example like "userX,userY:select;userZ:create" will grant select privilege to userX and userY, 1310 and grant create privilege to userZ whenever a new table created.</description> 1311 </property> 1312 1313 <property> 1314 <name>hive.security.authorization.createtable.group.grants</name> 1315 <value></value> 1316 <description>the privileges automatically granted to some groups whenever a table gets created. 1317 An example like "groupX,groupY:select;groupZ:create" will grant select privilege to groupX and groupY, 1318 and grant create privilege to groupZ whenever a new table created.</description> 1319 </property> 1320 1321 <property> 1322 <name>hive.security.authorization.createtable.role.grants</name> 1323 <value></value> 1324 <description>the privileges automatically granted to some roles whenever a table gets created. 1325 An example like "roleX,roleY:select;roleZ:create" will grant select privilege to roleX and roleY, 1326 and grant create privilege to roleZ whenever a new table created.</description> 1327 </property> 1328 1329 <property> 1330 <name>hive.security.authorization.createtable.owner.grants</name> 1331 <value></value> 1332 <description>the privileges automatically granted to the owner whenever a table gets created. 1333 An example like "select,drop" will grant select and drop privilege to the owner of the table</description> 1334 </property> 1335 1336 <property> 1337 <name>hive.metastore.authorization.storage.checks</name> 1338 <value>false</value> 1339 <description>Should the metastore do authorization checks against the underlying storage 1340 for operations like drop-partition (disallow the drop-partition if the user in 1341 question doesn't have permissions to delete the corresponding directory 1342 on the storage).</description> 1343 </property> 1344 1345 <property> 1346 <name>hive.error.on.empty.partition</name> 1347 <value>false</value> 1348 <description>Whether to throw an excpetion if dynamic partition insert generates empty results.</description> 1349 </property> 1350 1351 <property> 1352 <name>hive.index.compact.file.ignore.hdfs</name> 1353 <value>false</value> 1354 <description>True the hdfs location stored in the index file will be igbored at runtime. 1355 If the data got moved or the name of the cluster got changed, the index data should still be usable.</description> 1356 </property> 1357 1358 <property> 1359 <name>hive.optimize.index.filter.compact.minsize</name> 1360 <value>5368709120</value> 1361 <description>Minimum size (in bytes) of the inputs on which a compact index is automatically used.</description> 1362 </property> 1363 1364 <property> 1365 <name>hive.optimize.index.filter.compact.maxsize</name> 1366 <value>-1</value> 1367 <description>Maximum size (in bytes) of the inputs on which a compact index is automatically used. 1368 A negative number is equivalent to infinity.</description> 1369 </property> 1370 1371 <property> 1372 <name>hive.index.compact.query.max.size</name> 1373 <value>10737418240</value> 1374 <description>The maximum number of bytes that a query using the compact index can read. Negative value is equivalent to infinity.</description> 1375 </property> 1376 1377 <property> 1378 <name>hive.index.compact.query.max.entries</name> 1379 <value>10000000</value> 1380 <description>The maximum number of index entries to read during a query that uses the compact index. Negative value is equivalent to infinity.</description> 1381 </property> 1382 1383 <property> 1384 <name>hive.index.compact.binary.search</name> 1385 <value>true</value> 1386 <description>Whether or not to use a binary search to find the entries in an index table that match the filter, where possible</description> 1387 </property> 1388 1389 <property> 1390 <name>hive.exim.uri.scheme.whitelist</name> 1391 <value>hdfs,pfile</value> 1392 <description>A comma separated list of acceptable URI schemes for import and export.</description> 1393 </property> 1394 1395 <property> 1396 <name>hive.lock.mapred.only.operation</name> 1397 <value>false</value> 1398 <description>This param is to control whether or not only do lock on queries 1399 that need to execute at least one mapred job.</description> 1400 </property> 1401 1402 <property> 1403 <name>hive.limit.row.max.size</name> 1404 <value>100000</value> 1405 <description>When trying a smaller subset of data for simple LIMIT, how much size we need to guarantee 1406 each row to have at least.</description> 1407 </property> 1408 1409 <property> 1410 <name>hive.limit.optimize.limit.file</name> 1411 <value>10</value> 1412 <description>When trying a smaller subset of data for simple LIMIT, maximum number of files we can 1413 sample.</description> 1414 </property> 1415 1416 <property> 1417 <name>hive.limit.optimize.enable</name> 1418 <value>false</value> 1419 <description>Whether to enable to optimization to trying a smaller subset of data for simple LIMIT first.</description> 1420 </property> 1421 1422 <property> 1423 <name>hive.limit.optimize.fetch.max</name> 1424 <value>50000</value> 1425 <description>Maximum number of rows allowed for a smaller subset of data for simple LIMIT, if it is a fetch query. 1426 Insert queries are not restricted by this limit.</description> 1427 </property> 1428 1429 <property> 1430 <name>hive.rework.mapredwork</name> 1431 <value>false</value> 1432 <description>should rework the mapred work or not. 1433 This is first introduced by SymlinkTextInputFormat to replace symlink files with real paths at compile time.</description> 1434 </property> 1435 1436 <property> 1437 <name>hive.exec.concatenate.check.index</name> 1438 <value>true</value> 1439 <description>If this sets to true, hive will throw error when doing 1440 'alter table tbl_name [partSpec] concatenate' on a table/partition 1441 that has indexes on it. The reason the user want to set this to true 1442 is because it can help user to avoid handling all index drop, recreation, 1443 rebuild work. This is very helpful for tables with thousands of partitions.</description> 1444 </property> 1445 1446 <property> 1447 <name>hive.sample.seednumber</name> 1448 <value>0</value> 1449 <description>A number used to percentage sampling. By changing this number, user will change the subsets 1450 of data sampled.</description> 1451 </property> 1452 1453 <property> 1454 <name>hive.io.exception.handlers</name> 1455 <value></value> 1456 <description>A list of io exception handler class names. This is used 1457 to construct a list exception handlers to handle exceptions thrown 1458 by record readers</description> 1459 </property> 1460 1461 <property> 1462 <name>hive.autogen.columnalias.prefix.label</name> 1463 <value>_c</value> 1464 <description>String used as a prefix when auto generating column alias. 1465 By default the prefix label will be appended with a column position number to form the column alias. Auto generation would happen if an aggregate function is used in a select clause without an explicit alias.</description> 1466 </property> 1467 1468 <property> 1469 <name>hive.autogen.columnalias.prefix.includefuncname</name> 1470 <value>false</value> 1471 <description>Whether to include function name in the column alias auto generated by hive.</description> 1472 </property> 1473 1474 <property> 1475 <name>hive.exec.perf.logger</name> 1476 <value>org.apache.hadoop.hive.ql.log.PerfLogger</value> 1477 <description>The class responsible logging client side performance metrics. Must be a subclass of org.apache.hadoop.hive.ql.log.PerfLogger</description> 1478 </property> 1479 1480 <property> 1481 <name>hive.start.cleanup.scratchdir</name> 1482 <value>false</value> 1483 <description>To cleanup the hive scratchdir while starting the hive server</description> 1484 </property> 1485 1486 <property> 1487 <name>hive.output.file.extension</name> 1488 <value></value> 1489 <description>String used as a file extension for output files. If not set, defaults to the codec extension for text files (e.g. ".gz"), or no extension otherwise.</description> 1490 </property> 1491 1492 <property> 1493 <name>hive.insert.into.multilevel.dirs</name> 1494 <value>false</value> 1495 <description>Where to insert into multilevel directories like 1496 "insert directory '/HIVEFT25686/chinna/' from table"</description> 1497 </property> 1498 1499 <property> 1500 <name>hive.warehouse.subdir.inherit.perms</name> 1501 <value>false</value> 1502 <description>Set this to true if the the table directories should inherit the 1503 permission of the warehouse or database directory instead of being created 1504 with the permissions derived from dfs umask</description> 1505 </property> 1506 1507 <property> 1508 <name>hive.exec.job.debug.capture.stacktraces</name> 1509 <value>true</value> 1510 <description>Whether or not stack traces parsed from the task logs of a sampled failed task for 1511 each failed job should be stored in the SessionState 1512 </description> 1513 </property> 1514 1515 <property> 1516 <name>hive.exec.driver.run.hooks</name> 1517 <value></value> 1518 <description>A comma separated list of hooks which implement HiveDriverRunHook and will be run at the 1519 beginning and end of Driver.run, these will be run in the order specified 1520 </description> 1521 </property> 1522 1523 <property> 1524 <name>hive.ddl.output.format</name> 1525 <value>text</value> 1526 <description> 1527 The data format to use for DDL output. One of "text" (for human 1528 readable text) or "json" (for a json object). 1529 </description> 1530 </property> 1531 1532 <property> 1533 <name>hive.transform.escape.input</name> 1534 <value>false</value> 1535 <description> 1536 This adds an option to escape special chars (newlines, carriage returns and 1537 tabs) when they are passed to the user script. This is useful if the hive tables 1538 can contain data that contains special characters. 1539 </description> 1540 </property> 1541 1542 <property> 1543 <name>hive.exec.rcfile.use.explicit.header</name> 1544 <value>true</value> 1545 <description> 1546 If this is set the header for RC Files will simply be RCF. If this is not 1547 set the header will be that borrowed from sequence files, e.g. SEQ- followed 1548 by the input and output RC File formats. 1549 </description> 1550 </property> 1551 1552 <property> 1553 <name>hive.multi.insert.move.tasks.share.dependencies</name> 1554 <value>false</value> 1555 <description> 1556 If this is set all move tasks for tables/partitions (not directories) at the end of a 1557 multi-insert query will only begin once the dependencies for all these move tasks have been 1558 met. 1559 Advantages: If concurrency is enabled, the locks will only be released once the query has 1560 finished, so with this config enabled, the time when the table/partition is 1561 generated will be much closer to when the lock on it is released. 1562 Disadvantages: If concurrency is not enabled, with this disabled, the tables/partitions which 1563 are produced by this query and finish earlier will be available for querying 1564 much earlier. Since the locks are only released once the query finishes, this 1565 does not apply if concurrency is enabled. 1566 </description> 1567 </property> 1568 1569 <property> 1570 <name>hive.fetch.task.conversion</name> 1571 <value>minimal</value> 1572 <description> 1573 Some select queries can be converted to single FETCH task minimizing latency. 1574 Currently the query should be single sourced not having any subquery and should not have 1575 any aggregations or distincts (which incurrs RS), lateral views and joins. 1576 1. minimal : SELECT STAR, FILTER on partition columns, LIMIT only 1577 2. more : SELECT, FILTER, LIMIT only (+TABLESAMPLE, virtual columns) 1578 </description> 1579 </property> 1580 1581 <property> 1582 <name>hive.hmshandler.retry.attempts</name> 1583 <value>1</value> 1584 <description>The number of times to retry a HMSHandler call if there were a connection error</description> 1585 </property> 1586 1587 <property> 1588 <name>hive.hmshandler.retry.interval</name> 1589 <value>1000</value> 1590 <description>The number of miliseconds between HMSHandler retry attempts</description> 1591 </property> 1592 1593 1594 <property> 1595 <name>hive.server.read.socket.timeout</name> 1596 <value>10</value> 1597 <description>Timeout for the HiveServer to close the connection if no response from the client in N seconds, defaults to 10 seconds.</description> 1598 </property> 1599 1600 <property> 1601 <name>hive.server.tcp.keepalive</name> 1602 <value>true</value> 1603 <description>Whether to enable TCP keepalive for the Hive server. Keepalive will prevent accumulation of half-open connections.</description> 1604 </property> 1605 <!--zhangziliang--> 1606 <property> 1607 <name>hive.aux.jars.path</name> 1608 <value>file:///home/hadoop/source/hive/lib/hive-hbase-handler-0.10.0.jar,file:///home/hadoop/source/hive/lib/hbase-0.94.0.jar,file:///home/hadoop/source/hive/lib/zookeeper-3.4.3.jar</value> 1609 </property> 1610 </configuration> View Code 3.3 新增配置属性-hive.aux.jars.path 1 <property> 2 <name>hive.aux.jars.path</name> 3 <value>file:///home/hadoop/source/hive/lib/hive-hbase-handler-0.10.0.jar,file:///home/hadoop/source/hive/lib/hbase-0.94.0.jar,file:///home/hadoop/source/hive/lib/zookeeper-3.4.3.jar</value> 4 </property> 3.4 拷贝Jar包到Hive/lib目录 hbase-0.94.0.jar,zookeeper-3.4.3.jar 四、测试脚本-创建HBase能够识别的数据表 1 CREATE TABLE hbase_table_1(key int, value string) 2 STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler' 3 WITH SERDEPROPERTIES ("hbase.columns.mapping" = ":key,cf1:val") 4 TBLPROPERTIES ("hbase.table.name" = "xyz"); 五、异常解决 5.1 错误提示 java.lang.NoClassDefFoundError: com/google/protobuf/Message at org.apache.hadoop.hbase.io.HbaseObjectWritable.(HbaseObjectWritable.java … 5.2 解决方案 将$HBASE_HOME/lib/protobuf-java-2.4.0a.jar 拷贝到 $HIVE_HOME/lib/. 六、运行效果 [hadoop@hadoop1 lib]$ hive -hiveconf hbase.zookeeper.quorum=hadoop1 WARNING: org.apache.hadoop.metrics.jvm.EventCounter is deprecated. Please use org.apache.hadoop.log.metrics.EventCounter in all the log4j.properties files. Logging initialized using configuration in jar:file:/home/hadoop/source/hive/lib/hive-common-0.10.0.jar!/hive-log4j.properties Hive history file=/tmp/hadoop/hive_job_log_hadoop_201401012315_758621762.txt hive> CREATE TABLE hbase_table_1(key int, value string) > STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler' > WITH SERDEPROPERTIES ("hbase.columns.mapping" = ":key,cf1:val") > TBLPROPERTIES ("hbase.table.name" = "xyz"); OK Time taken: 23.246 seconds hive> show tables; OK hbase_table_1 Time taken: 1.346 seconds 作者:张子良 出处:http://www.cnblogs.com/hadoopdev 本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。

优秀的个人博客,低调大师

大数据应用之HBase数据插入性能优化实测教程

引言: 大家在使用HBase的过程中,总是面临性能优化的问题,本文从HBase客户端参数设置的角度,研究HBase客户端数据批量插入性能优化的问题。事实胜于雄辩,数据比理论更有说服力,基于此,作者设计了这么一个HBase数据插入性能优化实测实验,希望大家用自己的服务器跑出的结果,给自己一个值得信服的结论。 一、客户单优化参数 1.Put List Size HBase的Put支持单条插入,也支持批量插入。 2. AutoFlush AutoFlush指的是在每次调用HBase的Put操作,是否提交到HBase Server。 默认是true,每次会提交。如果此时是单条插入,就会有更多的IO,从而降低性能 3.Write Buffer Size Write Buffer Size在AutoFlush为false的时候起作用,默认是2MB,也就是当插入数据超过2MB,就会自动提交到Server 4.WAL WAL是Write Ahead Log的缩写,指的是HBase在插入操作前是否写Log。默认是打开,关掉会提高性能,但是如果系统出现故障(负责插入的Region Server 挂掉),数据可能会丢失。 参数 默认值 说明 JVM Heap Size 平台不同值不同自行设置 AutoFlush True 默认逐条提交 Put List Size 1 支持逐条和批量 Write Buffer Size 2M 与autoflush配合使用 Write Ahead Log True 默认开启,需要手动关闭 … … 二、源码程序 1 import java.io.IOException; 2 import java.util.ArrayList; 3 import java.util.List; 4 import java.util.Random; 5 6 import org.apache.hadoop.conf.Configuration; 7 import org.apache.hadoop.hbase.HBaseConfiguration; 8 import org.apache.hadoop.hbase.HColumnDescriptor; 9 import org.apache.hadoop.hbase.HTableDescriptor; 10 import org.apache.hadoop.hbase.KeyValue; 11 import org.apache.hadoop.hbase.MasterNotRunningException; 12 import org.apache.hadoop.hbase.ZooKeeperConnectionException; 13 import org.apache.hadoop.hbase.client.Delete; 14 import org.apache.hadoop.hbase.client.Get; 15 import org.apache.hadoop.hbase.client.HBaseAdmin; 16 import org.apache.hadoop.hbase.client.HTable; 17 import org.apache.hadoop.hbase.client.Result; 18 import org.apache.hadoop.hbase.client.ResultScanner; 19 import org.apache.hadoop.hbase.client.Scan; 20 import org.apache.hadoop.hbase.client.Put; 21 import org.apache.hadoop.hbase.util.Bytes; 22 23 /* 24 * -------优化案例说明------------ 25 * 1.优化参数1:Autoflush 默认关闭,需要手动开启 26 * 2.优化参数2:put list size 支持单条与批量 27 * 3.优化参数3:JVM heap size 默认值是平台而不同,需要手动设置 28 * 4.优化参数4:Write Buffer Size 默认值2M 29 * 5.优化参数5:Write Ahead Log 默认开启,需要手动关闭 30 * */ 31 32 public class TestInsert { 33 static Configuration hbaseConfig = null; 34 35 public static void main(String[] args) throws Exception { 36 Configuration HBASE_CONFIG = new Configuration(); 37 HBASE_CONFIG.set("hbase.master", "192.168.230.133:60000"); 38 HBASE_CONFIG.set("hbase.zookeeper.quorum", "192.168.230.133"); 39 HBASE_CONFIG.set("hbase.zookeeper.property.clientPort", "2181"); 40 hbaseConfig = HBaseConfiguration.create(HBASE_CONFIG); 41 //关闭wal,autoflush,writebuffer = 24M 42 insert(false,false,1024*1024*24); 43 //开启AutoFlush,writebuffer = 0 44 insert(false,true,0); 45 //默认值,全部开启 46 insert(true,true,0); 47 } 48 49 private static void insert(boolean wal,boolean autoFlush,long writeBuffer) 50 throws IOException { 51 String tableName="etltest"; 52 HBaseAdmin hAdmin = new HBaseAdmin(hbaseConfig); 53 if (hAdmin.tableExists(tableName)) { 54 hAdmin.disableTable(tableName); 55 hAdmin.deleteTable(tableName); 56 } 57 58 HTableDescriptor t = new HTableDescriptor(tableName); 59 t.addFamily(new HColumnDescriptor("f1")); 60 t.addFamily(new HColumnDescriptor("f2")); 61 t.addFamily(new HColumnDescriptor("f3")); 62 t.addFamily(new HColumnDescriptor("f4")); 63 hAdmin.createTable(t); 64 System.out.println("table created"); 65 66 HTable table = new HTable(hbaseConfig, tableName); 67 table.setAutoFlush(autoFlush); 68 if(writeBuffer!=0){ 69 table.setWriteBufferSize(writeBuffer); 70 } 71 List<Put> lp = new ArrayList<Put>(); 72 long all = System.currentTimeMillis(); 73 74 System.out.println("start time = "+all); 75 int count = 20000; 76 byte[] buffer = new byte[128]; 77 Random r = new Random(); 78 for (int i = 1; i <= count; ++i) { 79 Put p = new Put(String.format("row d",i).getBytes()); 80 r.nextBytes(buffer); 81 p.add("f1".getBytes(), null, buffer); 82 p.add("f2".getBytes(), null, buffer); 83 p.add("f3".getBytes(), null, buffer); 84 p.add("f4".getBytes(), null, buffer); 85 p.setWriteToWAL(wal); 86 lp.add(p); 87 if(i%1000 == 0){ 88 table.put(lp); 89 lp.clear(); 90 } 91 } 92 93 System.out.println("WAL="+wal+",autoFlush="+autoFlush+",buffer="+writeBuffer+",count="+count); 94 long end = System.currentTimeMillis(); 95 System.out.println("total need time = "+ (end - all)*1.0/1000+"s"); 96 97 98 System.out.println("insert complete"+",costs:"+(System.currentTimeMillis()-all)*1.0/1000+"ms"); 99 } 100 } 三、集群配置 3.1 服务器硬件配置清单 序号 节点名称 CUP 内存 硬盘 带宽 1 HMaster 2 HregionServer1 3 HregionServer2 4 … 5 6 7 3.2 客户端硬件配置清单 设备 节点名称 Cpu 内存 硬盘 带宽 四、测试报告 数据量 JVM AutoFlush Put List Size WriteBufferSize WAL 耗时 1000 512m false 1000 1024*1024*24 false 2000 5000 10000 20000 50000 100000 200000 500000 100000 备注:该技术专题讨论正在群Hadoop高级交流群:293503507同步直播中,敬请关注。 作者:张子良 出处:http://www.cnblogs.com/hadoopdev 本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。

资源下载

更多资源
优质分享App

优质分享App

近一个月的开发和优化,本站点的第一个app全新上线。该app采用极致压缩,本体才4.36MB。系统里面做了大量数据访问、缓存优化。方便用户在手机上查看文章。后续会推出HarmonyOS的适配版本。

Spring

Spring

Spring框架(Spring Framework)是由Rod Johnson于2002年提出的开源Java企业级应用框架,旨在通过使用JavaBean替代传统EJB实现方式降低企业级编程开发的复杂性。该框架基于简单性、可测试性和松耦合性设计理念,提供核心容器、应用上下文、数据访问集成等模块,支持整合Hibernate、Struts等第三方框架,其适用范围不仅限于服务器端开发,绝大多数Java应用均可从中受益。

Rocky Linux

Rocky Linux

Rocky Linux(中文名:洛基)是由Gregory Kurtzer于2020年12月发起的企业级Linux发行版,作为CentOS稳定版停止维护后与RHEL(Red Hat Enterprise Linux)完全兼容的开源替代方案,由社区拥有并管理,支持x86_64、aarch64等架构。其通过重新编译RHEL源代码提供长期稳定性,采用模块化包装和SELinux安全架构,默认包含GNOME桌面环境及XFS文件系统,支持十年生命周期更新。

Sublime Text

Sublime Text

Sublime Text具有漂亮的用户界面和强大的功能,例如代码缩略图,Python的插件,代码段等。还可自定义键绑定,菜单和工具栏。Sublime Text 的主要功能包括:拼写检查,书签,完整的 Python API , Goto 功能,即时项目切换,多选择,多窗口等等。Sublime Text 是一个跨平台的编辑器,同时支持Windows、Linux、Mac OS X等操作系统。

用户登录
用户注册
修改密码
忘记密码