How to Disable IPV6 in Ubuntu
Sponsored Link
Method 1
You need to edit the aliases file using the following command
gksudo gedit /etc/modprobe.d/aliases
Find the line: alias net-pf-10 ipv6
change to
alias net-pf-10 off
If the above change is not working you need to change the following one
alias net-pf-10 off ipv6
Save the file and reboot
Method2
Disable IPv6 in Firefox. Type about:config and search for:
network.dns.disableIPv6
and set it to TRUE
Method 3
Edit /etc/default/grub file
gksudo gedit /etc/default/grub
Change
GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash”
to
GRUB_CMDLINE_LINUX_DEFAULT=”ipv6.disable=1 quiet splash”
Save and exit the file
Update the grub from the command line
sudo update-grub
Could you please explain me why would I disable IPV6 ? for which reason ?
some people might get slow network/Internet connections, DNS resolution problems.If you disable ipv6 these two problems will be fixed.
You should not disable IPv6 because it is the future and the Web is moving towards it… Most hosting providers have updated and there is a good chance just 10% og your requests needs to be resent in IPv4.
If you need faster DNS you should rather look at a different DNS provider. Consider switching to OpenDNS for example! They are really fast and you get URL typo-correction and lots of other useful features.
There are some few software (for example, VMWare Server 2) doesn’t work with Ubuntu and IPV6. This could be one reason.
i think that if IPv6 is not utilised within a LAN nor has the LAN external access to IPv6 networks then it is not needed & could cause unexpected issue’s therefore it should be disabled.
Yes the future of the inet is with IPv6 but at the moment not enough ISP’s use it or offer it so it is only usefull in development environments.
I disable IPV6 bacuse the campus I am on doesnt support IPV6 and internet doesnt work at all if IPV6 is enabled
I’m behind an ipv4-only router. ipv6 may be the future, but the future is not here yet.
Would’nt it be the right way to disable/blacklist the ipv6 kernel modules in /etc/modprobe.d/blacklist?
… for security reason. There are a lot of machines using tunneling of ipv6 over ipv4 (e.g.teredo in windows) to overcome firewall rules of the admins and expose that way the corporate networks to the outside world. What sense make firewalls and NAT adresses, when they just get traversed by ipv6 traffic.
also for security reasons, several services had remote exploits in their ipv6-implementation, more will come.
in jaunty the aliases file is empty. But the probs
seem to most effect the http://www…so doing about:config
in firefox/ network.dns.disableIPv6 changed to true
made me happy enough…
the reasoning behind diabling IPv6 is that its
too early and IPv4 still dominates by far way far.
so it avoids hangups to revert…tootles
Thanks for the information. Remarkable blog;)
Cool blog! Thanks for the information. Add to favorites;)
Useful information! Thanks to author!
I had to edit the file “menu.lst” there was no “grub” file to edit that I could find – but that did the trick. Thanks for the info. My e-mail is now much faster.
The information will be useful to many. Thanks to author!
Even if your isp is using ipv6 your modem/gateway most likely is using nat/pat to translate it to a ipv4 private address. Unless you have a machine right up against the interenet, like a webserver, you probably dont need ipv6.
I’m running 9.10 32-bit server, but do not see the aliases file.
I am running 9.10 at home and cannot get any internet access, not with a web browser or to do updates. In 8.10 and 9.04 this worked straight after installing. The file /etc/modprobe.d/aliases does not appear to be there.
Perhaps the file is somewhere else, or the system is different in 9.10. Fortunately I also have 9.04 installed and that works, but I have heard about lots of problems with 9.10. Hope they get them dealt with for the next long-term support release.
Re: Comment by toniisam on January 27, 2010
I believe you’re correct. I tried upgrading from Ubuntu 8.10 to 9.04, and it worked HORRIBLY. It caused the Firefox and SeaMonkey browsers talking through my Netgear WGR614 wireless router to slow to a crawl — about 1/10th the speed that my Windows computers run. At the time I couldn’t find an answer to my dilemma, so I had no choice except remove 9.04 and revert to 8.10, which I’m still using. I later read that Ubuntu 9.04 had IPv6 enabled by default. I also understand that most consumer network equipment doesn’t support IPv6 natively today, including the WGR614, although there is a way of doing it indirectly by “tunneling”. It’s a shame that Canonical Ltd. released this abomination on the user community. IPv4 should be enabled by default, with IPv6 available for those whose network environments support it. IPv6 may be the future of the Internet, but, as others have commented above, the future isn’t here yet.
Using sysctl you can disable IPv6 on the running system without rebooting:
sysctl -w net.ipv6.conf.all.disable_ipv6=1
To disable permanently add “net.ipv6.conf.all.disable_ipv6=1” to /etc/sysctl.conf.
I also have terribly slow internet on my usually trusty Ubuntu machine when upgraded to 10.04. It was fine during my first try out with the Live cd and immediately after install but once rebooted all networking slowed to a crawl. I’ve tried disabling ipv6 in Firefox without success. I also tried reinstalling on that machine with the same results.
The same version of Ubuntu works fine on my Netbook though.
i can’t find the aliases file to modify.
IPv6 is disabled through your info but what is the issue with this.
Add
net.ipv6.conf.all.disable_ipv6=1
to /etc/sysctl.conf and run sysctl -p.
Everything else is more less “wrong”. May want to reflect that in your blog.
Using 10.04 with updates-
same as above- no “aliases” file found!
some change is just a pain to users!!!
Thanks! very useful information.
@Daniel Aleksandersen, this is the future posting. IPV6 is still not in wide use and is still causing all kinds of problems.