I have an embedded system built using buildroot. I have had a number of network issues, one of which is that my machine cannot see its gateway despite it being on the same subnet. I have tried using wireshark to analyse what is going on without success so as a last resort, I am considering trying to turn off support for IPv6 as I do not need it (my device doesn't need DNS or anything similar, simply needs to be able to communicate with other local machines on its subnet). I have read that I can turn off IPv6 by editing /etc/modprobe.conf but this file does not exist on my setup. Is there anything else I can do to disable IPv6 or is the only option to build the kernel from scratch without IPv6 support?
Add a comment
|
1 Answer
I agree with Ulrich, that this doesn't sound like an IPv6 problem. However, here's how to disable IPv6.
In /etc/sysctl.conf set the following options:
net.ipv6.conf.all.autoconf = 0
net.ipv6.conf.all.accept_ra = 0
net.ipv6.conf.all.disable_ipv6 = 1
If you don't have /etc/sysctl.conf just create it and add those lines, then reboot.
Alternatively, each of these has an interface in /proc that you can flip (and/or create a script to do this at boot time).
echo 0 > /proc/sys/net/ipv6/conf/all/autoconf
echo 0 > /proc/sys/net/ipv6/conf/all/accept_ra
echo 1 > /proc/sys/net/ipv6/conf/all/disable_ipv6
-
Thanks for your answer. Unfortunately I do not have a
sysctl.conffile on my embedded system. I think I will try to recompile the kernel.mathematician1975– mathematician19752013-03-04 09:09:55 +00:00Commented Mar 4, 2013 at 9:09 -
Do you have a
sysctlcommand?bahamat– bahamat2013-03-08 20:52:18 +00:00Commented Mar 8, 2013 at 20:52 -
Yes I have a
sysctlcommand as part of the busybox binary. I can see an option to read from a specified file of which/etc/sysctl.confis the default. Perhaps I just need to create this file and input the lines you suggest, then runsysctl? You were right about it not being IPv6 problem though - I simply had incorrect information from the network administrator.mathematician1975– mathematician19752013-03-22 11:35:43 +00:00Commented Mar 22, 2013 at 11:35 -
Yes, you just need to create the file with the parameters you want and reboot.bahamat– bahamat2013-03-22 15:47:28 +00:00Commented Mar 22, 2013 at 15:47