Reply
Thread Tools
Posts: 175 | Thanked: 210 times | Joined on Mar 2013
#1
Hello,

So, I seem to find some infos about how to enable ipv6 on the N900 but not on how to completely disable it.
I don't use ipv6 and sometimes the dns queries are slow because an ipv6 is first looked for before asking for an ipv4.
And also because I would rather use ipv4 only (I understand the usefulness of ipv6 but I never completely understood how it worked).

I've tried :
Code:
sysctl -w net.ipv6.conf.all.disable_ipv6=1
sysctl -w net.ipv6.conf.default.disable_ipv6=1
but it doesn't seem to work.

Any ideas?
 
Community Council | Posts: 677 | Thanked: 1,227 times | Joined on Sep 2010 @ Mbabane
#2
are you sure about ipv6??? N900 isn't really IPv6-friendly by default. it is possible to use IPv6 on it after a lot of 'sweat'

So I think it's most likely you have a completely different problem/cause for your slowness, not IPv6.

What is in your resolv.conf files (in /etc and /var/run) ... remove any IPv6 nameservers if you have them. Do you get any IPv6 addresses assigned to your connections?

Last edited by sicelo; 2017-02-10 at 07:33.
 
Posts: 175 | Thanked: 210 times | Joined on Mar 2013
#3
No ipv6, at least on grps, on wlan I have an ipv6 when connected at home but my network doesn't have ipv6 so I suppose it is a local ipv6 (as said I don't understand much of ipv6), and I'm not at home now to get the ip.

Code:
gprs0     Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  
          inet addr:10.127.47.xxx  P-t-P:10.127.47.xxx  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP  MTU:1400  Metric:1
          RX packets:2371 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1700 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:10 
          RX bytes:2679790 (2.5 MiB)  TX bytes:120760 (117.9 KiB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:5935 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5935 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:381592 (372.6 KiB)  TX bytes:381592 (372.6 KiB)

phonet0   Link encap:UNSPEC  HWaddr 15-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  
          UP POINTOPOINT RUNNING NOARP  MTU:4000  Metric:1
          RX packets:73866 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26775 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100 
          RX bytes:29760428 (28.3 MiB)  TX bytes:1859874 (1.7 MiB)
When I do a nslookup I get also ipv6 address.

Code:
Server:    127.0.0.1
Address 1: 127.0.0.1 N900

Name:      google.com
Address 1: 216.58.214.238 bud02s24-in-f14.1e100.net
Address 2: 2a00:1450:400d:807::200e bud02s22-in-x0e.1e100.net
In /etc/resolv.conf I have 127.0.0.1 and in /var/run/resolv,conf.gprs0 I have 2 nameservers but only ipv4 addresses.

When activating dnsmasq log-queries I get a lot of querie[AAAA] before getting querie[A], so it is looking first for an ipv6 before asking for an ipv4.

As stated before, I don't really understand how ipv6 works and therefore I would rather disable it, as for now it is not really needed (don't have ipv6 enabled on any of my other devices and they work as they should).

Any idea how to avoid any interaction with ipv6 on the N900?

Last edited by Malakai; 2017-02-10 at 16:03. Reason: Typos
 
Posts: 175 | Thanked: 210 times | Joined on Mar 2013
#4
On my home wlan I get this ipv6 :

Code:
inet6 addr: fe80::5e57:c8ff:fe5d:df13/64 Scope:Link
But as mentioned I don't have ipv6 on my home network, so I don't know what this ipv6 is referring to.

On an nslookup of google.com I get :

Code:
Server:    127.0.0.1
Address 1: 127.0.0.1 N900

Name:      google.com
Address 1: 216.58.214.238 bud02s24-in-f14.1e100.net
Address 2: 2a00:1450:4016:803::200e muc03s08-in-x0e.1e100.net
So the same ipv4 but a different ipv6.....?
 
Posts: 2,290 | Thanked: 4,133 times | Joined on Apr 2010 @ UK
#5
You can disable ipv6 in about:config within MicroB.

v6 is enabled on most modern stuff now to aid transition to v6.
I assume you have a router that is v6 compatible at home?
The address you are getting is link-local fe80
__________________

Wiki Admin
sixwheeledbeast's wiki
Testing Squad Subscriber
- mcallerx - tenminutecore - FlopSwap - Qnotted - zzztop - Bander - Fight2048 -


Before posting or starting a thread please try this.
 

The Following 2 Users Say Thank You to sixwheeledbeast For This Useful Post:
Posts: 175 | Thanked: 210 times | Joined on Mar 2013
#6
Originally Posted by sixwheeledbeast View Post
You can disable ipv6 in about:config within MicroB.
I would like to disable ipv6 on all maemo, not only on the browser, as the issues I get are not only related to the browser.

Originally Posted by sixwheeledbeast View Post
v6 is enabled on most modern stuff now to aid transition to v6.
Yes, but for now I disabled it on my router, access points, laptop, desktop, servers, etc, as ipv6 had weird issues on some devices.

Originally Posted by sixwheeledbeast View Post
I assume you have a router that is v6 compatible at home?
Yes, but ipv6 is disabled and on my ISP config page I set not to be assigned with an ipv6.

Originally Posted by sixwheeledbeast View Post
The address you are getting is link-local fe80
How can I prevent it from enabling such an address and thus disable ipv6?
 
Community Council | Posts: 677 | Thanked: 1,227 times | Joined on Sep 2010 @ Mbabane
#7
 
