Skip to content

Instantly share code, notes, and snippets.

View jpparis-orange's full-sized avatar

Jean-Pierre Paris jpparis-orange

  • Orange
  • Mougins (France)
View GitHub Profile
@jpparis-orange
jpparis-orange / normalize.sh
Last active October 16, 2017 06:24
normalize kibana4 save files

When you want to put kibana 4 export.json under git, you'll see that the file changes even if you did not touch searches, vizs or dashboards. The script below uses jq to keep kibana 4 objects (and object keys) in a constant order. Thus, no diffs if you left your kiaban untouched

@jpparis-orange
jpparis-orange / gist:44e464b8bb09246a4239
Last active October 19, 2015 21:35
Elasticsearch tribe node setup
# !/bin/bash
ES_BASE=/.../elasticsearch-1.4.2
ES_CMD=${ES_BASE}/bin/elasticsearch
# cleanup. Commented so that it doesn't harm your environment
# kill $(jps | grep Elas | awk '{print $1}')
# rm ${ES_BASE}/logs/*
# start two clusters
@jpparis-orange
jpparis-orange / esPigArray
Last active August 29, 2015 13:56
Problem using es arrays in pig
#!/bin/bash
# my configuration
# elasticsearch-1.0.0
# elasticsearch-hadoop-yarn.jar from 1.3.0.M2
# hadoop-2.2.0-bin
# hive-0.12.0-bin
# pig-0.12.0/ with recompiled pig-0.12.0-withouthadoop.jar for yarn
ES_CLUSTER="localhost:9200"
@jpparis-orange
jpparis-orange / esHiveDouble
Last active August 29, 2015 13:56
Reading double from es with hive
#!/bin/bash
# my configuration
# elasticsearch-1.0.0
# elasticsearch-hadoop-yarn.jar from 1.3.0.M2
# hadoop-2.2.0-bin
# hive-0.12.0-bin
# pig-0.12.0/ with recompiled pig-0.12.0-withouthadoop.jar for yarn
ES_CLUSTER="localhost:9200"
@jpparis-orange
jpparis-orange / hiveCopyEsIndexToAnother
Last active August 29, 2015 13:56
using hive to copy one es index to another one
#!/bin/bash
# my configuration
# elasticsearch-1.0.0
# elasticsearch-hadoop-yarn.jar from 1.3.0.M2
# hadoop-2.2.0-bin
# hive-0.12.0-bin
ES_CLUSTER="localhost:9200"