# Issue with Elasticsearch service on FreeBSD

**URL:** <https://discuss.elastic.co/t/issue-with-elasticsearch-service-on-freebsd/179794>\
**Category:** Elasticsearch\
**Created:** [May 6, 2019, 3:12pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-service-on-freebsd/179794 "2019-05-06T15:12:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Andromedae93](https://avatars.discourse-cdn.com/v4/letter/a/57b2e6/32.png) [@Andromedae93](https://discuss.elastic.co/u/Andromedae93)\
**Post date:** [May 6, 2019, 3:12pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-service-on-freebsd/179794/1 "2019-05-06T15:12:36Z")

</div>

Hello everybody,

I'm coming here in order to post my question which could help users. I installed elasticsearch thanks to pkg, but I have issues when I try to launch daemon commands on FreeBSD.

This is my environment:

- FreeBSD 11.1-STABLE
- ElasticSearch 5.3.0

Elasticsearch seems to be well-configured:

```
curl http://localhost:9200
{
  "name" : "eetOnCX",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "YizNpx3rTuWMGgu4GAx3jQ",
  "version" : {
    "number" : "5.3.0",
    "build_hash" : "3adb13b",
    "build_date" : "2017-03-23T03:31:50.652Z",
    "build_snapshot" : false,
    "lucene_version" : "6.4.1"
  },
  "tagline" : "You Know, for Search"
}

```

I added in /etc/rc.conf:  
`elasticsearch_enable="YES"`

But when I execute commands:

```
root@toto:/var/run # service elasticsearch start
Starting elasticsearch.
root@toto:/var/run # service elasticsearch status
elasticsearch not running? (check /var/run/elasticsearch.pid).
root@toto:/var/run # top -b
last pid: 12031; load averages: 0.51, 0.39, 0.38 up 24+04:59:53 17:08:52
49 processes: 1 running, 48 sleeping

Mem: 1255M Active, 5963M Inact, 11G Wired, 13G Free
ARC: 5748M Total, 3046M MFU, 2360M MRU, 4766K Anon, 89M Header, 250M Other
     4973M Compressed, 18G Uncompressed, 3.66:1 Ratio
Swap: 8192M Total, 8192M Free

  PID USERNAME THR PRI NICE SIZE RES STATE C TIME WCPU COMMAND
14583 elasticsearch 74 52 0 2393M 614M uwait 7 0:31 1477.34% java
72820 celery 1 20 0 95456K 83812K select 0 64:55 0.00% python3.6
11636 celery 1 20 0 77904K 71236K select 5 50:11 0.00% python3.6
36430 redis 3 20 0 10052K 4828K kqread 0 35:53 0.00% redis-server
78034 www 1 20 0 95840K 87484K kqread 0 8:16 0.00% uwsgi
58224 postgres 1 20 0 25756K 12436K select 5 7:02 0.00% postgres
22014 www 1 20 0 147M 55320K kqread 5 4:37 0.00% uwsgi
32653 postgres 1 20 0 161M 19240K select 1 3:57 0.00% postgres
36919 root 1 20 0 14060K 6256K kqread 7 3:57 0.00% uwsgi
 9114 www 1 20 0 123M 111M kqread 3 3:52 0.00% uwsgi
13191 www 1 20 0 113M 103M kqread 2 3:15 0.00% uwsgi
87305 www 1 20 0 80376K 72184K kqread 2 3:02 0.00% uwsgi
29679 www 1 20 0 78896K 72588K kqread 4 2:59 0.00% uwsgi
98308 www 1 20 0 65576K 57520K kqread 0 2:59 0.00% uwsgi
36653 www 10 20 0 1020M 425M kqread 0 2:32 0.00% node
48369 postgres 1 20 0 161M 20076K select 1 2:23 0.00% postgres
18591 root 1 20 0 6408K 2384K select 2 2:09 0.00% syslogd
18308 uwsgi 1 20 0 18228K 10920K kqread 1 1:31 0.00% uwsgi

```

In /var/log/elasticsearch.log I get:

```
[2019-05-06T17:08:47,497][WARN][o.e.b.BootstrapChecks] [eetOnCX] initial heap size [209715200] not equal to maximum heap size [536870912]; this can cause resize pauses and prevents mlockall from locking the entire heap
[2019-05-06T17:08:47,497][WARN][o.e.b.BootstrapChecks] [eetOnCX] memory locking requested for elasticsearch process but memory is not locked

```

It causes conflicts to my mind with logstash for example which doesn't know if ES is running or not. Furthermore, `service elasticsearch status` should give me the pid immediately right ?

Thank you very much, I'm fighting with ELK on FreeBSD since 1 week 😕

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 3, 2019, 3:12pm UTC](https://discuss.elastic.co/t/issue-with-elasticsearch-service-on-freebsd/179794/2 "2019-06-03T15:12:43Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