Posts: 2,290 | Thanked: 4,133 times | Joined on Apr 2010 @ UK
#8
For you to get AAAA queries something on the router must be allowing v6 connections.
I would say if you are only having issues at home then it's the router you need to play with.
__________________

Wiki Admin
sixwheeledbeast's wiki
Testing Squad Subscriber
- mcallerx - tenminutecore - FlopSwap - Qnotted - zzztop - Bander - Fight2048 -


Before posting or starting a thread please try this.
 
Posts: 2,153 | Thanked: 8,462 times | Joined on May 2010
#9
Some notes from my side:

1) Stock kernel does not support IPv6, so by default there is no way to open/bind IPv6 socket

2) Basically all default Maemo 5 applications have disabled IPv6 support, so they do not try to open/bind IPv6 socket (even you have kernel with IPv6 support)

3) Disabling IPv6 support can be achieved by sysctl which you already wrote. When disable_ipv6=1 then *no* userspace application is able to open/bind IPv6 socket. Kernel acts same as if IPv6 support was disabled at compile time.

4) Asking DNS server for AAAA record has nothing and absolutely nothing with IPv6 support. You can ask for AAAA record of some hostname via IPv6 DNS socket and also via *IPv4* DNS socket. POSIX applications uses getaddrinfo() function (see man 3 getaddrinfo) which is supposed to do DNS lookups.

5) Router has nothing allowing IPv6 connections and AAAA queries. Those are two different things which has nothing in common. DNS is application protocol (layer 7) and IPv6 is network protocol (layer 3).

6) DNS resolving does not have to be slow "because of IPv6". You can ask (and system libraries probably do it) for ANY address for some host and you get both IPv4 and IPv6 address.

7) IPv6 Link-Local address cannot be used for making "internet" connection and IIRC connect() is not possible.

So... In IPv4-only network there should be absolutely no penalty with enabled IPv6 support in kernel or applications.

Problem can be in IPv4-only network which advertise IPv6 availabilty (which is non-working). But simple disabling IPv6 in kernel fixes it.

So if you are seeing some problems even after disabling IPv6 then it is probably not IPv6 related.
 

The Following 6 Users Say Thank You to pali For This Useful Post:
Posts: 175 | Thanked: 210 times | Joined on Mar 2013
#10
Thanks pali for the clarifications, really instructive.

Originally Posted by pali View Post
1) Stock kernel does not support IPv6, so by default there is no way to open/bind IPv6 socket
I installed kernel power on my N900.

Originally Posted by pali View Post
2) Basically all default Maemo 5 applications have disabled IPv6 support, so they do not try to open/bind IPv6 socket (even you have kernel with IPv6 support)
Good to know. This means that only dnsmasq makes queries for AAAA addresses.

Originally Posted by pali View Post
3) Disabling IPv6 support can be achieved by sysctl which you already wrote. When disable_ipv6=1 then *no* userspace application is able to open/bind IPv6 socket. Kernel acts same as if IPv6 support was disabled at compile time.
Where can I add the disable_ipv6=1 to disable ipv6 at boot, as Maemo doesn't seem to have /etc/sysctl.conf.

Originally Posted by pali View Post
4) Asking DNS server for AAAA record has nothing and absolutely nothing with IPv6 support. You can ask for AAAA record of some hostname via IPv6 DNS socket and also via *IPv4* DNS socket. POSIX applications uses getaddrinfo() function (see man 3 getaddrinfo) which is supposed to do DNS lookups.
That explains why I see AAAA queries even if I don't have an ipv6 address. The queries are made through ipv4. My question would now be how to prevent dnsmasq from querying ipv6? Tried to search for it on the web with no real success.

Originally Posted by pali View Post
5) Router has nothing allowing IPv6 connections and AAAA queries. Those are two different things which has nothing in common. DNS is application protocol (layer 7) and IPv6 is network protocol (layer 3).
When getting home I will try to see if other devices query the router for ipv6 addresses or only ipv4.

Originally Posted by pali View Post
6) DNS resolving does not have to be slow "because of IPv6". You can ask (and system libraries probably do it) for ANY address for some host and you get both IPv4 and IPv6 address.
I was believing that because on dnsmasq logs I always see AAAA queries and then A queries, but if you say that there is no impact on DNS resolution then I believe you

Originally Posted by pali View Post
7) IPv6 Link-Local address cannot be used for making "internet" connection and IIRC connect() is not possible.
Seems logical.

Originally Posted by pali View Post
So... In IPv4-only network there should be absolutely no penalty with enabled IPv6 support in kernel or applications.

Problem can be in IPv4-only network which advertise IPv6 availabilty (which is non-working). But simple disabling IPv6 in kernel fixes it.

So if you are seeing some problems even after disabling IPv6 then it is probably not IPv6 related.
Can't say that I have a real problem now, just wanted to be sure that it is deactivated and that it couldn't produce problems in a future specific situation, like my N900 connecting to an ipv6 network (I wouldn't want to have an ipv6 address in this situation ; only ipv4).

So to resume :
Where can I add the disable_ipv6=1 to disable ipv6 at boot, as Maemo doesn't seem to have /etc/sysctl.conf.
How to prevent dnsmasq from querying ipv6?

Thanks.
 
Reply

Tags
disable, ipv6-support, maemo

Thread Tools

 
Forum Jump


All times are GMT. The time now is 16:09.