1. 启动hbase-indexer服务

nohup ./hbase-indexer server -z s1:,s2:,s3:,s4:,s5: > /work/hbase-indexer.log &
  • 参数说明
    1. -z hbase-indexer要用到的zooKeeper的链接信息
    2. /work/hbase-indexer.log 输出日志文件路径

2. 添加索引

./hbase-indexer add-indexer -n indexer_vip -c /opt/lucidworks-hdpsearch/hbase-indexer/demo/vip_indexer_mapper.xml -cp solr.zk=s1:,s2:,s3:,s4:,s5:/solr -cp solr.collection=collection_vip
  • 参数说明
    1. -indexer 动作命令
    2. -n 要创建的索引名称参数,indexer_vip 索引名称
    3. -c 索引映射文件路径
    4. solr.zk zooKeeper 链接信息
    5. solr.collection 索引映射的集合信息,collection_vip 集合名称
    • 映射文件示例
    <xml version="1.0" encoding="UTF-8"?>
    <!--
    /*
    * Copyright 2013 NGDATA nv
    *
    * Licensed under the Apache License, Version 2.0 (the "License");
    * you may not use this file except in compliance with the License.
    * You may obtain a copy of the License at
    *
    * http://www.apache.org/licenses/LICENSE-2.0
    *
    * Unless required by applicable law or agreed to in writing, software
    * distributed under the License is distributed on an "AS IS" BASIS,
    * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    * See the License for the specific language governing permissions and
    * limitations under the License.
    */
    -->
    <indexer table="BizvaneV2.Vip" mapper="com.ngdata.hbaseindexer.morphline.MorphlineResultToSolrMapper">
    <field name="firstname" value="info:firstname"/>
    <field name="age" value="info:age" type="int"/>
    </indexer>

3. 删除索引

./hbase-indexer delete-indexer --name 'indexer_vip'
  • 参数说明
    1. delete-indexer 动作命令
    2. indexer_vip 要被删除的索引名称

4. 查看所有索引清单

./hbase-indexer list-indexers -dump
  • 参数说明
    1. list-indexers 动作命令
    2. -dump 添加此参数可以显示索引的配置详情

Hbase-indexer常用命令的更多相关文章

  1. (转)Hbase shell 常用命令(1)

    Hbase shell 常用命令(1) link:http://blog.csdn.net/scutshuxue/article/details/6988348 下面我们看看HBase Shell的一 ...

  2. hbase基本概念和hbase shell常用命令用法

    1. 简介 HBase是一个分布式的.面向列的开源数据库,源于google的一篇论文<bigtable:一个结构化数据的分布式存储系统>.HBase是Google Bigtable的开源实 ...

  3. 【转载】HBase基本概念和hbase shell常用命令用法

    1. 简介 HBase是一个分布式的.面向列的开源数据库,源于google的一篇论文<bigtable:一个结构化数据的分布式存储系统>.HBase是Google Bigtable的开源实 ...

  4. Hbase Shell常用命令

    hbase shell常用的操作命令有create,describe,disable,drop,list,scan,put,get,delete,deleteall,count,status等,通过h ...

  5. HBase Shell 常用命令及例子

    下面我们看看HBase Shell的一些基本操作命令,我列出了几个常用的HBase Shell命令,如下: 名称 命令表达式 创建表 create '表名称', '列名称1','列名称2','列名称N ...

  6. 【转】Hbase shell 常用命令

    不定时更新常用好用命令. --------------------------------------------------------------------------------------- ...

  7. HBase学习笔记2 - HBase shell常用命令

    转载请标注原链接:http://www.cnblogs.com/xczyd/p/6639397.html 扫表的时候限定行数 scan } 即为扫表的时候,限定只输出五条数据 ============ ...

  8. Hbase shell 常用命令(1)

    下面我们看看HBase Shell的一些基本操作命令,我列出了几个常用的HBase Shell命令,如下: 名称 命令表达式 创建表 create '表名称', '列名称1','列名称2','列名称N ...

  9. Hbase&Hadoop常用命令

    Hbase中根据Rowkey的前缀Prefix查询数据: scan 'test_xiaomifeng_monitoring_log',{FILTER => "(PrefixFilter ...

  10. hbase shell 常用命令

    进入hbase shell console$HBASE_HOME/bin/hbase shell如果有kerberos认证,需要事先使用相应的keytab进行一下认证(使用kinit命令),认证成功之 ...

随机推荐

  1. pythonweb框架Flask学习笔记04-模板继承

    # -*- coding:utf-8 -*- from flask import render_template,Flask app=Flask(__name__) @app.route('/hell ...

  2. NOIP2017滚粗记【上】

    Day0: NOIP前停课训练的最后一天,上午打了一场三题都见过的比赛,一窝人AK. 下午一群人在机房缓慢氧化,到了晚上因为比赛在我们学校打,所以所有的机房都断网了(百思不得其解为什么两个竞赛室也被断 ...

  3. java --Method

    MethodDemo class MethodDemo { public static void main(String[] args) { //调用自定义的方法. draw(4,5); draw(8 ...

  4. HBase 安装设置

    一.安装环境 1. JDK:jdk-7u79-linux-x64.tar.gz 2. HBase:hbase-0.98.13-hadoop1-bin.tar.gz 3. Hadoop:hadoop-1 ...

  5. 使用mysqldump备份单表数据,并使用navicat导出单表中部分字段到excel

    今天工作上遇到一个问题,客户需要将生产环境上数据库中用户表中的用户名.登录名.邮箱三个字段导出到excel中,查了一下,分两个步骤完成了任务 1. 使用mysqldump命令将生产环境的user表备份 ...

  6. php 按照二位数组中某个指定的字段进行排序

    /** * 按照二维数组中某个指定的某个字段进行排序 * @param $array 需要被排序的数组 * @param $flag 排序的标志 1,SORT_DESC 降序 2,SORT_ASC 升 ...

  7. 【原】SPARK_MEM和SPARK_WORKER_MEMORY的区别

    SPARK_MEM:设置每个Job(程序)在每个节点可用的内存量:(默认为512m) SPARK_WORKER_MEMORY:设置集群中每个节点分配的最大内存量:(默认为内存总量减去1G)

  8. Java虚拟机(二):JVM内存模型

    所有的Java开发人员可能会遇到这样的困惑?我该为堆内存设置多大空间呢?OutOfMemoryError的异常到底涉及到运行时数据的哪块区域?该怎么解决呢?其实如果你经常解决服务器性能问题,那么这些问 ...

  9. [C语言]声明解析器cdecl修改版

    一.写在前面 K&R曾经在书中承认,"C语言声明的语法有时会带来严重的问题.".由于历史原因(BCPL语言只有唯一一个类型——二进制字),C语言声明的语法在各种合理的组合下 ...

  10. js拼图

    ;(function($){ function arrayIndexOf(r, num){ if( Array.prototype.indexOf ){ return r.indexOf(num); ...