Skip to content

Commit

Permalink
Create index README
Browse files Browse the repository at this point in the history
  • Loading branch information
iriahi committed Jun 4, 2016
1 parent e9ede41 commit b54cabb
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions conf/elasticsearch/REAME.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Ahmia index
Ahmia search engine use elasticsearch to index content.

## Installation
Please install elastic search from the official repository thanks to the [official guide](https://www.elastic.co/guide/en/elasticsearch/reference/current/setup-repositories.html)

## Configuration
Default configuration is enough to run index in dev mode. Here is suggestion for a more secure configuration

### /etc/security/limits.conf

```
elasticsearch - nofile unlimited
elasticsearch - memlock unlimited
```

### /etc/default/elasticsearch
on CentOS/RH: /etc/sysconfig/elasticsearch

```
ES_HEAP_SIZE=2g # Half of your memory, other half is for Lucene
MAX_OPEN_FILES=1065535
MAX_LOCKED_MEMORY=unlimited
```

### /etc/elasticsearch/elasticsearch.yml

```
bootstrap.mlockall: true
```

## Start the service

```sh
# systemctl start elasticsearch
```

## Init mappings
Please do this when running for the first time

```sh
$ curl -XPUT -i "localhost:9200/crawl/" -d "@./mappings.json"
```

0 comments on commit b54cabb

Please sign in to comment.