Jump to content

This is the support site for Andrews & Arnold Ltd, a UK Internet provider. Information on these pages is generally for our customers but may be useful to others, enjoy!

OpenWRT routers: Difference between revisions

Content deleted Content added
Adsb (talk | contribs)
Using Luci on DSA
Tags: Mobile edit Mobile web edit
Adsb (talk | contribs)
Reorder sections
Tags: Mobile edit Mobile web edit
Line 69: Line 69:


Do not have an interface named ''wan6'', the IPv6 configuration will be handled automatically.
Do not have an interface named ''wan6'', the IPv6 configuration will be handled automatically.
The ''option ipv6 auto'' line will cause a virtual interface named ''wan_6'' to be created, and an instance of the DHCPv6 client to be run on it. This will request an IPv6 Internet address, and a single Prefix to be Delegated. You can't get the DHCPv6 client started this way to accept more options. In order to use the delegated prefix, the LAN should be configured to expect it, e.g.:
The ''option ipv6 auto'' line will cause a virtual interface named ''wan_6'' to be created, and an instance of the DHCPv6 client to be run on it. This will request an IPv6 Internet address, and a single Prefix to be Delegated. You can't get the DHCPv6 client started this way to accept more options.

= Enabling IPv6 in the local network =

OpenWrt fully supports IPv6, as well as IPv4 and dual stacks to enable the mix of both protocols.

The easiest approach is to use prefix delegation from the WAN to provide the network address. This is achieved by configuration of the ''wan'' interface to obtain the IPv6 address automatically, and to delegate IPv6 addresses downstream. This is achieved through a virtual wan_6 interface.

Then on the ''lan'' interface Advanced settings configure the IPv6 prefix filter to ''wan_6'' and set the IPv6 assignment length to 64. There is a choice of the suffix to append to the prefix - popular choices would be ''::1'' (to use that fixed value), or ''eui64'' (to use an address based on the MAC address).

There is the possibility of running a NAT64 server on OpenWrt, so the local network can use only IPv6 but hosts on it can still reach IPv4 hosts on the Internet.

For prefix delegation to the lan interface, "/etc/config/network" should look like:
config interface 'lan'
config interface 'lan'
option device 'br-lan'
option device 'br-lan'
option proto 'static'
option proto 'static'
option defaultroute '1'
option defaultroute '1'
list ipaddr '81.187.xx.yy/zz'
list ipaddr '192.168.1.1/24'
list ip6class 'wan_6'
list ip6class 'wan_6'
option ip6ifaceid 'eui64'
option ip6ifaceid 'eui64'
option ip6assign '64'
option ip6assign '64'


The ''list ip6class wan_6'' line causes the lan to use the delegated prefix from wan_6. ''option ip6ifaceid eui64'' makes the local IPv6 address on the lan use the 64 bits derived from the MAC address as the suffix (you might choose to use ''::1'' instead). ''option ip6assign 64'' defines the netmask associated with the prefix delegation.
The ''list ip6class wan_6'' line causes the lan to use the delegated prefix from wan_6. ''option ip6ifaceid ::1'' makes the local IPv6 address on the lan use ::1 as the 64 bit suffix (you might choose to use ''eui64'' instead to use the 64 bits derived from the MAC address as the suffix). ''option ip6assign 64'' defines the netmask associated with the prefix delegation.


== Multiple routed IPv6 /64 blocks ==
== Multiple routed IPv6 /64 blocks ==
Line 127: Line 139:
...
...


= Enabling IPv6 in the local network =

OpenWrt fully supports IPv6, as well as IPv4 and dual stacks to enable the mix of both protocols.

The easiest approach is to use prefix delegation from the WAN to provide the network address. This is achieved by configuration of the ''wan'' interface to obtain the IPv6 address automatically, and to delegate IPv6 addresses downstream.

Then on the ''lan'' interface configure the IPv6 prefix filter to ''wan_6'' and set the IPv6 assignment length to 64. There is a choice of the suffix to append to the prefix - popular choices would be ''::1'' (to use that fixed value), or ''eui64'' (to use an address based on the MAC address).

There is the possibility of running a NAT64 server on OpenWrt, so the local network can use only IPv6 but hosts on it can still reach IPv4 hosts on the Internet.


= Advanced configuration of the local network =
= Advanced configuration of the local network =