# Slice bounds out of range

**URL:** <https://discuss.elastic.co/t/slice-bounds-out-of-range/39049>\
**Category:** Beats\
**Tags:** packetbeat\
**Created:** [January 13, 2016, 3:25am UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049 "2016-01-13T03:25:48Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ceekay](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ceekay/32/5687_2.png) [@ceekay](https://discuss.elastic.co/u/ceekay)\
**Post date:** [January 13, 2016, 3:25am UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049/1 "2016-01-13T03:25:48Z")

</div>

Hi all,

I'm running Packetbeat on an Ubuntu system with Postgres 9.2 and keep seeing the following in syslog:

> Jan 13 15:43:24 cat-prod-pg92 /usr/bin/packetbeat[26499]: log.go:113: ParsePgsql exception. Recovering, but please report this: runtime error: slice bounds out of range.  
> Jan 13 15:43:24 cat-prod-pg92 /usr/bin/packetbeat[26499]: log.go:114: Stacktrace: /go/src/github.com/elastic/beats/libbeat/logp/log.go:114 (0x48c5c6)#012/usr/local/go/src/runtime/asm\_amd64.s:437 (0x47d8fe)#012/usr/local/go/src/runtime/panic.go:423 (0x44d4f9)#012/usr/local/go/src/runtime/panic.go:18 (0x44ba39)#012/go/src/github.com/elastic/beats/packetbeat/protos/pgsql/pgsql.go:279 (0x512203)#012/go/src/github.com/elastic/beats/packetbeat/protos/pgsql/pgsql.go:610 (0x5146de)#012/go/src/github.com/elastic/beats/packetbeat/protos/pgsql/pgsql.go:707 (0x51515d)#012/go/src/github.com/elastic/beats/packetbeat/protos/tcp/tcp.go:87 (0x521093)#012/go/src/github.com/elastic/beats/packetbeat/protos/tcp/tcp.go:173 (0x5221cd)#012/go/src/github.com/elastic/beats/packetbeat/decoder/decoder.go:136 (0x6c8ad1)#012/go/src/github.com/elastic/beats/packetbeat/sniffer/sniffer.go:352 (0x5337a9)#012/go/src/github.com/elastic/beats/packetbeat/packetbeat.go:212 (0x422f2b)#012/usr/local/go/src/runtime/asm\_amd64.s:1696 (0x47fc41)

I've added the `snaplen` setting as per [ParsePgsql exception (slice bounds out of range) · Issue #157 · elastic/beats · GitHub](https://github.com/elastic/beats/issues/157) but this doesn't seem to help.

My packetbeat config is as follows:

> interfaces:  
> device: any  
> snaplen: 65535  
> protocols:  
> pgsql:  
> ports: [5432]  
> output:  
> logstash:  
> enabled: true  
> hosts: ["dev-ingress1:10614", "dev-ingress2.10614"]  
> tls:  
> disabled: false  
> certificate\_authorities: ["/etc/ssl/certs/dev-beats-ca.pem"]  
> insecure: false

Ubuntu 12.04.5  
packetbeat 1.0.1  
postgres 9.2.13-1.pgdg12.4+1

Any ideas about the cause of this and how I can solve it? Thanks!

---

<div class="post-metadata">

**Author:** ![steffens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steffens/32/79630_2.png) [@steffens](https://discuss.elastic.co/u/steffens)\
**Post date:** [January 13, 2016, 10:39am UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049/2 "2016-01-13T10:39:23Z")

</div>

We've some fixes in 1.1, but still unsure about problem being fixed or still persist. Any attempts to reproduce failed.

Can you try with packetbeat 1.1 nightlies: [https://beats-nightlies.s3.amazonaws.com/index.html?prefix=packetbeat/](https://beats-nightlies.s3.amazonaws.com/index.html?prefix=packetbeat/)

You can follow the issue on github:

> <https://github.com/elastic/beats/issues/342>

  

> <https://github.com/elastic/beats/issues/565>

---

<div class="post-metadata">

**Author:** ![ceekay](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ceekay/32/5687_2.png) [@ceekay](https://discuss.elastic.co/u/ceekay)\
**Post date:** [January 13, 2016, 9:55pm UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049/3 "2016-01-13T21:55:40Z")

</div>

Hi @steffens

I'm now running 1.2.0~nightly160112155654 with the same config, but still getting this error.

Is there any other info you want about the system?

---

<div class="post-metadata">

**Author:** ![steffens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steffens/32/79630_2.png) [@steffens](https://discuss.elastic.co/u/steffens)\
**Post date:** [January 14, 2016, 1:47pm UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049/4 "2016-01-14T13:47:44Z")

</div>

Hi,

we're still trying to reproduce this problem for being able to debug and fix the issue. Unfortunately it's still hiding. We're still in need for a good trace.

See [this github comment](https://github.com/elastic/beats/issues/565#issuecomment-168663852) for a small shell script trying to capture and validate a trace reproducing the issue.

Please use [github issue #565](https://github.com/elastic/beats/issues/565) for discussions, as we treat this as a bug.

---

<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 5, 2017, 9:56pm UTC](https://discuss.elastic.co/t/slice-bounds-out-of-range/39049/5 "2017-07-05T21:56:43Z")

</div>


