Re: problem making IPv6 address from rtadvd prefix
Douglas Maus dmaus at speakeasy.net writes: As a final followup to this problem (still unresolved), I can say that my problem of the kernel not properly handling IPv6 router advertisements to generate an IPv6 global (2001:xx...) address (non- link-local) - may be specific to the hardware I was using, in that: in the same network environment (same switch, same Apple Airport ExtremeN router advertising IPv6) and same install CD on a MacMini with Core2Duo, running OpenBSD 5.0 I was able to easily get it to properly configure the 2001.xxx... address but on a Supermicro SYS-5015A-H (with Intel Atom 330 and dual Realtek RTL8111C-GR) it has failed to generate the 2001:xxx... address every time at least 6 times tried - in an additional huh - that's funny on the last time I tried to reinstall from beginning, I noticed that in the install process, in the network section after telling IPv4 to use 'dhcp', and IPv6 to use 'rtsol', then deciding to go back to the beginning with CTRL+C, in the second time through the network section, again 'dhcp' requested and received the dhcp IPv4 address, but the IPv6 section actually _offered_ an address of the form '2001:xxx...' I choose 'rtsol' - and after install and reboot, still no '2001.xxx...' address. (I may try to duplicate this and let it install with the '2001.xxx...' address, but I'm done for tonight.) I thought that perhaps this meant that the bsd.rd kernel of the installer seems to correctly process the IPv6 route advertisements, but something in the stock bsd(.mp) kernel may not. ? If anyone with more knowledge finds this a useful clue, then I'd be happy to follow more direction in debugging. Otherwise - I think I'll just call this one beyond me. Thanks.
Re: problem making IPv6 address from rtadvd prefix
On 2011-12-03, Douglas Maus dm...@speakeasy.net wrote: - Am I right that - if my ifconfig only has an inet6 link-local address, then I won't be able to connect to IPv6 hosts outside my local network? correct. - If my 'ifconfig re0' shows this: re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr 00:30:48:dc:75:df priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,master, rxpause,txpause) status: active inet6 fe80::230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 inet 10.0.1.8 netmask 0xff00 broadcast 10.0.1.255 then I won't be able to connect to global IPv6 hosts outside my network? correct. - If my router advertises the prefix 2001:470:1f07:15cc::/64, then the appropriate global address would be: 2001:470:1f07:15cc:230:48ff:fedc:75df ? correct. - Does StateLess Address AutoConfiguration refer to the configuration of just the link local address fe80::230:48ff:fedc:75df, or does it also include the global address 2001:470:1f07:15cc:230:48ff:fedc:75df ? the global address. - If 'netstat -f inet6 -rn' shows the row: 2001:470:1f07:15cc::/64link#1 UC 00 - 4 re0 then that indicates my machine is seeing the router advertised prefix? yes. - Since my first post, I think I have realized that - in /etc/hostname.re0 the line 'rtsol', does _not_ mean that at boot time the program /sbin/rtsol handles / performs SLAAC. The 'rtsol' in hostname.re0 triggers certain actions in /etc/netstart, correct? 'rtsol' does not configure address on interfaces, correct? rtsol sends the messages, but the configuration is done by the kernel, assuming net.inet6.ip6.forwarding=0 and net.inet6.ip6.accept_rtadv=1. - (I admit I do not understand shell scripts) /etc/netstart processes settings, and does both setting of address on interfaces, and configures routes? generally yes, but the ip6 auto addressing is done in the kernel, all netstart does here is to run rtsol. - The actual tool to set address is /sbin/ifconfig, correct? to manually set addresses, or set addresses from hostname.if files, yes. - When hostname.re0 has 'rtsol', is /etc/netstart supposed to (A) use the MAC or lladdr to configure the IPv6 link-local fe80::230:48ff:fedc:75df _and_ (B) listen for route advertisement with prefix, and then configure the global IPv6 address with prefix:lladdr ? the kernel does all this. - If (B) is true, then if my machine is correctly configured, I should get ifconfig to show both: inet6 fe80::230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 and something like: inet6 2001:470:1f07:15cc:230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 scopeid is for link-local addresses. it shoud look something like: vic0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr 00:0c:29:87:71:ca priority: 0 groups: egress media: Ethernet autoselect status: active inet6 fe80::20c:29ff:fe87:71ca%vic0 prefixlen 64 scopeid 0x1 inet 10.15.5.72 netmask 0xff00 broadcast 10.15.5.255 inet6 2001:4b10:1002:55:20c:29ff:fe87:71ca prefixlen 64 autoconf pltime 604440 vltime 2591640 - If (B) is not true, then what is the right way to get the global address configured at boot time? put 'rtsol' in the hostname.if file and this in sysctl.conf: net.inet6.ip6.forwarding=0 net.inet6.ip6.accept_rtadv=1 if you have these set and it's still failing, we'll need more information. specifically, a packet capture would be useful, as would nd6 debug logging. packet capture: tcpdump -s1500 -Xvvi interface proto icmp6 debug logging: set ddb.console=1 in sysctl.conf and reboot (you can't set this sysctl later on, you will get Operation not permitted). when the system has booted, make sure you're in a text mode console and then break into ddb (either hit ctrl+alt+esc, or send a BREAK if it's serial console, or run 'sysctl ddb.trigger=1') and then type: w nd6_debug 1 and c. it should look something like this: Stopped at Debugger: ldrbr15, [r15, r15, ror r15]! ddb w nd6_debug 1 nd6_debug 0= 1 ddb c you should then be back where you were at your regular console; run rtsol again and see if additional information shows up at the bottom of dmesg. - Will the global address need to be an 'alias' one, in addition to the link-local one? we don't use 'alias' with v6 (well, you can type it on the command line, but it doesn't change things; v6 accepts multiple addresses on an interface by default).
Re: problem making IPv6 address from rtadvd prefix
I did these: - edit /etcsysctl.conf so that ddb.console=1 - rebooted - in another shell ran $ tcpdump -s1500 -Xvvi re0 icmp6 ('interface proto icmp6' gave 'Syntax Error') - did ctrl-alt-esc, got Stopped at Debugger... ddbw nd6_debug 1 nd6_debug 0 = 1 ddbc - ran $ rtsol -D re0 - and got: checking if re0 is ready... re0 is ready set timer for re0 to 0:481765 New timer is 0:00481718 timer expiration on re0, state = 1 send RS on re0, whose state is 2 set timer for re0 to 4:0 New timer is 4:0163 received RA from fe80::21f:f3ff:fe40:ac51 on re0, state is 2 stop timer for re0 there is no timer - in the other tcpdump shell saw this: tcpdump: listening on re0, link-type EN10MB 15:13:53.750950 fe80::230:48ff:fedc:75df ff02::2: icmp6: router solicitation\ (src lladdr: 00:30:48:dc:75:df) (len 16, hlim 255) : 6000 0010 3aff fe80 `.:??... 0010: 0230 48ff fedc 75df ff02 .0H???u??... 0020: 0002 8500 fd56 ..?V 0030: 0101 0030 48dc 75df ...0H?u? 15:13:54.140179 fe80::21f:f3ff:fe40:ac51 ff02::1: icmp6: router advertisement\ (chlim=64, O router_ltime=1800, reachable_time=0, retrans_time=0)(src lladdr:\ 00:1f:f3:40:ac:51)(prefix info: LA valid_ltime=14400, preferred_ltime=3600,\ prefix=2001:470:1f07:15cc::/64)(unknown opt_type=25, opt_len=3) (len 80, hlim\ 255) : 6000 0050 3aff fe80 `P:??... 0010: 021f f3ff fe40 ac51 ff02 ..???@?Q?... 0020: 0001 8600 f841 4040 0708 ..?A@@.. 0030: 0101 001f f340 ac51 ?@?Q 0040: 0304 40c0 3840 0e10 ..@?..8@ 0050: 2001 0470 1f07 15cc ..p...? 0060: 1903 04b0 2001 0470 1f07 15cc ...? ..p...? 0070: 021f f3ff fe40 ac51 ..???@?Q - ran dmesg and got this: OpenBSD 5.0 (GENERIC.MP) #59: Wed Aug 17 10:19:44 MDT 2011 dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC.MP cpu0: Intel(R) Atom(TM) CPU 230 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,\ DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,TM2,SSSE3,CX16,xTPR,\ PDCM,MOVBE real mem = 2138238976 (2039MB) avail mem = 2093182976 (1996MB) mainbus0 at root bios0 at mainbus0: AT/286+ BIOS, date 07/10/09, BIOS32 rev. 0 @ 0xf0010, SMBIOS\ rev. 2.5 @ 0xfd170 (27 entries) bios0: vendor American Megatrends Inc. version 1.0a date 07/10/2009 bios0: Supermicro X7SLA acpi0 at bios0: rev 2 acpi0: sleep states S0 S1 S3 S4 S5 acpi0: tables DSDT FACP APIC MCFG SLIC OEMB acpi0: wakeup devices P0P2(S4) P0P1(S4) PS2K(S4) PS2M(S4) EUSB(S4) MC97(S4)\ P0P4(S4) P0P5(S4) P0P6(S4) P0P7(S4) P0P8(S4) LAN0(S1) P0P9(S4) LAN1(S1)\ USB0(S4) USB1(S4) USB2(S4) USB3(S4) SLPB(S4) acpitimer0 at acpi0: 3579545 Hz, 24 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: apic clock running at 133MHz cpu1 at mainbus0: apid 1 (application processor) cpu1: Intel(R) Atom(TM) CPU 230 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu1: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,\ DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,TM2,SSSE3,CX16,xTPR,\ PDCM,MOVBE ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 24 pins ioapic0: misconfigured as apic 1, remapped to apid 2 acpimcfg0 at acpi0 addr 0xf000, bus 0-63 acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus -1 (P0P2) acpiprt2 at acpi0: bus 3 (P0P1) acpiprt3 at acpi0: bus 1 (P0P4) acpiprt4 at acpi0: bus -1 (P0P5) acpiprt5 at acpi0: bus -1 (P0P6) acpiprt6 at acpi0: bus -1 (P0P7) acpiprt7 at acpi0: bus 2 (P0P8) acpiprt8 at acpi0: bus -1 (P0P9) acpicpu0 at acpi0 acpicpu1 at acpi0 acpibtn0 at acpi0: SLPB acpibtn1 at acpi0: PWRB bios0: ROM list: 0xc/0xaa00! pci0 at mainbus0 bus 0: configuration mode 1 (bios) pchb0 at pci0 dev 0 function 0 Intel 82945G Host rev 0x02 vga1 at pci0 dev 2 function 0 Intel 82945G Video rev 0x02 wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) intagp0 at vga1 agp0 at intagp0: aperture at 0xe000, size 0x1000 inteldrm0 at vga1: apic 2 int 16 drm0 at inteldrm0 ppb0 at pci0 dev 28 function 0 Intel 82801GB PCIE rev 0x01: apic 2 int 16 pci1 at ppb0 bus 1 ppb1 at pci0 dev 28 function 4 Intel 82801G PCIE rev 0x01: apic 2 int 16 pci2 at ppb1 bus 2 re0 at pci2 dev 0 function 0 Realtek 8168 rev 0x02: RTL8168C/8111C (0x3c00),\ apic 2 int 16, address 00:30:48:dc:75:df rgephy0 at re0 phy 7: RTL8169S/8110S PHY, rev. 2 uhci0 at pci0 dev 29 function 0 Intel 82801GB USB rev 0x01: apic 2 int 23 uhci1 at pci0 dev 29 function 1 Intel 82801GB USB rev 0x01: apic 2 int 19 uhci2 at pci0 dev 29 function 2 Intel 82801GB USB rev 0x01: apic 2 int 18 uhci3 at pci0 dev 29 function 3
Re: problem making IPv6 address from rtadvd prefix
On Wed, Nov 30, 2011 at 02:39:13PM +, Christian Weisgerber wrote: Douglas Maus dm...@speakeasy.net wrote: Also, is having the rtsold daemon running all the time required? No. If you have hostname.if with rtsol to set the route at boot, do you have to run rtsold? No. IPv6 routers regularly broadcast advertisements. If you have net.inet6.ip6.accept_rtadv set to 1, these advertisements will be automatically processed by the kernel. You only need to run rtsol to request a router advertisement right now, so you won't have to wait ten minutes. In other words, running rtsol once at startup (from hostname.if) is enough. Thank you for setting me straight on this. This explains why the man page for rtsold is so much about how to supervise an interface (and sending Router Solicitation messages). Almost nothing about what to do with an Advertisement. -- Christian naddy Weisgerber na...@mips.inka.de -- / Raimo Niskanen, Erlang/OTP, Ericsson AB
Re: problem making IPv6 address from rtadvd prefix
I do thank those that have replied with comments and suggestions. In my confusion, I feel forced to go back and re-assess some of my unspoken assumptions about IPv6 addresses and routing. On my small home network with Apple Airport router configured as tunnel to tunnelbroker.net, my MacOSX machines can connect to IPv6 (www.kame.net) but my OpenBSD 5.0 machine can't. I don't know why. I'd like it to work, but I also hope to learn more about networking along the way. I think my basic questions to make sure of my footing are: - Am I right that - if my ifconfig only has an inet6 link-local address, then I won't be able to connect to IPv6 hosts outside my local network? - If my 'ifconfig re0' shows this: re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr 00:30:48:dc:75:df priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,master, rxpause,txpause) status: active inet6 fe80::230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 inet 10.0.1.8 netmask 0xff00 broadcast 10.0.1.255 then I won't be able to connect to global IPv6 hosts outside my network? - If my router advertises the prefix 2001:470:1f07:15cc::/64, then the appropriate global address would be: 2001:470:1f07:15cc:230:48ff:fedc:75df ? - Does StateLess Address AutoConfiguration refer to the configuration of just the link local address fe80::230:48ff:fedc:75df, or does it also include the global address 2001:470:1f07:15cc:230:48ff:fedc:75df ? - If 'netstat -f inet6 -rn' shows the row: 2001:470:1f07:15cc::/64link#1 UC 00 - 4 re0 then that indicates my machine is seeing the router advertised prefix? - Since my first post, I think I have realized that - in /etc/hostname.re0 the line 'rtsol', does _not_ mean that at boot time the program /sbin/rtsol handles / performs SLAAC. The 'rtsol' in hostname.re0 triggers certain actions in /etc/netstart, correct? 'rtsol' does not configure address on interfaces, correct? - (I admit I do not understand shell scripts) /etc/netstart processes settings, and does both setting of address on interfaces, and configures routes? - The actual tool to set address is /sbin/ifconfig, correct? - When hostname.re0 has 'rtsol', is /etc/netstart supposed to (A) use the MAC or lladdr to configure the IPv6 link-local fe80::230:48ff:fedc:75df _and_ (B) listen for route advertisement with prefix, and then configure the global IPv6 address with prefix:lladdr ? - If (B) is true, then if my machine is correctly configured, I should get ifconfig to show both: inet6 fe80::230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 and something like: inet6 2001:470:1f07:15cc:230:48ff:fedc:75df%re0 prefixlen 64 scopeid 0x1 - If (B) is not true, then what is the right way to get the global address configured at boot time? - Will the global address need to be an 'alias' one, in addition to the link-local one? Thanks so much.
Re: problem making IPv6 address from rtadvd prefix
On 2011-11-30, Douglas Maus dm...@speakeasy.net wrote: Followup: (sorry for unconventional thread posting and the delay - learning OpenBSD is my very late night hobby so I'm not subscribed to the misc list) If you post from gmane's web interface, it will keep the references etc intact, which makes it easier to follow the thread. stu wrote: no dmesg. okay - sorry - I've put it at the bottom of this post (always seems to me like a waste of electrons) That is less important than the time of people who are trying to help. :) I suspect some re(4) don't do multicast correctly. does it start working if you leave tcpdump running on the interface? When I let tcpdump run for a couple minutes before to snag the route solicitation and advertisement - no help. How long of a time are you suggesting? Yes that would do the trick (in some cases the nic may need to be in promiscuous mode while the advertisement is received; also in some other cases it may be necessary that it is *not* in promiscuous mode)... bios0: Supermicro X7SLA ...but I can confirm the realtek nic on those does handle multicast OK with the OpenBSD re(4) driver. for your obfuscated MAC addresses, did you just change them in the email or did you set them on the nic with ifconfig lladdr? no, I did not set them with ifconfig I just fudged them in the email to hide my MAC (don't most people do that - make up DEAD:BEEF:CAFE:BABE etc?) Only people who want to make it a bit harder for others to help them ;) (sometimes people use lladdr or similar to change the actualy address on the nice and might inadvertently flip the U/L or multicast bits of the address). (and if you're using IPv6 SLAAC, you'll likely be sending that mac address to all sorts of places anyway...) here's my rtsol $ sudo rtsol -d re0 checking if re0 is ready... re0 is ready send RS on re0, whose state is 2 received RA from fe80::00a1:b1ff:fea1:b1e1 on re0, state is 2 stop timer for re0 there is no timer that looks right It seems to see the RA however, this doesn't say anything about processing the prefix. Is there any toggle/flag to get it to output debug info about the prefix? I would watch output from 'tcpdump -nire0 -s1500 -Xvvv icmp6' while doing the rtsol -d re0, you should see something like this:- # tcpdump -nitrunk0 -s1500 -Xvvv icmp6 tcpdump: listening on trunk0, link-type EN10MB tcpdump: WARNING: compensating for unaligned libpcap packets 12:29:33.242725 fe80::21b:21ff:fe2d:f70c ff02::2: icmp6: router solicitation (src lladdr: 00:1b:21:2d:f7:0c) (len 16, hlim 255) : 6000 0010 3aff fe80 `.:. 0010: 021b 21ff fe2d f70c ff02 ..!..-.. 0020: 0002 8500 4a84 ..J. 0030: 0101 001b 212d f70c !-.. 12:29:33.727694 fe80::20d:b9ff:fe17:cc4 ff02::1: icmp6: router advertisement(chlim=64, router_ltime=1800, reachable_time=0, retrans_time=0)(src lladdr: 00:0d:b9:17:0c:c4)(prefix info: LA valid_ltime=2592000, preferred_ltime=604800, prefix=2001:4b10:1002:100::/64) (len 56, hlim 255) : 6000 0038 3aff fe80 `8:. 0010: 020d b9ff fe17 0cc4 ff02 0020: 0001 8600 1fa5 4000 0708 @... 0030: 0101 000d b917 0cc4 0040: 0304 40c0 0027 8d00 0009 3a80 ..@..':. 0050: 2001 4b10 1002 0100 .K. mherrb further suggested: But you may have a crappy ethernet switch or hub in the path that blocks or damages multicast frames. I've had such a device it the past. Replacing it by a little more expensive switch fixed my v6 SLAAC issues. ...and sometimes the expensive switches need special config ;)
Re: problem making IPv6 address from rtadvd prefix
On Tue, Nov 29, 2011 at 07:59:41PM -0500, Douglas Maus wrote: Followup: (sorry for unconventional thread posting and the delay - learning OpenBSD is my very late night hobby so I'm not subscribed to the misc list) 3 persons posted with suggestions (mherrb, stu, and raimo) mherrb wrote: A few stuff to check: - you say you modified sysctl.conf, but did you execute the sysctl command or rebooted to have those changes taken into account ? I rebooted, then checked by running 'sysctl net.inet6' to confirm changes so, not that. - what does the 'rtsol -d' command report when executed ? (it will manually trigger a router sollicitation) and raimo also suggested: Try (see rtsold(8)): # pkill -USR1 rtsold # cat /var/run/rtsold.dump \ Interface re0 probe interval: infinity no probe timer interface status: active other config: off rtsold status: IDLE carrier detection: available probes: 0, dadcount = 0 no timer number of valid RAs: 11940 here's my rtsol $ sudo rtsol -d re0 checking if re0 is ready... re0 is ready send RS on re0, whose state is 2 received RA from fe80::00a1:b1ff:fea1:b1e1 on re0, state is 2 stop timer for re0 there is no timer and here is my rtsold.dump Interface re0 probe interval: infinity no probe timer interface status: active other config: on rtsold status: IDLE carrier detection: available probes: 0, dadcount = 0 no timer number of valid RAs: 2 It seems to see the RA however, this doesn't say anything about processing the prefix. Is there any toggle/flag to get it to output debug info about the prefix? And what is this 'other config'? I've googled it, and can't find enough to educate myself. I do not know what is causing your symptoms, but have not run out of hints completely yet (but almost). rtsold takes -f and -D flags that might be useful. Maybe a ktrace of rtsold could give more info. 'other config' is actually mentioned in the man page for rtsold. Just a guess, if your Apple router perhaps uses this Other Configuration flag and you have not supplied an -O switch to rtsold maybe it gets confused and does not complete its tasks (setting the IPv6 address). Note that your routing table in a previous mail had got your expected prefix to the right link, probably the work of rtsold... Also, is having the rtsold daemon running all the time required? If you have hostname.if with rtsol to set the route at boot, do you have to run rtsold? I guess that would be useful on large dynamic networks, but simple home networks, would the absence of rtsold be a problem? I was not aware of that from reading the man pages for hostname.if and rtsol(d). Again, guessing, but... since router advertisements has a lifetime timeout value suggests it might have to be re-run (or preferably run in the background) during the host's uptime. mherrb further suggested: But you may have a crappy ethernet switch or hub in the path that blocks or damages multicast frames. I've had such a device it the past. Replacing it by a little more expensive switch fixed my v6 SLAAC issues. A) The switch is an HP Procurve 1410-16G (not inexpensive) B) The MacOSX machines in my network are not having a problem configuring with the proper prefix, so I don't think it is the switch stu wrote: no dmesg. okay - sorry - I've put it at the bottom of this post (always seems to me like a waste of electrons) I suspect some re(4) don't do multicast correctly. does it start working if you leave tcpdump running on the interface? When I let tcpdump run for a couple minutes before to snag the route solicitation and advertisement - no help. How long of a time are you suggesting? for your obfuscated MAC addresses, did you just change them in the email or did you set them on the nic with ifconfig lladdr? no, I did not set them with ifconfig I just fudged them in the email to hide my MAC (don't most people do that - make up DEAD:BEEF:CAFE:BABE etc?) So, still no luck. I also tried setting IPv4 to do dhcp in hostname.re0 instead of the fixed address like in my original email, and rebooted several times, but still no help. Other thoughts? thank you for your offers of help and advice dmesg: OpenBSD 5.0 (GENERIC.MP) #59: Wed Aug 17 10:19:44 MDT 2011 dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC.MP cpu0: Intel(R) Atom(TM) CPU 330 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,A CPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,TM2,SSSE3,CX16,xTPR,PDC M,MOVBE real mem = 2138238976 (2039MB) avail mem = 2093182976 (1996MB) mainbus0 at root bios0 at mainbus0: AT/286+ BIOS, date 05/13/10, BIOS32 rev. 0 @ 0xf0010, SMBIOS rev. 2.5 @ 0xfd170 (27 entries) bios0: vendor American Megatrends Inc. version 1.0b date 05/13/2010
Re: problem making IPv6 address from rtadvd prefix
Douglas Maus dm...@speakeasy.net wrote: Also, is having the rtsold daemon running all the time required? No. If you have hostname.if with rtsol to set the route at boot, do you have to run rtsold? No. IPv6 routers regularly broadcast advertisements. If you have net.inet6.ip6.accept_rtadv set to 1, these advertisements will be automatically processed by the kernel. You only need to run rtsol to request a router advertisement right now, so you won't have to wait ten minutes. In other words, running rtsol once at startup (from hostname.if) is enough. -- Christian naddy Weisgerber na...@mips.inka.de
Re: problem making IPv6 address from rtadvd prefix
no dmesg. I suspect some re(4) don't do multicast correctly. does it start working if you leave tcpdump running on the interface? for your obfuscated MAC addresses, did you just change them in the email or did you set them on the nic with ifconfig lladdr? On 2011-11-29, Douglas Maus dm...@speakeasy.net wrote: I could use some help understanding IPv6 autoconfiguration on OpenBSD5.0 If an OpenBSD system is configured to be an IPv6 host and to use 'rtsol', and the network IPv6 router running rtadvd sends a prefix (like 2001:.../64) as part of the route advertisements, then isn't the host supposed to use the prefix to generate an IPv6 address with that 2001: prefix and fill the last 64 bits with bits from the ethernet ID / EUI? I'm trying to work my way through / debug this, and I'm stumped. I'll document what I have checked - please let me know any other configurations or responses I should check. /etc/hostname.re0 (setup during installation, with rtsol selected) inet 10.0.1.2 255.255.255.0 up rtsol /etc/sysctl.conf net.inet6.icmp6.rediraccept=1 net.inet6.ip6.forwarding=0 net.inet6.ip6.accept_rtadv=1 (although installation set rediraccept to 1, I needed to manually set ip6.forwarding=0 and ip6.accept_rtadv=1 - perhaps this should be fixed in the install script) $ ifconfig re0 (sanitized of real EUI) re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr c1:a1:c1:a1:f1:e1 priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,master,rxpause,txpause) status: active inet 10.0.1.2 netmask 0xff00 broadcast 10.0.1.255 inet6 fe80::c1a1:c1ff:fea1:f1e1%re0 prefixlen 64 scopeid 0x1 (note - only the link-local IPv6 address) tcpdump of the router advertisement (sanitized), the router is an Apple Airport ExtremeN which advertises the link-local address of the router, and also advertises the prefix for this LAN: $tcpdump -v -i re0 12:00:00.00 fe80::c1a1:b1ff:fea1:b1e1 ff02::1: icmp6: router advertisement(chlim=64, O router_ltime=1800, reachable_time=0, retrans_time=0)(src lladdr: c1:a1:b1:a1:b1:e1)(prefix info: LA valid_ltime=14400, preferred_ltime=3600, prefix=2001:470:dead:beef::/64)[ndp opt] (len 80, hlim 255) routing table (output of netstat -rn -f inet6, sanitized) Internet6: DestinationGatewayFlags Refs Use Mtu Prio Iface ::/104 ::1UGRS 0 0 - 8 lo0 ::/96 ::1UGRS 0 0 - 8 lo0 defaultfe80::c1a1:b1ff:fea1:b1e1%re0 UG 0 214 - 4 re0 ::1::1UH14 0 33196 4 lo0 ::127.0.0.0/104::1UGRS 0 0 - 8 lo0 ::224.0.0.0/100::1UGRS 0 0 - 8 lo0 ::255.0.0.0/104::1UGRS 0 0 - 8 lo0 :::0.0.0.0/96 ::1UGRS 0 0 - 8 lo0 2001:470:dead:beef::/64link#1 UC 0 0 - 4 re0 2002::/24 ::1UGRS 0 0 - 8 lo0 2002:7f00::/24 ::1UGRS 0 0 - 8 lo0 2002:e000::/20 ::1UGRS 0 0 - 8 lo0 2002:ff00::/24 ::1UGRS 0 0 - 8 lo0 fe80::/10 ::1UGRS 0 0 - 8 lo0 fe80::%re0/64 link#1 UC 1 0 - 4 re0 fe80::c1a1:b1ff:fea1:b1e1%re0 c1:a1:b1:a1:b1:e1 UHLc 1 7 - 4 re0 fe80::c1a1:c1ff:fea1:f1e1%re0 c1:a1:c1:a1:f1:e1 HL 1 0 - 4 lo0 fe80::%lo0/64 fe80::1%lo0U 0 0 - 4 lo0 fe80::1%lo0link#4 UHL0 0 - 4 lo0 fec0::/10 ::1UGRS 0 0 - 8 lo0 ff01::/16 ::1UGRS 0 0 - 8 lo0 ff01::%re0/32 link#1 UC 0 0 - 4 re0 ff01::%lo0/32 fe80::1%lo0UC 0 0 - 4 lo0 ff02::/16 ::1UGRS 0 0 - 8 lo0 ff02::%re0/32 link#1 UC 0 0 - 4 re0 ff02::%lo0/32
Re: problem making IPv6 address from rtadvd prefix
On Mon, Nov 28, 2011 at 09:57:06PM -0500, Douglas Maus wrote: I could use some help understanding IPv6 autoconfiguration on OpenBSD5.0 If an OpenBSD system is configured to be an IPv6 host and to use 'rtsol', and the network IPv6 router running rtadvd sends a prefix (like 2001:.../64) as part of the route advertisements, then isn't the host supposed to use the prefix to generate an IPv6 address with that 2001: prefix and fill the last 64 bits with bits from the ethernet ID / EUI? I'm trying to work my way through / debug this, and I'm stumped. I'll document what I have checked - please let me know any other configurations or responses I should check. /etc/hostname.re0 (setup during installation, with rtsol selected) inet 10.0.1.2 255.255.255.0 up rtsol /etc/sysctl.conf net.inet6.icmp6.rediraccept=1 net.inet6.ip6.forwarding=0 net.inet6.ip6.accept_rtadv=1 (although installation set rediraccept to 1, I needed to manually set ip6.forwarding=0 and ip6.accept_rtadv=1 - perhaps this should be fixed in the install script) dmesg excerpt: OpenBSD 5.0 (GENERIC.MP) #63: Wed Aug 17 10:14:30 MDT 2011 dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP : re0 at pci4 dev 0 function 0 Realtek 8168 rev 0x06: RTL8168E/8111E (0x2c00), apic 0 int 19, address de:ad:be:ef:ca:fe rgephy0 at re0 phy 7: RTL8169S/8110S PHY, rev. 4 For me it works just fine and my settings follows here... /etc/rc.conf.local: rtsold_flags=re0 /etc/hostname.re0: dhcp up rtsol /etc/sysctl.conf: net.inet6.ip6.forwarding=0 net.inet6.ip6.accept_rtadv=1 net.inet6.icmp6.rediraccept=1 # ifconfig re0 re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr de:ad:be:ef:ca:fe priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,rxpause,txpause) status: active inet6 fe80::dcad:beff:feef:cafe%re0 prefixlen 64 scopeid 0x1 inet 192.168.0:123 netmask 0xff00 broadcast 192.168.0.255 inet6 fec0::dcad:beff:feef:cafe prefixlen 64 autoconf pltime 604761 vltime 2591961 Try (see rtsold(8)): # pkill -USR1 rtsold # cat /var/run/rtsold.dump Interface re0 probe interval: infinity no probe timer interface status: active other config: off rtsold status: IDLE carrier detection: available probes: 0, dadcount = 0 no timer number of valid RAs: 11940 $ ifconfig re0 (sanitized of real EUI) re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr c1:a1:c1:a1:f1:e1 priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,master,rxpause,txpause) status: active inet 10.0.1.2 netmask 0xff00 broadcast 10.0.1.255 inet6 fe80::c1a1:c1ff:fea1:f1e1%re0 prefixlen 64 scopeid 0x1 (note - only the link-local IPv6 address) tcpdump of the router advertisement (sanitized), the router is an Apple Airport ExtremeN which advertises the link-local address of the router, and also advertises the prefix for this LAN: $tcpdump -v -i re0 12:00:00.00 fe80::c1a1:b1ff:fea1:b1e1 ff02::1: icmp6: router advertisement(chlim=64, O router_ltime=1800, reachable_time=0, retrans_time=0)(src lladdr: c1:a1:b1:a1:b1:e1)(prefix info: LA valid_ltime=14400, preferred_ltime=3600, prefix=2001:470:dead:beef::/64)[ndp opt] (len 80, hlim 255) routing table (output of netstat -rn -f inet6, sanitized) Internet6: DestinationGatewayFlags Refs Use Mtu Prio Iface ::/104 ::1UGRS 0 0 - 8 lo0 ::/96 ::1UGRS 0 0 - 8 lo0 defaultfe80::c1a1:b1ff:fea1:b1e1%re0 UG 0 214 - 4 re0 ::1::1UH14 0 33196 4 lo0 ::127.0.0.0/104::1UGRS 0 0 - 8 lo0 ::224.0.0.0/100::1UGRS 0 0 - 8 lo0 ::255.0.0.0/104::1UGRS 0 0 - 8 lo0 :::0.0.0.0/96 ::1UGRS 0 0 - 8 lo0 2001:470:dead:beef::/64link#1 UC 0 0 - 4 re0 2002::/24 ::1UGRS 0 0 - 8 lo0 2002:7f00::/24 ::1UGRS 0 0 - 8 lo0 2002:e000::/20 ::1UGRS 0 0 - 8 lo0 2002:ff00::/24 ::1
Re: problem making IPv6 address from rtadvd prefix
Followup: (sorry for unconventional thread posting and the delay - learning OpenBSD is my very late night hobby so I'm not subscribed to the misc list) 3 persons posted with suggestions (mherrb, stu, and raimo) mherrb wrote: A few stuff to check: - you say you modified sysctl.conf, but did you execute the sysctl command or rebooted to have those changes taken into account ? I rebooted, then checked by running 'sysctl net.inet6' to confirm changes so, not that. - what does the 'rtsol -d' command report when executed ? (it will manually trigger a router sollicitation) and raimo also suggested: Try (see rtsold(8)): # pkill -USR1 rtsold # cat /var/run/rtsold.dump \ Interface re0 probe interval: infinity no probe timer interface status: active other config: off rtsold status: IDLE carrier detection: available probes: 0, dadcount = 0 no timer number of valid RAs: 11940 here's my rtsol $ sudo rtsol -d re0 checking if re0 is ready... re0 is ready send RS on re0, whose state is 2 received RA from fe80::00a1:b1ff:fea1:b1e1 on re0, state is 2 stop timer for re0 there is no timer and here is my rtsold.dump Interface re0 probe interval: infinity no probe timer interface status: active other config: on rtsold status: IDLE carrier detection: available probes: 0, dadcount = 0 no timer number of valid RAs: 2 It seems to see the RA however, this doesn't say anything about processing the prefix. Is there any toggle/flag to get it to output debug info about the prefix? And what is this 'other config'? I've googled it, and can't find enough to educate myself. Also, is having the rtsold daemon running all the time required? If you have hostname.if with rtsol to set the route at boot, do you have to run rtsold? I guess that would be useful on large dynamic networks, but simple home networks, would the absence of rtsold be a problem? I was not aware of that from reading the man pages for hostname.if and rtsol(d). mherrb further suggested: But you may have a crappy ethernet switch or hub in the path that blocks or damages multicast frames. I've had such a device it the past. Replacing it by a little more expensive switch fixed my v6 SLAAC issues. A) The switch is an HP Procurve 1410-16G (not inexpensive) B) The MacOSX machines in my network are not having a problem configuring with the proper prefix, so I don't think it is the switch stu wrote: no dmesg. okay - sorry - I've put it at the bottom of this post (always seems to me like a waste of electrons) I suspect some re(4) don't do multicast correctly. does it start working if you leave tcpdump running on the interface? When I let tcpdump run for a couple minutes before to snag the route solicitation and advertisement - no help. How long of a time are you suggesting? for your obfuscated MAC addresses, did you just change them in the email or did you set them on the nic with ifconfig lladdr? no, I did not set them with ifconfig I just fudged them in the email to hide my MAC (don't most people do that - make up DEAD:BEEF:CAFE:BABE etc?) So, still no luck. I also tried setting IPv4 to do dhcp in hostname.re0 instead of the fixed address like in my original email, and rebooted several times, but still no help. Other thoughts? thank you for your offers of help and advice dmesg: OpenBSD 5.0 (GENERIC.MP) #59: Wed Aug 17 10:19:44 MDT 2011 dera...@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC.MP cpu0: Intel(R) Atom(TM) CPU 330 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,A CPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,TM2,SSSE3,CX16,xTPR,PDC M,MOVBE real mem = 2138238976 (2039MB) avail mem = 2093182976 (1996MB) mainbus0 at root bios0 at mainbus0: AT/286+ BIOS, date 05/13/10, BIOS32 rev. 0 @ 0xf0010, SMBIOS rev. 2.5 @ 0xfd170 (27 entries) bios0: vendor American Megatrends Inc. version 1.0b date 05/13/2010 bios0: Supermicro X7SLA acpi0 at bios0: rev 2 acpi0: sleep states S0 S1 S3 S4 S5 acpi0: tables DSDT FACP APIC MCFG SLIC OEMB acpi0: wakeup devices P0P2(S4) P0P1(S4) PS2K(S4) PS2M(S4) EUSB(S4) MC97(S4) P0P4(S4) P0P5(S4) P0P6(S4) P0P7(S4) P0P8(S4) LAN0(S1) P0P9(S4) LAN1(S1) USB0(S4) USB1(S4) USB2(S4) USB3(S4) SLPB(S4) acpitimer0 at acpi0: 3579545 Hz, 24 bits acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: apic clock running at 133MHz cpu1 at mainbus0: apid 2 (application processor) cpu1: Intel(R) Atom(TM) CPU 330 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu1: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,A CPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,MWAIT,DS-CPL,TM2,SSSE3,CX16,xTPR,PDC M,MOVBE cpu2 at mainbus0: apid 1 (application processor) cpu2: Intel(R) Atom(TM) CPU 330 @ 1.60GHz (GenuineIntel 686-class) 1.61 GHz cpu2: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,CFLUSH,DS,A
Re: problem making IPv6 address from rtadvd prefix
On Mon, Nov 28, 2011 at 09:57:06PM -0500, Douglas Maus wrote: I could use some help understanding IPv6 autoconfiguration on OpenBSD5.0 If an OpenBSD system is configured to be an IPv6 host and to use 'rtsol', and the network IPv6 router running rtadvd sends a prefix (like 2001:.../64) as part of the route advertisements, then isn't the host supposed to use the prefix to generate an IPv6 address with that 2001: prefix and fill the last 64 bits with bits from the ethernet ID / EUI? I'm trying to work my way through / debug this, and I'm stumped. I'll document what I have checked - please let me know any other configurations or responses I should check. /etc/hostname.re0 (setup during installation, with rtsol selected) inet 10.0.1.2 255.255.255.0 up rtsol /etc/sysctl.conf net.inet6.icmp6.rediraccept=1 net.inet6.ip6.forwarding=0 net.inet6.ip6.accept_rtadv=1 (although installation set rediraccept to 1, I needed to manually set ip6.forwarding=0 and ip6.accept_rtadv=1 - perhaps this should be fixed in the install script) $ ifconfig re0 (sanitized of real EUI) re0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST mtu 1500 lladdr c1:a1:c1:a1:f1:e1 priority: 0 groups: egress media: Ethernet autoselect (1000baseT full-duplex,master,rxpause,txpause) status: active inet 10.0.1.2 netmask 0xff00 broadcast 10.0.1.255 inet6 fe80::c1a1:c1ff:fea1:f1e1%re0 prefixlen 64 scopeid 0x1 (note - only the link-local IPv6 address) tcpdump of the router advertisement (sanitized), the router is an Apple Airport ExtremeN which advertises the link-local address of the router, and also advertises the prefix for this LAN: $tcpdump -v -i re0 12:00:00.00 fe80::c1a1:b1ff:fea1:b1e1 ff02::1: icmp6: router advertisement(chlim=64, O router_ltime=1800, reachable_time=0, retrans_time=0)(src lladdr: c1:a1:b1:a1:b1:e1)(prefix info: LA valid_ltime=14400, preferred_ltime=3600, prefix=2001:470:dead:beef::/64)[ndp opt] (len 80, hlim 255) routing table (output of netstat -rn -f inet6, sanitized) Internet6: DestinationGatewayFlags Refs Use Mtu Prio Iface ::/104 ::1UGRS 0 0 - 8 lo0 ::/96 ::1UGRS 0 0 - 8 lo0 defaultfe80::c1a1:b1ff:fea1:b1e1%re0 UG 0 214 - 4 re0 ::1::1UH14 0 33196 4 lo0 ::127.0.0.0/104::1UGRS 0 0 - 8 lo0 ::224.0.0.0/100::1UGRS 0 0 - 8 lo0 ::255.0.0.0/104::1UGRS 0 0 - 8 lo0 :::0.0.0.0/96 ::1UGRS 0 0 - 8 lo0 2001:470:dead:beef::/64link#1 UC 0 0 - 4 re0 2002::/24 ::1UGRS 0 0 - 8 lo0 2002:7f00::/24 ::1UGRS 0 0 - 8 lo0 2002:e000::/20 ::1UGRS 0 0 - 8 lo0 2002:ff00::/24 ::1UGRS 0 0 - 8 lo0 fe80::/10 ::1UGRS 0 0 - 8 lo0 fe80::%re0/64 link#1 UC 1 0 - 4 re0 fe80::c1a1:b1ff:fea1:b1e1%re0 c1:a1:b1:a1:b1:e1 UHLc 1 7 - 4 re0 fe80::c1a1:c1ff:fea1:f1e1%re0 c1:a1:c1:a1:f1:e1 HL 1 0 - 4 lo0 fe80::%lo0/64 fe80::1%lo0U 0 0 - 4 lo0 fe80::1%lo0link#4 UHL0 0 - 4 lo0 fec0::/10 ::1UGRS 0 0 - 8 lo0 ff01::/16 ::1UGRS 0 0 - 8 lo0 ff01::%re0/32 link#1 UC 0 0 - 4 re0 ff01::%lo0/32 fe80::1%lo0UC 0 0 - 4 lo0 ff02::/16 ::1UGRS 0 0 - 8 lo0 ff02::%re0/32 link#1 UC 0 0 - 4 re0 ff02::%lo0/32 fe80::1%lo0UC 0 0 - 4 lo0 Isn't there supposed to be an IPv6 address like: 2001:470:dead:beef:c1a1:c1ff:fea1:f1e1 I can ping6 my default router: ping6 -I re0 fe80::c1a1:b1ff:fea1:b1e1 but I