# Setting up Logstash using Docker

**URL:** <https://discuss.elastic.co/t/setting-up-logstash-using-docker/157228>\
**Category:** Logstash\
**Created:** [November 18, 2018, 2:46pm UTC](https://discuss.elastic.co/t/setting-up-logstash-using-docker/157228 "2018-11-18T14:46:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sai\_Srinivas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sai_srinivas/32/37788_2.png) [@Sai\_Srinivas](https://discuss.elastic.co/u/Sai_Srinivas)\
**Post date:** [November 18, 2018, 2:46pm UTC](https://discuss.elastic.co/t/setting-up-logstash-using-docker/157228/1 "2018-11-18T14:46:51Z")

</div>

Hi Everyone!

This is my first time using Logstash. I am trying to setup logstash on Docker using the following command.

docker run -h logstash --name logstash\_a --link elasticsearch\_1:elasticsearch -it  
--rm -v "SPwD":/config-dir logstash:6.5.0 -f /config-dir/logstash.config

When I run this command I get the following error:

OpenJDK 64-Bit Server VM warning: If the number of processors is expected to increase from one, then you should configure the number of parallel GC threads appropriately using -XX:ParallelGCThreads=N  
OpenJDK 64-Bit Server VM warning: INFO: os::commit\_memory(0x00000000c5330000, 986513408, 0) failed; error='Cannot allocate memory' (errno=12)

# 

# There is insufficient memory for the Java Runtime Environment to continue.

# Native memory allocation (mmap) failed to map 986513408 bytes for committing reserved memory.

# An error report file with more information is saved as:

# /usr/share/logstash/hs\_err\_pid1.log

Can someone help me in setting up the Logstash

---

<div class="post-metadata">

**Author:** ![jarpy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jarpy/32/51290_2.png) [@jarpy](https://discuss.elastic.co/u/jarpy)\
**Post date:** [November 19, 2018, 4:52am UTC](https://discuss.elastic.co/t/setting-up-logstash-using-docker/157228/2 "2018-11-19T04:52:23Z")

</div>

I don't mean to be "Captain Obvious", but how much memory _is_ available to the container? What does your environment look like? Is it a constrained system? A virtual machine of some kind, maybe?

---

<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:** [December 17, 2018, 4:52am UTC](https://discuss.elastic.co/t/setting-up-logstash-using-docker/157228/3 "2018-12-17T04:52:24Z")

</div>

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