This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The default roles file is empty as the preferred method of defining roles is | |
# through the API/UI. File based roles are useful in error scenarios when the | |
# API based roles may not be available. | |
admins: | |
cluster: | |
- all | |
indices: | |
- names: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ======================== Elasticsearch Configuration ========================= | |
# | |
# NOTE: Elasticsearch comes with reasonable defaults for most settings. | |
# Before you set out to tweak and tune the configuration, make sure you | |
# understand what are you trying to accomplish and the consequences. | |
# | |
# The primary way of configuring a node is via this file. This template lists | |
# the most important settings you may want to configure for a production cluster. | |
# | |
# Please consult the documentation for further information on configuration options: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
make sure to go in users_roles and add admins as (user created) | |
./elasticsearch-users useradd kumawatlalit -p kumawat -r network,monitoring |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//docker compose up ---->after saving this run this in the same folder --> you can use vs code | |
version: "3.7" | |
services: | |
es01: | |
image: "docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.2" | |
ports: | |
- "9200:9200" | |
- "9300:9300" | |
environment: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2.2' | |
services: | |
elasticsearch: | |
image: docker.elastic.co/elasticsearch/elasticsearch:6.6.1 | |
container_name: elasticsearch | |
environment: | |
- cluster.name=docker-cluster | |
- bootstrap.memory_lock=true | |
- "ES_JAVA_OPTS=-Xms512m -Xmx512m" | |
ulimits: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#uncomment things you want to use and comment that you dont want | |
#Give it A star | |
version: "3" | |
services: | |
#mongodb: | |
#container_name: mongodb | |
#image: mongo:latest | |
#ports: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
put hola/ | |
{ | |
"settings":{ | |
"analysis":{ | |
"analyzer":{ | |
"my-analyzer":{ | |
"tokenizer":"my-tokenizer", | |
"filter":["lowercase"] | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { Client } = require('@elastic/elasticsearch'); | |
const fs = require('fs'); | |
const readline = require('readline'); | |
const csv = require('csv-parser'); | |
const client = new Client({ node: 'http://localhost:9200' }); | |
const filePath = '/path/to/large/csv/file'; // Replace with the path to your CSV file | |
const chunkSize = 100000; // Replace with the desired chunk size |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
elasticsearch1: | |
image: docker.elastic.co/elasticsearch/elasticsearch:8.6.1 | |
container_name: elasticsearch1 | |
environment: | |
- discovery.type=zen | |
- cluster.name=docker-cluster | |
- node.name=node-1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
elasticsearch: | |
image: docker.elastic.co/elasticsearch/elasticsearch:8.6.1 | |
container_name: elasticsearch | |
environment: | |
- discovery.type=single-node | |
ports: | |
- 9200:9200 |