Hurricane Electric's IPv6 Tunnel Broker Forums

Advanced search  

News:

Welcome to Hurricane Electric's Tunnelbroker.net forums!

Pages: 1 [2] 3

Author Topic: IPv6 stateless autoconfiguration  (Read 14606 times)

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #15 on: October 13, 2011, 05:20:33 AM »

so u mean to conf each computer one by one without making one computer as a router for each clients through stateless conf?
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2736
Re: IPv6 stateless autoconfiguration
« Reply #16 on: October 13, 2011, 05:34:46 AM »

You can either statically assign the addresses or assign via RA

I don't know what you topology is, but if you have something like

internet --- router --- client

you need to put the tunnel ::2 address on the outside interface of the router (and I think you already have) then assign an address from your routed /64 to the inside interface of your router (say its 2001:db8:12:1) then assign another address out of that same subnet to the client behind the router (say 2001:db8:12::2
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #17 on: October 13, 2011, 07:09:52 AM »

yes, that my topology is.

Quote
you need to put the tunnel ::2 address on the outside interface of the router (and I think you already have)

is this what u mean?

modprobe ipv6
ip tunnel add he-ipv6 mode sit remote 216.218.221.42 local 202.47.88.67 ttl 255
ip link set he-ipv6 up
ip addr add 2001:470:35:270::2/64 dev he-ipv6
ip route add ::/0 dev he-ipv6
ip -f inet6 addr

what do u mean by inside and outside interface?
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2736
Re: IPv6 stateless autoconfiguration
« Reply #18 on: October 13, 2011, 07:25:09 AM »

the outside interface is what connects to the Internet...inside interface is the interface that connects to the rest of your network
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #19 on: October 14, 2011, 06:05:30 AM »

in this case eth0 is the outside interface and eth2 is the inside interface?

so let say i've to conf eth0:
etc/sysconfig/network-scripts/init.ipv6-global
#server interface configuration
auto eth0
iface eth0 inet6 static
        address 2001:470:36:270::1
        netmask 64

*is it how to conf server?
and for client is wlan0 or what and how to conf it?
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2736
Re: IPv6 stateless autoconfiguration
« Reply #20 on: October 14, 2011, 06:09:00 AM »

Quote
in this case eth0 is the outside interface and eth2 is the inside interface?

I don't know...it depends on how you have your site configured.  If eth0 connects you to the internet, then yes, it's your outside address.

You can configure wlan0 the same way.  If wlan0 is in the same subnet as eth2, use an address  out of the same /64 for both of them.  If wlan0  is in a different network, you'll have to request the /48 from HE and use an separate /64 from that.
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #21 on: October 17, 2011, 08:47:32 PM »

hi, i conf the server eth0 (as i showed u my ifconfig, eth0 is the out interface)

eth0      Link encap:Ethernet  HWaddr 00:26:18:EE:C6:4F 
          inet addr:202.47.88.67  Bcast:202.47.88.79  Mask:255.255.255.240
          inet6 addr: fe80::226:18ff:feee:c64f/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2638691 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26406 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:247245133 (235.7 MiB)  TX bytes:3949177 (3.7 MiB)
          Interrupt:28 Base address:0xa000

eth2      Link encap:Ethernet  HWaddr 00:40:F4:EA:7D:DD 
          inet addr:172.27.11.66  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: fe80::240:f4ff:feea:7ddd/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1954651 errors:568303 dropped:661603 overruns:568303 frame:0
          TX packets:2735 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:177805561 (169.5 MiB)  TX bytes:245523 (239.7 KiB)
          Interrupt:20 Base address:0x4c00

he-ipv6   Link encap:IPv6-in-IPv4 
          inet6 addr: fe80::ca2f:5843/128 Scope:Link
          inet6 addr: 2001:470:35:270::2/64 Scope:Global
          UP POINTOPOINT RUNNING NOARP  MTU:1480  Metric:1
          RX packets:774 errors:0 dropped:0 overruns:0 frame:0
          TX packets:904 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:426982 (416.9 KiB)  TX bytes:123000 (120.1 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:413 errors:0 dropped:0 overruns:0 frame:0
          TX packets:413 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:47135 (46.0 KiB)  TX bytes:47135 (46.0 KiB)

[root@ip6 etc]# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:26:18:EE:C6:4F 
          inet addr:202.47.88.67  Bcast:202.47.88.79  Mask:255.255.255.240
          inet6 addr: fe80::226:18ff:feee:c64f/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2641751 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26430 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:247514388 (236.0 MiB)  TX bytes:3953637 (3.7 MiB)
          Interrupt:28 Base address:0xa000

eth2      Link encap:Ethernet  HWaddr 00:40:F4:EA:7D:DD 
          inet addr:172.27.11.66  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: fe80::240:f4ff:feea:7ddd/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1957685 errors:568303 dropped:661603 overruns:568303 frame:0
          TX packets:2749 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:178072540 (169.8 MiB)  TX bytes:246697 (240.9 KiB)
          Interrupt:20 Base address:0x4c00

he-ipv6   Link encap:IPv6-in-IPv4 
          inet6 addr: fe80::ca2f:5843/128 Scope:Link
          inet6 addr: 2001:470:35:270::2/64 Scope:Global
          UP POINTOPOINT RUNNING NOARP  MTU:1480  Metric:1
          RX packets:774 errors:0 dropped:0 overruns:0 frame:0
          TX packets:904 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:426982 (416.9 KiB)  TX bytes:123000 (120.1 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:413 errors:0 dropped:0 overruns:0 frame:0
          TX packets:413 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:47135 (46.0 KiB)  TX bytes:47135 (46.0 KiB)

eth0 conf:
auto eth0
iface eth0 inet6 static
        address 2001:470:36:270::1
        netmask 64

and in the client ifconfig
eth0      Link encap:Ethernet  HWaddr 00:e0:4c:87:0f:8e 
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:29

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:286 errors:0 dropped:0 overruns:0 frame:0
          TX packets:286 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:33648 (33.6 KB)  TX bytes:33648 (33.6 KB)

wlan0     Link encap:Ethernet  HWaddr 48:5d:60:53:2f:6b 
          inet addr:172.27.11.238  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: fe80::4a5d:60ff:fe53:2f6b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:297578 errors:0 dropped:0 overruns:0 frame:0
          TX packets:135554 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:356938043 (356.9 MB)  TX bytes:12017672 (12.0 MB)

so i conf wlan0:
auto wlan0
iface wlan0 inet6 static
        address 2001:470:ec64::2
        netmask 48

and conf radvdump for the server:
interface eth0 {
        AdvSendAdvert on;
        MinRtrAdvInterval 3;
        prefix 2001:470:36:270::/64 {
                AdvOnLink on;
                AdvAutonomous on;
                AdvRouterAddr on;
        };
};

and try a program to call radvdump

[root@ip6 ~]# radvdump

^C

still give the same error... :-(
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #22 on: October 17, 2011, 10:16:43 PM »

now, the client get ip add from server, but i dont what exactly it is

ipv6@ipv6-laptop:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 00:e0:4c:87:0f:8e 
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:29

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:319 errors:0 dropped:0 overruns:0 frame:0
          TX packets:319 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:36224 (36.2 KB)  TX bytes:36224 (36.2 KB)

wlan0     Link encap:Ethernet  HWaddr 48:5d:60:53:2f:6b 
          inet addr:172.27.11.238  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: 2001:470:36:270:4a5d:60ff:fe53:2f6b/64 Scope:Global
          inet6 addr: fe80::4a5d:60ff:fe53:2f6b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:734174 errors:0 dropped:0 overruns:0 frame:0
          TX packets:264811 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:688070763 (688.0 MB)  TX bytes:24831803 (24.8 MB)
Logged

k1mu

  • Newbie
  • *
  • Posts: 36
Re: IPv6 stateless autoconfiguration
« Reply #23 on: October 18, 2011, 04:17:38 AM »

now, the client get ip add from server, but i dont what exactly it is
For this interface?
Quote
wlan0     Link encap:Ethernet  HWaddr 48:5d:60:53:2f:6b 
          inet6 addr: 2001:470:36:270:4a5d:60ff:fe53:2f6b/64 Scope:Global

It's getting 200:470:36:270::/64 as the prefix from your radvd.conf
Quote

interface eth0 {
        AdvSendAdvert on;
        MinRtrAdvInterval 3;
        prefix 2001:470:36:270::/64 {
                AdvOnLink on;
                AdvAutonomous on;
                AdvRouterAddr on;
        };
};

If your routable /64 isn't 2001:470:36:270, then you'll need to fix your radvd.conf and restart radvd.

If you're wondering where the rest of the stateless address comes from, it's the MAC address of the interface converted to EUI-64.
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #24 on: October 18, 2011, 05:35:07 AM »

Quote
If your routable /64 isn't 2001:470:36:270, then you'll need to fix your radvd.conf and restart radvd.

what did u mean, doesn't it need to put the prefix that i got from HE 2001:470:36:270/64??
Logged

k1mu

  • Newbie
  • *
  • Posts: 36
Re: IPv6 stateless autoconfiguration
« Reply #25 on: October 19, 2011, 11:24:50 AM »

what did u mean, doesn't it need to put the prefix that i got from HE 2001:470:36:270/64??

There are TWO networks involved. One is the tunnel between you and Hurricane Electric.
Your configuration details seem to imply that the tunnel uses 2001:470:36:270::/64, which is what you're telling RADVD to advertise to your LAN. Since that's not your network, that's not going to work. That network is only used with the connection between your endpoint and the servers at HE.

In addition to the tunnel /64, HE provides you with a routed /64 or a routed /48. That is the network that RA should be advertising to your LAN. Basically, HE sets up routing for IPv6 to send any traffic to that network prefix towards your server, which then routes the traffic onto your internal LAN.
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #26 on: October 21, 2011, 02:52:02 AM »

this is my tunnel details:

Code: [Select]
Server IPv4 Address:216.218.221.42
Server IPv6 Address:2001:470:35:270::1/64
Client IPv4 Address:202.47.88.67
Client IPv6 Address:2001:470:35:270::2/6

Routed IPv6 Prefixes
Routed /64:2001:470:36:270::/64
Routed /48:2001:470:ec64::/48

The network which is only used with the connection between your endpoint and the servers at HE.
The conf are:
Code: [Select]
modprobe ipv6
ip tunnel add he-ipv6 mode sit remote 216.218.221.42 local 202.47.88.67 ttl 255
ip link set he-ipv6 up
ip addr add 2001:470:35:270::2/64 dev he-ipv6
ip route add ::/0 dev he-ipv6
ip -f inet6 addr

so,now i wanna make it as router that can connect multiple clients through wireless because as discussed here before that is also able to connect thru wireless (not only LAN) by using radvd.conf
radvd.conf:
Code: [Select]

interface eth0 {
        AdvSendAdvert on;
        MinRtrAdvInterval 3;
        prefix 2001:470:36:270::/64 {
                AdvOnLink on;
                AdvAutonomous on;
                AdvRouterAddr on;
        };
};


and the router and client are in different network, so as suggested by mr.cholzhauer i shud use prefix /48 for client interface:
Code: [Select]
auto wlan0
iface wlan0 inet6 static
        address 2001:470:ec64::2
        netmask 4

for the router:
Code: [Select]
auto eth0
iface eth0 inet6 static
        address 2001:470:36:270::1
        netmask 64

#radvdump

^C
*error

and the client still cant connect to ipv6 site
client ifconfig:
Code: [Select]
ipv6@ipv6-laptop:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 00:e0:4c:87:0f:8e
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:29

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:319 errors:0 dropped:0 overruns:0 frame:0
          TX packets:319 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:36224 (36.2 KB)  TX bytes:36224 (36.2 KB)

wlan0     Link encap:Ethernet  HWaddr 48:5d:60:53:2f:6b
          inet addr:172.27.11.238  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: [b]2001:470:36:270[/b]:4a5d:60ff:fe53:2f6b/64 Scope:Global
          inet6 addr: fe80::4a5d:60ff:fe53:2f6b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:734174 errors:0 dropped:0 overruns:0 frame:0
          TX packets:264811 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:688070763 (688.0 MB)  TX bytes:24831803 (24.8 MB)
router ifconfig:
Code: [Select]
eth0      Link encap:Ethernet  HWaddr 00:26:18:EE:C6:4F
          inet addr:202.47.88.67  Bcast:202.47.88.79  Mask:255.255.255.240
          inet6 addr: fe80::226:18ff:feee:c64f/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2638691 errors:0 dropped:0 overruns:0 frame:0
          TX packets:26406 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:247245133 (235.7 MiB)  TX bytes:3949177 (3.7 MiB)
          Interrupt:28 Base address:0xa000

eth2      Link encap:Ethernet  HWaddr 00:40:F4:EA:7D:DD
          inet addr:172.27.11.66  Bcast:172.27.11.255  Mask:255.255.255.0
          inet6 addr: fe80::240:f4ff:feea:7ddd/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1954651 errors:568303 dropped:661603 overruns:568303 frame:0
          TX packets:2735 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:177805561 (169.5 MiB)  TX bytes:245523 (239.7 KiB)
          Interrupt:20 Base address:0x4c00

he-ipv6   Link encap:IPv6-in-IPv4
          inet6 addr: fe80::ca2f:5843/128 Scope:Link
          inet6 addr: [b]2001:470:35:270::2/64 [/b]Scope:Global
          UP POINTOPOINT RUNNING NOARP  MTU:1480  Metric:1
          RX packets:774 errors:0 dropped:0 overruns:0 frame:0
          TX packets:904 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:426982 (416.9 KiB)  TX bytes:123000 (120.1 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:413 errors:0 dropped:0 overruns:0 frame:0
          TX packets:413 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:47135 (46.0 KiB)  TX bytes:47135 (46.0 KiB)
i applied all ways those are discussed on this topic, shud revies from the prev discussion

regards
 :)
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2736
Re: IPv6 stateless autoconfiguration
« Reply #27 on: October 21, 2011, 03:59:20 AM »

It looks like your hosts are getting an address...that's good.

First, I wouldn't bother using the 2001:470:36:270::/64 for anything...you have 64k worth of /64's in your /48, so I don't think you're going to run out

Second, you need to have a route for that /48 on your router. 
Logged

smith21

  • readonly_member
  • Newbie
  • *
  • Posts: 19
Re: IPv6 stateless autoconfiguration
« Reply #28 on: October 21, 2011, 04:12:47 AM »

so i also need to assign /48 besides /64 in the router? is it something look like this code?

Code: [Select]
auto eth0
iface eth0 inet6 static
        address 2001:470:36:270::1
        netmask 64
        address 2001:470:ec64::1
        netmask 48
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2736
Re: IPv6 stateless autoconfiguration
« Reply #29 on: October 21, 2011, 04:26:23 AM »

No...the only place your /48 goes is in your routing table.  Look at "netstat -nr" to see the current one
Logged
Pages: 1 [2] 3