Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Apr 2009 22:46:42 +0800
From:      Rommel Laranjo <rslaranjo@gmail.com>
To:        freebsd-bugs@freebsd.org
Subject:   Bug: Changing Stateless Autoconfigured IPv6 Address to Static  manually
Message-ID:  <f051005f0904220746h3bd2c229i2a43e67618a4cbfd@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hello everyone,

I need help. My box(Machine1) by default will perform IPv6 stateless
autoconfiguration and I need to change this autoconfigured address to static
manually without restarting.
Here are the steps I follow but I sure I missed something cause I was
unsuccessful of doing it.

1. I disabled sysctl knob to stop receiving rtadv
# sysctl -w net.inet6.ip6.accept_rtadv=0

2. I then removed the autoconfigured ipv6 address from the interface
# ifconfig em0 inet6 2001:db8:1234:abcd:20c:27ff:fe3d:63dd delete

3. I removed the default ipv6 route since I will replace with another route
# route delete -inet6 default

4. I then added the autoconfigured ipv6 address back to the interface to
make it static
# ifconfig em0 inet6 2001:db8:1234:abcd:20c:27ff:fe3d:63dd prefixlen 64 up

5. I added the new default ipv6 route
# route add -inet6 default 2001:db8:1234:abcd::1

At this point I pinged 2001:db8:1234:abcd:20c:27ff:fe3d:63dd from another
IPv6 box (Machine2) with IPv6 address of the same prefix
(2001:db8:1234:abcd:215:d3ff:fe4f:acaf) but with now success. But if I ping6
from Machine2 to may router 2001:db8:1234:abcd::1 I am successfull.

I tried to check IPv6 route information from Machine1 thru netstat -rnf
inet6
but have not found this entry:

2001:db8:1234:abcd::/64           link#1                        UC
em0

I hope someone could shed light on how to put this route into my ipv6
routing table.
Is this a bug in FreeBSD not automatically add this route after adding an
IPv6 address with this prefix?

Thanks,

Romskie



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f051005f0904220746h3bd2c229i2a43e67618a4cbfd>