# Initial OL7 Configuration Issues

**URL:** <https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503>\
**Category:** Elasticsearch\
**Created:** [February 7, 2019, 6:32pm UTC](https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503 "2019-02-07T18:32:35Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dotcomelastic](https://avatars.discourse-cdn.com/v4/letter/d/278dde/32.png) [@dotcomelastic](https://discuss.elastic.co/u/dotcomelastic)\
**Post date:** [February 7, 2019, 6:32pm UTC](https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503/1 "2019-02-07T18:32:35Z")

</div>

I'm trying to setup Graylog and before you install Graylog, Elasticsearch is required. The basic configuration seems to be all that is necessary but I cannot get this to start and continue to run. See errors below:

[Graylog Install Docs](http://docs.graylog.org/en/2.5/pages/installation/os/centos.html)

I'm using Oracle Linux 7u2 minimal install. It's a fresh install with no updates at the moment. This is a VM sitting on ESXi 6.0u2. 2 CPU, 8GB RAM, 30GB HDD. This is more of a test build to see how to perform the install.

I'm using java1.8.0\_202 (jdk-8u202-linux-x64.rpm)  
So far I just have Java and MongoDB installed.

Here is the error I'm receiving:  
● elasticsearch.service - Elasticsearch  
Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled)  
Active: failed (Result: exit-code) since Thu 2019-02-07 13:08:24 EST; 12min ago  
Docs: [http://www.elastic.co](http://www.elastic.co)  
Process: 3176 ExecStart=/usr/share/elasticsearch/bin/elasticsearch -p ${PID\_DIR}/elasticsearch.pid --quiet (code=exited, status=1/FAILURE)  
Main PID: 3176 (code=exited, status=1/FAILURE)

Feb 07 13:08:24 apsls elasticsearch[3176]: at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:93)  
Feb 07 13:08:24 apsls elasticsearch[3176]: Caused by: ParsingException[Failed to parse object: expecting token of type [START\_OBJECT] but found [VALUE\_STRING]]  
Feb 07 13:08:24 apsls elasticsearch[3176]: at org.elasticsearch.common.xcontent.XContentParserUtils.ensureExpectedToken(XContentParserUtils.java:78)  
Feb 07 13:08:24 apsls elasticsearch[3176]: at org.elasticsearch.common.settings.Settings.fromXContent(Settings.java:696)  
Feb 07 13:08:24 apsls elasticsearch[3176]: at org.elasticsearch.common.settings.Settings.access$500(Settings.java:84)  
Feb 07 13:08:24 apsls elasticsearch[3176]: at org.elasticsearch.common.settings.Settings$Builder.loadFromStream(Settings.java:1212)  
Feb 07 13:08:24 apsls elasticsearch[3176]: ... 8 more  
Feb 07 13:08:24 apsls systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE  
Feb 07 13:08:24 apsls systemd[1]: Unit elasticsearch.service entered failed state.  
Feb 07 13:08:24 apsls systemd[1]: elasticsearch.service failed.

Only things I have changed in the elasticsearch.yml are:  
cluster.name:graylog  
path.data:/var/lib/elasticsearch  
path.logs:/var/log/elasticsearch  
action.auto\_create\_index:false \<---This line is per Graylog instructions

Here is my /etc/sysconfig/elasticsearch file:  
[root@apsls java]# cat /etc/sysconfig/elasticsearch  
################################

# Elasticsearch

################################

# Elasticsearch home directory

ES\_HOME=/usr/share/elasticsearch

# Elasticsearch Java path

#JAVA\_HOME=

# Elasticsearch configuration directory

ES\_PATH\_CONF=/etc/elasticsearch

# Elasticsearch PID directory

PID\_DIR=/var/run/elasticsearch

# Additional Java OPTS

#ES\_JAVA\_OPTS=

# Configure restart on package upgrade (true, every other setting will lead to not restarting)

#RESTART\_ON\_UPGRADE=true

################################

# Elasticsearch service

################################

# SysV init.d

# 

# The number of seconds to wait before checking if Elasticsearch started successfully as a daemon process

ES\_STARTUP\_SLEEP\_TIME=5

################################

# System properties

################################

# Specifies the maximum file descriptor number that can be opened by this process

# When using Systemd, this setting is ignored and the LimitNOFILE defined in

# /usr/lib/systemd/system/elasticsearch.service takes precedence

#MAX\_OPEN\_FILES=65536

# The maximum number of bytes of memory that may be locked into RAM

# Set to "unlimited" if you use the 'bootstrap.memory\_lock: true' option

# in elasticsearch.yml.

# When using systemd, LimitMEMLOCK must be set in a unit file such as

# /etc/systemd/system/elasticsearch.service.d/override.conf.

#MAX\_LOCKED\_MEMORY=unlimited

# Maximum number of VMA (Virtual Memory Areas) a process can own

# When using Systemd, this setting is ignored and the 'vm.max\_map\_count'

# property is set at boot time in /usr/lib/sysctl.d/elasticsearch.conf

MAX\_MAP\_COUNT=262144

If anyone has any advice, much appreciated!!

Thank you in advance.

---

<div class="post-metadata">

**Author:** ![dotcomelastic](https://avatars.discourse-cdn.com/v4/letter/d/278dde/32.png) [@dotcomelastic](https://discuss.elastic.co/u/dotcomelastic)\
**Post date:** [February 7, 2019, 6:57pm UTC](https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503/2 "2019-02-07T18:57:59Z")

</div>

I may have resolved this? I saw that my $ES\_JAVA\_OPTS was blank so I changed it to:

# Additional Java OPTS

ES\_JAVA\_OPTS="$ES\_JAVA\_OPTS -Djava.io.tmpdir=/tmp/java" ./bin/elasticsearch

It seems to be running but is this expected behavior? Sorry for the lack of knowledge on ES:  
● elasticsearch.service - Elasticsearch  
Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled)  
Active: active (running) since Thu 2019-02-07 13:48:24 EST; 4min 8s ago  
Docs: [http://www.elastic.co](http://www.elastic.co)  
Main PID: 3526 (elasticsearch)  
CGroup: /system.slice/elasticsearch.service  
├─ 308 /bin/bash ./bin/elasticsearch  
├─ 329 /bin/bash ./bin/elasticsearch  
.....  
├─32734 /bin/bash ./bin/elasticsearch  
└─32755 /bin/bash ./bin/elasticsearch

Thanks again

---

<div class="post-metadata">

**Author:** ![dotcomelastic](https://avatars.discourse-cdn.com/v4/letter/d/278dde/32.png) [@dotcomelastic](https://discuss.elastic.co/u/dotcomelastic)\
**Post date:** [February 8, 2019, 1:02am UTC](https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503/3 "2019-02-08T01:02:03Z")

</div>

Ok new error:

[root@apsls bin]# systemctl status elasticsearch.service  
● elasticsearch.service - Elasticsearch  
Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled)  
Active: failed (Result: exit-code) since Thu 2019-02-07 13:59:18 EST; 5h 16min ago  
Docs: [http://www.elastic.co](http://www.elastic.co)  
Process: 3526 ExecStart=/usr/share/elasticsearch/bin/elasticsearch -p ${PID\_DIR}/elasticsearch.pid --quiet (code=exited, status=1/FAILURE)  
Main PID: 3526 (code=exited, status=1/FAILURE)

Feb 07 13:48:24 apsls systemd[1]: Started Elasticsearch.  
Feb 07 13:48:24 apsls systemd[1]: Starting Elasticsearch...  
Feb 07 13:59:16 apsls elasticsearch[3526]: Error occurred during initialization of VM  
Feb 07 13:59:16 apsls elasticsearch[3526]: java.lang.OutOfMemoryError: unable to create new native thread  
Feb 07 13:59:18 apsls systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE  
Feb 07 13:59:18 apsls systemd[1]: Unit elasticsearch.service entered failed state.  
Feb 07 13:59:18 apsls systemd[1]: elasticsearch.service failed.

It has 32764 threads then hours later stops. That should be plenty?

---

<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:** [March 8, 2019, 1:02am UTC](https://discuss.elastic.co/t/initial-ol7-configuration-issues/167503/4 "2019-03-08T01:02:09Z")

</div>

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