weblog d’un abbe


How IPv6 tunnelling keeps me connected with IRC servers

Filed under: Research — Tags: , , — abbe @ 0041

These days I used to IRC a lot. And also these days, my dynamic IPv4 based ADSL Broadband connection disconnects frequently, couple of time it is at ADSL level, sometimes its at PPPoE level. IRCing over an IPv6 tunnel keeps me logged-in to IRC even when my ADSL links goes down, and I was waiting for it to up. But this works with only my freenet6 tunnel, not 6to4. How all this happens ?

  1. I connect to Internet by PPPoE dialing to my ISP.
  2. I start my freenet6 tunnel (IPv6-over-UDP-over-IPv4).
  3. Now, I connect to IPv6 IRC servers like (ipv6.chat.freenode.net, or irc6.oftc.net) using my IRC client.
  4. ADSL links goes down after some time.
  5. PPPoE connection also times out, destroying my IPv6 tunnel .
  6. Within 10-15 seconds ADSL link is up.
  7. PPPoE session is re-established.
  8. freenet6 IPv6 tunnel is re-established.
  9. I check my IRC client to see whether I was disconnected or not. To my surprise, I am still online, getting all messages. never disconnected.

Why I was not disconnected from IRC despite my IPv6 tunnel get destroyed, my IPv4 address changed ? Is my IRC client doing any magic ? No, its not anything special my IRC client does, its all due to my OS, GNU/Linux‘s network stack. Hmm…? Yes, when my IPv6 tunnel (underlying channel) goes down, TCP connection to IRC servers stays in ESTABLISHED state until TCP connection times out. Now another question is why, IRC server hasn’t disconnected from its side ? Because my link went down suddenly, so no time for tunnel client to send the message to the remote endpoint to close the tunnel. So, for remote endpoint (i.e. freenet6 server) I’m still up, its just that I’m not sending ACK packets, so it’ll keep transmitting retransmitted packets (from IRC server) until tunnel times out. For IRC server also, I’m still up, its just that I’m not sending ACK packets, so it’ll keep retransmitting packets unless, (i) I acknowledge with ACK packets, or (ii) TCP retransmission timeout happens at IRC server’s end, or (iii, not sure on this, as I don’t how its all happening at tunnel broker’s end) freenet6 server sends an ICMPv6 Destination Unreachable to IRC server, when tunnel timeout happens. BtW, its no special treatment for IPv6 tunnels its there for other networks also, provided address of your network interface is static and you regain connectivity before retransmission timeout happens :) . Not sure, if this is part of Internet Host Requirements RFCs. I’ll read them soon as I get some time, anyways happy IPv6ing… :)


Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: