# Cannot run Logstash on windows

**URL:** <https://discuss.elastic.co/t/cannot-run-logstash-on-windows/224425>\
**Category:** Logstash\
**Created:** [March 20, 2020, 1:43pm UTC](https://discuss.elastic.co/t/cannot-run-logstash-on-windows/224425 "2020-03-20T13:43:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cgrosu](https://avatars.discourse-cdn.com/v4/letter/c/46a35a/32.png) [@cgrosu](https://discuss.elastic.co/u/cgrosu)\
**Post date:** [March 20, 2020, 1:43pm UTC](https://discuss.elastic.co/t/cannot-run-logstash-on-windows/224425/1 "2020-03-20T13:43:08Z")

</div>

I followed the steps to install and run logstash from [https://www.elastic.co/guide/en/logstash/current/installing-logstash.html](https://www.elastic.co/guide/en/logstash/current/installing-logstash.html)  
[https://www.elastic.co/guide/en/logstash/current/running-logstash-windows.html](https://www.elastic.co/guide/en/logstash/current/running-logstash-windows.html)

Unfortunately I am getting following error after I am running the run command : C:\logstash-7.6.1\> .\bin\logstash.bat -f .\config\syslog.conf  
Error: Could not find or load main class Search\logstash-7.6.1\logstash-core\lib\jars\animal-sniffer-annotations-1.14.jar

JAVA\_HOME is set to c:\Program Files\Java\jre1.8.0\_241  
Path has : c:\Program Files\Java\jre1.8.0\_241\bin  
Java version "1.8.0\_241"  
Java(TM) SE Runtime Environment (build 1.8.0\_241-b07)  
Java HotSpot(TM) 64-Bit Server VM (build 25.241-b07, mixed mode)

Can somebody help me ?

Thanks

---

<div class="post-metadata">

**Author:** ![plezy](https://avatars.discourse-cdn.com/v4/letter/p/b782af/32.png) [@plezy](https://discuss.elastic.co/u/plezy)\
**Post date:** [March 24, 2020, 8:30pm UTC](https://discuss.elastic.co/t/cannot-run-logstash-on-windows/224425/2 "2020-03-24T20:30:33Z")

</div>

Hi Constantin,

Just ran into the same problem.

I had to remove the quotes around the **%CLASSPATH%** at line 55 of bin\logstash.bat.

Hope this help,

Patrick

---

<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:** [April 21, 2020, 8:33pm UTC](https://discuss.elastic.co/t/cannot-run-logstash-on-windows/224425/3 "2020-04-21T20:33:00Z")

</div>

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