Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save PeterLi/371fcc3f7e814eeb7559 to your computer and use it in GitHub Desktop.
Save PeterLi/371fcc3f7e814eeb7559 to your computer and use it in GitHub Desktop.
Apple OSX "Create NAT64 Network" to help test IPv6 is just not working for my laptop or computer or iPhone or iPad devices - SOLVED
Overview:
=========
So you want to test your application, whether it be desktop, mobile or tablet for IPv6 compatibility.
Apple make this easy as OSX has a nice hidden feature to enable your Apple laptop to create an IPv6 ONLY personal hotspot by sharing your existing (IPv4) internet connection. The problem is, you follow the instructions, but it is JUST NOT WORKING for you!
Well, if you are like me and you spent way longer than you would have wanted, trying to get this working, this snippet of info may save you some time.
Reference:
==========
See following URL to setup a IPv6 hotspot on your Apple Laptop
https://developer.apple.com/library/ios/documentation/NetworkingInternetWeb/Conceptual/NetworkingOverview/UnderstandingandPreparingfortheIPv6Transition/UnderstandingandPreparingfortheIPv6Transition.html
Non-functioning Symptoms:
=========================
- Your xcode project tries to do some networking calls with ASIHTTPRequest, AFNetworking or Alamofire (or CoreFoundation networking classes) and eventually fails with a timeout or "A server with the specified host name could not be found" (NSURLErrorDomain, -1003)
- Your iPhone / iPad / Computer fails to load a web page and eventually shows an error
- Your iPhone / iPad / Computer may load a web page ONCE, but then everything starts to fail to load a web page and eventually shows an error
- Rebooting your iPhone loads a page once, then everything stops working again.
POSSIBLE CAUSE (and SOLUTION):
==============================
You have configured in your WiFi setting a custom DNS entry!
eg you added 8.8.8.8 or 2001:4860:4860::8888 say to your list of DNS IP's
To "fix" this, simply remove any IPv4 DNS entries (and the oddly the Google IPv6 address of the equivalent for 8.8.8.8... and maybe your other IPv6 DNS IP's)
(I simply deleted all, and let the DHCP server assign a default DNS... this worked)
Save and Apply the setting in System Preferences > Network...
Now when you browse via Safari or run your app on your device... everything WORKS!
@andrewvmail
Copy link

I had to go into the shared
Screen Shot 2020-02-05 at 10 32 20 PM
interface and configure IPv6 Automatically to get it to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment