# Stop logstash

**URL:** https://discuss.elastic.co/t/stop-logstash/86293
**Category:** Logstash
**Created:** [May 18, 2017, 3:26pm UTC](https://discuss.elastic.co/t/stop-logstash/86293 "2017-05-18T15:26:48Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Hajer\_ben\_salem1](https://avatars.discourse-cdn.com/v4/letter/h/f04885/32.png) [@Hajer\_ben\_salem1](https://discuss.elastic.co/u/Hajer_ben_salem1)
#### Post date: [May 18, 2017, 3:26pm UTC](https://discuss.elastic.co/t/stop-logstash/86293/1 "2017-05-18T15:26:48Z")

</div>

How can I stop the Logstash instance, while ensuring that it finish sending the bulks to Elasticsearch? I don't want to loose any logs while stopping logstash.  
My version od ELK is 5.3  
My file.conf :

input {  
http\_poller {  
urls =\> {  
test1 =\> { method =\> get  
url =\> "[https://jira.vermeg.com/rest/api/2/search?"](https://jira.vermeg.com/rest/api/2/search?%22)  
headers =\> {  
Accept =\> "application/json"  
}}  
test2 =\> { method =\> get  
url=\>"[https://jira.vermeg.com/rest/api/2/search?"](https://jira.vermeg.com/rest/api/2/search?%22)  
headers =\> {  
Accept =\> "application/json"  
}}  
}  
interval =\> 3600  
}}  
filter {  
split {  
field =\> "issues"  
}  
mutate {  
add\_field =\> {"SvnTrace"=\>"not\_found"}  
add\_field =\> {"key" =\> "%{issues[key]}"}  
}}  
filter {  
elasticsearch {  
hosts =\> ["10.6.140.58:9200"]  
index =\> "svn.solife-2017.05.15"  
query =\> 'is :" %{[key]}"'  
fields =\> { "revision" =\> "SvnTrace" }   
}}  
filter {  
if [SvnTrace] != "not\_found" {  
drop {}  
}}  
output {

elasticsearch {  
hosts =\> "10.6.140.58:9200"  
index =\> "jira-svn-demo\_test10"

```
}

```

}

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [May 19, 2017, 2:24am UTC](https://discuss.elastic.co/t/stop-logstash/86293/2 "2017-05-19T02:24:19Z")

</div>

LS will try to flush anything it has in its pipeline during shutdown. If you issue a shutdown command you should see this in the logs.

---

<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 16, 2017, 2:24am UTC](https://discuss.elastic.co/t/stop-logstash/86293/3 "2017-06-16T02:24:19Z")

</div>

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