# {RESOLVED} ipv6 / ipv4

## jazernorth

My stupid ISP (Qwest in Utah) doesn't support ipv6.  So when my Linux box is trying to use ipv6 first, it delays the loading of pages and such.  I thought I had ipv6 disabled completely, but when I updated to KDE4.6 and updated my kernel to 2.6.36 I find the ipv6 is back again (or at least it seems so).

Does anyone have a link or instructions on how to disable ipv6?  I have USE=-ipv6, but it seems the ipv6 was still compiled into the code.

I use Chromium, but it seems like firefox is using ipv6 as well.

Any help would greatly be appreciated.

Thanks!

Jay N.Last edited by jazernorth on Sat May 28, 2011 5:12 pm; edited 1 time in total

----------

## truc

in firefox you can disable ipv6 dns request:

```
network.dns.disableIPv6
```

----------

## jazernorth

There is a way to do it system wide.  I did it before, I just can't remember how and I can't find the documentation anymore.

Anyone know how to disable ipv6 completely on the system?

Thanks!

----------

## keenblade

 *jazernorth wrote:*   

> There is a way to do it system wide.  I did it before, I just can't remember how and I can't find the documentation anymore.
> 
> Anyone know how to disable ipv6 completely on the system?
> 
> Thanks!

 

I think you need to edit /etc/modprobe.d/modprobe.conf and /etc/modprobe.d/aliases.conf. In the files I found out this:

```

# Uncomment the network protocols you don't want loaded:

# alias net-pf-2 off            # IPv4

# alias net-pf-10 off           # IPv6

```

Probably editing just /etc/modprobe.d/aliases.conf is enough. Since running update-modules, /etc/modprobe.d/modprobe.conf will be updated, acording to the comments in the file.

----------

## jazernorth

Thanks keenblade!  Here is some more info, as I have already previously done what you suggested.

Here is my aliases.conf file, as it is now.  I already had the two network protocols uncommented.

```
LinuxServer jay # cat /etc/modprobe.d/aliases.conf 

# Aliases to tell insmod/modprobe which modules to use 

# Uncomment the network protocols you don't want loaded:

# alias net-pf-1 off            # Unix

# alias net-pf-2 off            # IPv4

# alias net-pf-3 off            # Amateur Radio AX.25

# alias net-pf-4 off            # IPX

# alias net-pf-5 off            # DDP / appletalk

# alias net-pf-6 off            # Amateur Radio NET/ROM

# alias net-pf-9 off            # X.25

alias net-pf-10 off             # IPv6

alias ipv6 off

# alias net-pf-11 off           # ROSE / Amateur Radio X.25 PLP

# alias net-pf-19 off           # Acorn Econet

alias char-major-10-175 agpgart

alias char-major-10-200 tun

alias char-major-81     bttv

alias char-major-108    ppp_generic

alias /dev/ppp          ppp_generic

alias tty-ldisc-3       ppp_async

alias tty-ldisc-14      ppp_synctty

alias ppp-compress-21   bsd_comp

alias ppp-compress-24   ppp_deflate

alias ppp-compress-26   ppp_deflate

# Crypto modules (see http://www.kerneli.org/)

alias loop-xfer-gen-0   loop_gen

alias loop-xfer-3       loop_fish2

alias loop-xfer-gen-10  loop_gen

alias cipher-2          des

alias cipher-3          fish2

alias cipher-4          blowfish

alias cipher-6          idea

alias cipher-7          serp6f

alias cipher-8          mars6

alias cipher-11         rc62

alias cipher-15         dfc2

alias cipher-16         rijndael

alias cipher-17         rc5

# Support for i2c and lm_sensors

alias char-major-89    i2c-dev

```

Here is my ifconfig output.  It shows a inet6 address, even though the two lines above are uncommented.

```
LinuxServer jay # ifconfig

eth0      Link encap:Ethernet  HWaddr 00:1f:bc:08:10:e3  

          inet addr:192.168.0.6  Bcast:192.168.0.255  Mask:255.255.255.0

          inet6 addr: fe80::21f:bcff:fe08:10e3/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:174685 errors:0 dropped:0 overruns:0 frame:0

          TX packets:154265 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:113863603 (108.5 MiB)  TX bytes:32503506 (30.9 MiB)

          Interrupt:44 Base address:0xc000 

```

I might be confused, but I'm pretty sure ipv6 is still active.

----------

## keenblade

jazernorth, just to be sure, did you reboot after changes?

Also edit /etc/modprobe.d/modprobe.conf ,too.

----------

## jazernorth

I have done so many changes in the last 24 hours, I thought, why not restart again.  So I just did a reboot and it is still showing inet6 in ifconfig output.

Here is a listing of the /etc/modprobe.d directory.  

```
LinuxServer modprobe.d # ls

aliases.conf  alsa.conf  blacklist.conf  i386.conf  nvidia.conf  pnp-aliases.conf  ppp.conf  usb-load-ehci-first.conf
```

You'll see that I don't have a modprobe.conf.  I even ran udpate-modules.

```
LinuxServer modprobe.d # update-modules -v    

 * We have just /etc/modprobe.d; Nothing to do!
```

Thanks for the help, and any more help is much appreciated.

----------

## keenblade

I think for this to work you need to build ipv6 as a module, not built-in kernel. So, you may need to compile kernel without ipv6 or as a module. I guess, the options in /etc/modprobe.d/ will only apply to the ones that are buillt as modules.

----------

## jazernorth

If you were close by, I'd kiss you!

Thanks!

It was compiled into the kernel.  Apparently between kernel-2.6.36-gentoo-r5 and kernel-2.6.37-gentoo-r4 the IPv6 option in the kernel went from module to built in.

For those in the same situation as me, here is what you do.

```

cd /usr/src/linux

make clean

make menuconfig

Networking Support --->

  Networking Options --->

    < >The IPv6 protocol ---> {disable this one}

exit menuconfig

recompile kernel and copy to /boot (see Gentoo instructions for this)

reboot.

```

Thank you thank you thank you!

Web browsers and other network items now work quickly, no more waiting for IPv6 to fail first.

----------

## keenblade

 *jazernorth wrote:*   

> If you were close by, I'd kiss you!
> 
> Thanks!
> 
> For those in the same situation as me, here is what you do.
> ...

 

 :Smile:  You're welcome.

Btw, I build IPv6 protocol as module just to test. And it is successfully disabled with the modprobe.conf and aliases.conf, as mentioned before.

----------

