# Duplicate Events

**URL:** https://discuss.elastic.co/t/duplicate-events/40546
**Category:** Logstash
**Created:** [January 30, 2016, 10:17am UTC](https://discuss.elastic.co/t/duplicate-events/40546 "2016-01-30T10:17:06Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![sathishlinux](https://avatars.discourse-cdn.com/v4/letter/s/7ab992/32.png) [@sathishlinux](https://discuss.elastic.co/u/sathishlinux)
#### Post date: [January 30, 2016, 10:17am UTC](https://discuss.elastic.co/t/duplicate-events/40546/1 "2016-01-30T10:17:06Z")

</div>

Hello Forum,

I have the following setup (single node):

Logstash 2.1.0 + Elasticsearch 2.1.0 + Kibana4 and logstash receiving logs from different sources (nxlog, syslog forward and etc..). I am seeing exactly 9 duplicate events for the each logs received:

Jan 30 11:13:12 rhel sshd[9766]: Failed password for root from 192.168.1.1 port 43242 ssh2

The above log turns into 9 entries in elasticsearch. But I tried to send the output to "file" and there are no duplicates. I am having only issue with elasticsearch output. The following is the output config:

elasticsearch {  
hosts =\> "localhost"  
}

Please help me to solve this issue.

Thank you.

Regards,  
Sathish.

---

<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: [January 31, 2016, 12:35am UTC](https://discuss.elastic.co/t/duplicate-events/40546/2 "2016-01-31T00:35:48Z")

</div>

What's the rest of the config look like?

---

<div class="post-metadata">

### Author: ![sathishlinux](https://avatars.discourse-cdn.com/v4/letter/s/7ab992/32.png) [@sathishlinux](https://discuss.elastic.co/u/sathishlinux)
#### Post date: [February 1, 2016, 9:41am UTC](https://discuss.elastic.co/t/duplicate-events/40546/3 "2016-02-01T09:41:30Z")

</div>

Hello Warkolm,

If I store the data into a new index then I dont see any duplicates. I have created an index called "rhel7" and used the following config:

output {  
if [type] == "rhel" {  
elasticsearch {  
hosts =\> "localhost"  
index =\> "rhel7"  
}

The index rhel7 has no duplicate values. Only the default index has the issue. The following the settings of the default index:

{"logstash-2016.02.01":{"settings":{"index":{"creation\_date":"1454284536872","refresh\_interval":"5s","number\_of\_shards":"5","number\_of\_replicas":"1","uuid":"CRbjaZ4WT\_y9PtZMcqL56Q","version":{"created":"2010099"}}}}}

I am not sure why the default index has duplicate entries.

> [@sathishlinux](#):
>
> Hello Forum,
> 
> I have the following setup (single node):
> 
> Logstash 2.1.0 + Elasticsearch 2.1.0 + Kibana4 and logstash receiving logs from different sources (nxlog, syslog forward and etc..). I am seeing exactly 9 duplicate events for the each logs received:
> 
> Jan 30 11:13:12 rhel sshd[9766]: Failed password for root from 192.168.1.1 port 43242 ssh2
> 
> The above log turns into 9 entries in elasticsearch. But I tried to send the output to "file" and there are no duplicates. I am having only issue with elasticsearch output. The following is the output config:
> 
> elasticsearch {hosts =\> "localhost"}
> 
> Please help me to solve this issue.
> 
> Thank you.
> 
> Regards,Sathish.

---

<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: [July 6, 2017, 5:13am UTC](https://discuss.elastic.co/t/duplicate-events/40546/4 "2017-07-06T05:13:35Z")

</div>


