# Logstash hangs with error sized\_queue\_timeout

**URL:** <https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031>\
**Category:** Logstash\
**Created:** [August 26, 2016, 11:18am UTC](https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031 "2016-08-26T11:18:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Deb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/deb/32/46162_2.png) [@Deb](https://discuss.elastic.co/u/Deb)\
**Post date:** [August 26, 2016, 11:18am UTC](https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031/1 "2016-08-26T11:18:55Z")

</div>

Cross-posting this from [stackoverflow](http://stackoverflow.com/questions/39164892/logstash-hangs-with-error-sized-queue-timeout).

We have a logstash pipeline in which numerous logstash-forwarders forward logs to a single logstash instance. Many times we have observed that the logstash hangs with the below error:-

```
[2016-07-22 03:01:12.619] WARN -- Concurrent::Condition: [DEPRECATED] Will be replaced with Synchronization::Object in v1.0.
called on: /opt/logstash-1.5.3/vendor/bundle/jruby/1.9/gems/logstash-input-lumberjack-1.0.2/lib/logstash/sized_queue_timeout.rb:16:in `initialize'
Exception in thread ">output" java.lang.UnsupportedOperationException
        at java.lang.Thread.stop(Thread.java:869)
        at org.jruby.RubyThread.exceptionRaised(RubyThread.java:1221)
        at org.jruby.internal.runtime.RubyRunnable.run(RubyRunnable.java:112)
        at java.lang.Thread.run(Thread.java:745)

```

Our logstash config looks like below:-

```
input {
 lumberjack {
  port => 6782
  codec => json {}
  ssl_certificate => "/opt/logstash-1.5.3/cert/logstash-forwarder.crt"
  ssl_key => "/opt/logstash-1.5.3/cert/logstash-forwarder.key"
  type => "lumberjack"
 }
}

filter {
  if [env] != "prod" and [env] != "common" {
    drop {}
  }
  if [message] =~ /^\s*$/ {
    drop { }
  }
}

output {
  if "_jsonparsefailure" in [tags] {
    file {
      path => "/var/log/shop/parse_error/%{env}/%{app}/%{app}_%{host}_%{+YYYY-MM-dd}.log"
    }
  } else {
    kafka {
      broker_list => ["kafka:9092"]
      topic_id => "logstash_logs2"
    }
  }
}

```

On restarting the logstash it starts working again. Can some one let me know why this problem comes and how can we get around this without restarting logstash everytime?

---

<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:** [August 27, 2016, 11:38pm UTC](https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031/2 "2016-08-27T23:38:47Z")

</div>

What version of things are you running?

Also, please note the LSF is deprecated and will be totally unsupported soon.

---

<div class="post-metadata">

**Author:** ![Deb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/deb/32/46162_2.png) [@Deb](https://discuss.elastic.co/u/Deb)\
**Post date:** [August 28, 2016, 4:56am UTC](https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031/3 "2016-08-28T04:56:29Z")

</div>

Logstash 1.5.3  
Kafka 0.8.  
ES - 1.7.1

My pipeline looks like below:-

Multiple LF --- Logstash Collector --- Kafka---- Logstash Indexer --- ES  
Cluster.

I am seeing the problem in logstash-collector.

Just to add in preparation for moving to beats I tried upgrading to  
logstash 2.3.4. But that started giving some other issue:-

> [@Logstash 2.3.4 getting stuck while attempting to install template in elasticsearch](https://discuss.elastic.co/t/logstash-2-3-4-getting-stuck-while-attempting-to-install-template-in-elasticsearch/59098/3):
>
> I modified my output plugin as follows:- output { if [env] == "prod" or [env] == "common" { stdout { codec =\> rubydebug } } } Logstash log said:- Pipeline main started {:file=\>"logstash/agent.rb",:line=\>"473", :method=\>"start\_pipeline"} Also I started getting data on the stdout. We are using transport protocol so we are using elasticsearch\_java output.

So at this point I am stuck with LSF.

---

<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, 4:41am UTC](https://discuss.elastic.co/t/logstash-hangs-with-error-sized-queue-timeout/59031/4 "2017-07-06T04:41:17Z")

</div>


