# Autostart Logstash configuration

**URL:** <https://discuss.elastic.co/t/autostart-logstash-configuration/65569>\
**Category:** Logstash\
**Created:** [November 9, 2016, 11:52pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569 "2016-11-09T23:52:33Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gmmurugan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/gmmurugan/32/12488_2.png) [@gmmurugan](https://discuss.elastic.co/u/gmmurugan)\
**Post date:** [November 9, 2016, 11:52pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/1 "2016-11-09T23:52:33Z")

</div>

How exactly i can make the logstash\_server to start the pipeline automatically with configurations.

i think im using logstash 2.3.2 and the path in my server is /opt/logstash/server/etc/conf.d/test.conf

normally im seeing the runner agent path set to conf.d but i dont see any grep result for the test.conf

sample:

```
logstash 16597 517 99 23:49 ? 00:00:10 /bin/java -XX:+UseParNewGC -XX:+
UseConcMarkSweepGC -Djava.awt.headless=true -XX:CMSInitiatingOccupancyFraction=7
5 -XX:+UseCMSInitiatingOccupancyOnly -XX:+HeapDumpOnOutOfMemoryError -Djava.io.t
mpdir=/opt/logstash/server/tmp/ -Xmx4693M -Xms1564M -Xss2048k -Djffi.boot.librar
y.path=/opt/logstash/server/vendor/jruby/lib/jni -XX:+UseParNewGC -XX:+UseConcMa
rkSweepGC -Djava.awt.headless=true -XX:CMSInitiatingOccupancyFraction=75 -XX:+Us
eCMSInitiatingOccupancyOnly -XX:+HeapDumpOnOutOfMemoryError -server -Djava.io.tm
pdir=/opt/logstash/server/tmp/ -XX:HeapDumpPath=/opt/logstash/server/heapdump.hp
rof -Xbootclasspath/a:/opt/logstash/server/vendor/jruby/lib/jruby.jar -classpath
 : -Djruby.home=/opt/logstash/server/vendor/jruby -Djruby.lib=/opt/logstash/serv
**er/vendor/jruby/lib -Djruby.script=jruby -Djruby.shell=/bin/sh org.jruby.Main --**
 **1.9 /opt/logstash/server/lib/bootstrap/environment.rb logstash/runner.rb agent -**
 **f /opt/logstash/server/etc/conf.d** --pluginpath /opt/logstash/server/lib -l /opt/
logstash/server/log/logstash.log -w 1
```

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [November 10, 2016, 6:54am UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/2 "2016-11-10T06:54:11Z")

</div>

You've apparently started Logstash with `-f /opt/logstash/server/etc/conf.d` so logstash will read all files in that directory.

---

<div class="post-metadata">

**Author:** ![gmmurugan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/gmmurugan/32/12488_2.png) [@gmmurugan](https://discuss.elastic.co/u/gmmurugan)\
**Post date:** [November 10, 2016, 1:43pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/3 "2016-11-10T13:43:57Z")

</div>

I agree. I think its using the default code to initialize all the conf in conf.d folder. But I do not see any results. But when I run manually ,I can see why.

I suspect the jdbc classpath not referenced in the automatic run and its working in manual run. Is that possible ?

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [November 10, 2016, 1:52pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/4 "2016-11-10T13:52:55Z")

</div>

> I suspect the jdbc classpath not referenced in the automatic run and its working in manual run. Is that possible ?

Sure, that's possible.

---

<div class="post-metadata">

**Author:** ![gmmurugan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/gmmurugan/32/12488_2.png) [@gmmurugan](https://discuss.elastic.co/u/gmmurugan)\
**Post date:** [November 12, 2016, 4:40pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/6 "2016-11-12T16:40:32Z")

</div>

> [@gmmurugan](#):
>
> So how can I add the libraries for jdbc-driver for db2. Its more than one  
> . so I can't add them in conf files.

So how can I add the libraries for jdbc-driver for db2. Its more than one  
. so I can't add them in conf files.

---

<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 10, 2016, 4:40pm UTC](https://discuss.elastic.co/t/autostart-logstash-configuration/65569/7 "2016-12-10T16:40:38Z")

</div>

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