User Tools

Site Tools


ipv6

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

ipv6 [2014/11/24 01:14] (current)
0.0.0.0 created
Line 1: Line 1:
 +====== IPv6 ======
  
 +===== SixXS =====
 +  * Handle: BRR3-SIXXS
 +
 +===== Setting up the gateway =====
 +Add the following to the network configuration:​
 +{{File|/​etc/​conf.d/​net|<​syntax lang="​gentoo-conf-d">​
 +config_br0="​2a01:​348:​1b6:​0::​1/​64"​
 +config_br1="​2a01:​348:​1b6:​1::​1/​64"​
 +
 +depend_sixxs() {
 +    need net.br0
 +}
 +iptunnel_sixxs="​mode sit remote 77.75.104.126 local 78.86.202.93 ttl 64 dev br0"
 +mtu_sixxs="​1280"​
 +config_sixxs="​2a01:​348:​6:​1d4::​2/​64"​
 +routes_sixxs="​2000::/​3 via 2a01:​348:​6:​1d4::​1"​
 +</​syntax>​}}
 +
 +Create an init script for the sixxs tunnel, start it, and have it run on boot:
 +{{Root|<​source lang="​bash">​
 +cd /etc/init.d
 +ln -s net.lo net.sixxs
 +/​etc/​init.d/​net.sixxs start
 +rc-update add net.sixxs default
 +</​source>​}}
 +
 +==== Firewall ====
 +Iptables only works on IPv4, so we will also need an IPv6 firewall, which is handled by <​tt>​ip6tables</​tt>​ (installed with the {{Package|direct=yes|net-firewall/​iptables}} package, when the {{USEFlag|{{EnableFlag|ipv6}}}} USE flag is enabled).
 +
 +Create an empty ruleset with:
 +{{Root|<​source lang="​bash">​
 +ip6tables-save > ip6tables.sixxs
 +</​source>​}}
 +
 +Edit the file, and then run the following commands to install the rules, and ensure the firewall starts up on boot:
 +{{Root|<​source lang="​bash">​
 +iptables-restore ip6tables.sixxs
 +/​etc/​init.d/​ip6tables save
 +/​etc/​init.d/​ip6tables start
 +rc-update add ip6tables default
 +</​source>​}}
 +
 +==== Router Advertisements ====
 +Install the Router Advertisement Daemon, which announces the subnet prefix for local machines to use when using stateless autoconfiguration:​
 +  * {{Package|direct=yes|net-misc/​radvd}}
 +
 +Set up <​tt>​radvd.conf</​tt>​ with the local configuration:​
 +{{File|/​etc/​radvd.conf|<​syntax lang="​conf">​
 +interface br0 {
 +    AdvSendAdvert off;
 +};
 +
 +interface br1 {
 +    AdvSendAdvert on;
 +    AdvLinkMTU 1280;
 +    MaxRtrAdvInterval 300;
 +
 +    prefix 2a01:​348:​1b6:​1::/​64 {
 +        AdvOnLink on;
 +        AdvAutonomous on;
 +    };
 +};
 +
 +#interface eth3 {
 +  -   ​AdvSendAdvert on;
 +  -   ​AdvLinkMTU 1280;
 +  -   ​MaxRtrAdvInterval 300;
 +#
 +  -   ​prefix 2a01:​348:​1b6:​2::/​64 {
 +  -       ​AdvOnLink on;
 +  -       ​AdvAutonomous on;
 +  -   };
 +#};
 +</​syntax>​}}
 +
 +Then start the service, and ensure it is stared on every boot:
 +{{Root|<​source lang="​bash">​
 +/​etc/​init.d/​radvd start
 +rc-update add radvd default
 +</​source>​}}
ipv6.txt · Last modified: 2014/11/24 01:14 by 0.0.0.0