Modify

#803 new defect

Google talk timeouts..

Reported by: brynet@… Owned by:
Priority: normal Milestone:
Component: BitlBee Version: 3.0.1
Keywords: patch Cc:
IRC client+version: Client-independent Operating System: OpenBSD
OS version/distro:

Description

I've been seeing timeouts with gtalk xmpp connections, setting the SO_KEEPALIVE socket option seems to help.

I'm not sure if this is a proper fix, but it "works for me".

Attachments (1)

bitlbee-keepalive.diff (470 bytes) - added by brynet@… at 2011-06-18T16:52:13Z.
Force keepalives.

Download all attachments as: .zip

Change History (8)

Changed at 2011-06-18T16:52:13Z by brynet@…

Attachment: bitlbee-keepalive.diff added

Force keepalives.

comment:1 Changed at 2011-06-21T07:51:13Z by wilmer

Weird. The Jabber module is also sending keepalives in the form of whitespace. Every minute. I'm not sure how often this sends a keepalive?

comment:2 Changed at 2011-06-21T08:43:17Z by brynet@…

I noticed the whitespace being sent, however that doesn't seem to be enough for Google.. it likes to arbitrarily end the connection, for whatever reason.

comment:3 Changed at 2011-06-21T08:52:52Z by brynet@…

Oh, I'm not sure how often the OpenBSD kernel sends keepalives with SO_KEEPALIVE, the POSIX/SUS leaves that up to the implementation.. but it appears to do the trick for me.

comment:4 Changed at 2011-06-21T09:47:33Z by brynet@…

Supposedly it works out to be around once ever 2 hours because of an odd bug in the kernel code, however with that fixed it should be sending keepalives once every 75 seconds.. regardless the connection is eventually dropped unless SO_KEEPALIVE is set, so is there any harm in doing so?

comment:5 Changed at 2011-06-21T10:30:18Z by brynet@…

Does biitlbee support XMPP ping? XEP-0199? perhaps Google is just very strict about that sort of stuff.

comment:6 Changed at 2011-06-21T10:45:10Z by Wilmer van der Gaast <wilmer@…>

They're not, but maybe some router on your way is. Loads of people use BitlBee to connect to GTalk for years already, and this problem is pretty new to me.

But every now and then I see problems with trigger happy low-timeout NAT/firewall boxes causing problems like this.

I'll take a look at importing this patch BTW. Would be good to apply the same sockctl() to the IRC socket actually.

comment:7 Changed at 2014-02-04T06:11:39Z by dx

Keywords: patch added

Modify Ticket

Action
as new The ticket will remain with no owner.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.