To disable IPv6 in OS X Lion, you will need to use the Terminal.
- Applications > Utilities > Terminal
- To determine what are all of your Mac's network interfaces are, issue the following command: networksetup -listallnetworkservices
- To disable IPv6 for wireless, issue the following command: networksetup -setv6off Wi-Fi; to disable IPv6 for Ethernet, issue the following command: networksetup -setv6off Ethernet
- To re-enable IPv6, use -setv6automatic instead
how do you know it works?
when i use "networksetup -setv6off Wi-Fi", the command completes without obvious error, but i still see evidence of ip6 being used:
beejMBA:~ beej$ telnet www.google.com 80
when i turn off ip6 with "sudo ip6 -x", i get:
beejMBA:personal beej$ telnet www.google.com 80
which looks better to me...
You need to use quote marks around the network name, like this:
To disable IPv6 for wireless, issue the following command: networksetup -setv6off "Wi-Fi"
To turn the iPV6 back on, if you like, just open System Prefs/Network and do it from there in the GUI.
Or, if you prefer, use Terminal. Either works.
Related, just to note it somewhere—it seems technically possible to disable the IPv6 loopback address ::1 and friends (which I had to do as they were causing me grief trying to develop Java web apps in a local Eclipse/Tomcat setup where third-party classes were expecting IPv4 format and choking instead… long sad story). From the Terminal:
$ ifconfig lo0 inet6 fe80::1%lo0 delete
$ ifconfig lo0 inet6 ::1 delete
I don’t know if this has negative consequences (e.g. the Bonjour subsystem etc) and wouldn’t expect it to persist between restarts (but I’ll leave that as an exercise for the reader), but it generally seems to work for me.
Oh, and Mountain Lion doesn’t seem to have the ip6 utility anymore (well, it’s not on my clean Mountain Lion 10.8.2 install, anyway)?