• Welcome to Hurricane Electric's IPv6 Tunnel Broker Forums.

IPv6 on iPad brokenness

Started by cconn, March 17, 2013, 09:42:29 AM

Previous topic - Next topic

cconn

I have an iPad mini and it has an annoying behaviour.  I would like to know if it is specific to my setup or if it is iOS6.1.2 that is misbehaving.

Essentially, I am running an Openwrt router using 6relayd for SLAAC/RA.  It seems to work fine for XP/Windows7/Android JB 4.1/Ubuntu, however my iPad will not keep its prefix active when I pick it up after a period of it being idle.

The RAs being sent by 6relayd are with lifetime 7200s, and I see regular RAs on the wire coming from the wrt device.  I installed a app on the iPad called ip6config, which allows me to see the prefixes configured on the various interfaces, the one I am interested in being the WiFi.  Upon powerup, the iPad will properly configure itself a prefix and IPv6 works fine.  However, if I am to let it sleep for more than 7200s, (or idle, because I don't think it is sleeping, just the screen is off), the RAs sent between the time I last used it and the time I pick it up are ignored.  This causes the WiFi to no longer have a valid IPv6 prefix when I unlock the device.

What is worse, it doesn't send any RS to the network, and will remain without a working prefix until the wrt sends out a RA.  Once the iPad sees the RA, the prefix is re-enabled and voila, IPv6 works again.

I have 3 iPhones on this LAN that do not seem to do this, however the difference with these devices is that they seem to shut off WiFi when they are idle for a certain amount of time, so I believe they are sending a RS when they reconnect to the wifi when I unlock them, contrary to the iPad which is always connected to the AP.

Anyone with a non 3G/4G iPad care to comment on their observations with regards to prefix lifetimes on the devices?

kasperd

It does sound like an iOS bug. I am wondering though, how do you know if the WiFi connection is kept active? How do you tell the difference between a connection which is kept active, but not transferring any packets, and a connection which is disabled?

cconn

#2
I think the ipad still pings on v4 when idle, and in the unlock screen the wifi bars are already there contrary to the iphones.

I know for a fact using wireshark i see no RS sent by the ipad when it is unlocked.   I will have to test with wireshark what the iphones do but they have a valid prefix faster than i can open the ip6info app to check, contrary to the ipad that has no valid prefix until an unsollicited RA is sent by the router, which can take minutes

kasperd


cconn

apparently it pings when it is idle only when it is on  a charger.  The iPhones do this as well.  v4/v6 pings therefore work when the devices are plugged in  ::)

I will test without chargers and run packet captures to check for router sollicitations when they are woken.  Perhaps the iPhones do the same.  In any case, I never noticed before since my previous router would send RAs every 30 seconds, this one has a much longer time between RAs and I am noting this strange behaviour.  Other OSs I use do not seem to have moments where the prefix is unusable...

ravenstar

As far as I am aware RS messages only need to be sent out when a device first joins a network once it is on the network it shouldn't have to send out any additional RS messages unless it detects changes on the network.

Indeed powering off the IPad and powering it back on does indeed cause an RS message to be sent as does switching the network the Ipad is using.

TBH IPv6 on the IOS is not the best it can be.  It's happy eyballs solution means that browsers will use the IPv4 address rather than the IPv6 address, apple could seriously do with overhauling this.

Ravenstar68

cconn

#6
Quote from: ravenstar on May 14, 2013, 04:12:42 AM
As far as I am aware RS messages only need to be sent out when a device first joins a network once it is on the network it shouldn't have to send out any additional RS messages unless it detects changes on the network.

Indeed powering off the IPad and powering it back on does indeed cause an RS message to be sent as does switching the network the Ipad is using.

TBH IPv6 on the IOS is not the best it can be.  It's happy eyballs solution means that browsers will use the IPv4 address rather than the IPv6 address, apple could seriously do with overhauling this.

Ravenstar68

unfortunately I have found my Samsung Galaxy S4 seems to do the same on two different IPv6 router platforms.  

And the RS would as you say be used every time a network is joined, my point is that when the iPad sleeps its wireless (and the GS4 apparently as well), things on the network can change.

For instance, a prefix can be deprecated (lifetime = 0) if it changes, which can happen on a dynamic link such as PPPoE, or renumbering a network etc.

As well, in my case even if the prefix does not change, and the devices sleep longer than the preferred/maximum prefix lifetimes, therefore when they wake from sleep the prefix is actually no longer to be considered valid since they have not gotten any RAs in the interim to reset their lifetime counters.  Yet for some reason, the devices wait patiently for a RA to re-enable the IPv6 stack instead of asking the network if a router/prefix is available.  This is what I find as a strange implementation  ???

ravenstar

The Router Lifetime only refers to the Routers lifetime as a default router.

What are the prefix Preferred and Valid Lifetimes?
My Valid time is shown as        2592000 (30 days)
My preferred time is shown as   604800 (7 days)

When the Ipad wakes from sleep it should still have the router information in it, the ND state would most likely be STALE at that point rather than UNREACHABLE, so it should try resending information using the existing path rather than having to send out an RS message again.

Are you able to try pinging a specific v6 address just after the Ipad wakes up?

Ravenstar68