No buffer space available

920 views
Skip to first unread message

mattn

unread,
Apr 7, 2013, 9:56:19 AM4/7/13
to golan...@googlegroups.com
Hi list.

Currently, I'm writing some application that getting JSON via long poll like following.

for {
   client.Observe()
}

For an hour or two hours, it works fine for me. but passing four or five hours, error occured in receiving datas.

  No buffer space available

I tried to add runtime.GC() in this loop but it not solved this problem. Anyone do you know the something to solve this problem?


I'm writing this with go latest in the repo. working this on linux CentOS 6.

- Yasuhiro Matsumoto


Albert Strasheim

unread,
Apr 7, 2013, 11:49:48 AM4/7/13
to golan...@googlegroups.com
On Sunday, April 7, 2013 3:56:19 PM UTC+2, mattn wrote:
For an hour or two hours, it works fine for me. but passing four or five hours, error occured in receiving datas.
  No buffer space available
I tried to add runtime.GC() in this loop but it not solved this problem. Anyone do you know the something to solve this problem?
I'm writing this with go latest in the repo. working this on linux CentOS 6.

This is pretty strange. The error string might mean that you are getting ENOBUFS for some reason. From googling it seems more like a UDP thing.

Maybe run the app under strace -f -q -s1000 -v -tt -ostrace.log? Might be a network poller issue.

Regards

Albert

Dmitry Vyukov

unread,
Apr 7, 2013, 6:52:25 PM4/7/13
to mattn, golang-nuts
This post:
http://lists.freebsd.org/pipermail/freebsd-performance/2003-July/000396.html
suggests that it can be an issue with network interface, or DOS from network.

mattn

unread,
Apr 7, 2013, 8:15:02 PM4/7/13
to golan...@googlegroups.com
> This is pretty strange. The error string might mean that you are getting ENOBUFS for some reason. From googling it seems more like a UDP thing.

Yes, but this is TCP thing.


> Maybe run the app under strace -f -q -s1000 -v -tt -ostrace.log? Might be a network poller issue.

Thank you, I'll try it in later.

mattn

unread,
Apr 8, 2013, 7:24:27 AM4/8/13
to golan...@googlegroups.com
Sorry all.
I forgot to close stream with defer r.Body.Close().
Reply all
Reply to author
Forward
0 new messages