PPPoE + IPv6

OpenWrt is an open Linux based operating system for embedded devices (wireless routers, etc)

PPPoE + IPv6

Postby Void Main » Sat Jan 22, 2011 3:22 pm

The site has been up and down the last couple of days because I have been trying to get my new DSL modem working the way I want. I got a new DSL modem (Actiontec GT701D) because my old modem (Motorola 2210-02) was pings from the Internet and Hurricane Electric wouldn't issue me an IPv6 tunnel without being able to ping my public IPv4 address. Anyway, the Motorola had an option on the connection page to share public IP address on the LAN. What that allowed me to do is save my PPPoE login ID and password in the modem and it would handle that authentication and then pass the public IP that was attained to the LAN interface via DHCP. That is, I could plug the WAN port of my WRT54G to my modem and get the public address via DHCP so there was no need to mess with PPPoE at the WRT.

Well, the new Actiontec modem doesn't appear to be able to do that but it does have a transparent bridge mode that means I have to now do the PPPoE on the WRT54G itself to get the public address on the WAN port. I finally got that working on my WRT54G running OpenWrt 8.09.2. I still have one issue to resolve. The public address used to get assigned to my eth0.1 and now it gets assigned to my ppp0 interface. I changed my Shorewall configuration to use ppp0 rather than the eth0.1 interface but shorewall is not starting on boot. It used to start automatically on a call to "ifup wan" by way of a script called /etc/hotplug.d/iface/15-shorewall:

CURRENT_IP=/var/run/shorewall.ip
COMMAND=/sbin/shorewall

Code: Select all
[ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && {
        [ -x $COMMAND ] && [ -s $CURRENT_IP ] && {
                                include /lib/network
                                scan_interfaces

                                . /var/state/network

                                config_get newip wan ipaddr
                                [ "$newip" != `cat $CURRENT_IP` ] && {
                                        $COMMAND status | grep -q 'Shorewall is running'
                                } && {
                                        $COMMAND restart
                                }
        } &
}


So, now I just have to figure out how to get that script hooked into the process that brings up the ppp0 interface. I think my /etc/config/network may not be correct either:

config 'switch' 'eth0'
option 'vlan0' '2 3 4 5*'
option 'vlan1' '0 2t 5'
option 'vlan2' '1 2t 5'

config 'interface' 'loopback'
option 'ifname' 'lo'
option 'proto' 'static'
option 'ipaddr' '127.0.0.1'
option 'netmask' '255.0.0.0'

config 'interface' 'lan'
option 'type' 'bridge'
option 'ifname' 'eth0.0'
option 'proto' 'static'
option 'netmask' '255.255.255.0'
option 'ipaddr' '192.168.1.1'
option 'ip6addr' '2001:db8:0:f101::1/64'
option 'defaultroute' '0'
option 'peerdns' '0'

config 'interface' 'wan'
option 'ifname' 'eth0.1'
option 'proto' 'pppoe'
option 'username' 'myusername@att.net'
option 'password' 'mypassword'
option 'defaultroute' '1'
option 'mtu' '1492'
option 'peerdns' '1'
User avatar
Void Main
Site Admin
Site Admin
 
Posts: 5705
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA

Re: PPPoE + IPv6

Postby Void Main » Sat Jan 22, 2011 3:41 pm

Found the answer here:

http://inhalt.serviert.de/wissen/openwr ... figuration

I created a /etc/ppp/ip-up.d/10-shorewall script:

Code: Select all
#!/bin/sh

if [ ! -f /tmp/myshorewall.lock ]; then

touch /tmp/myshorewall.lock

/sbin/shorewall restart

rm -f /tmp/myshorewall.lock

fi


It seems to work correctly on startup. Hopefully it reruns when the IP address changes.
User avatar
Void Main
Site Admin
Site Admin
 
Posts: 5705
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA

Re: PPPoE + IPv6

Postby Void Main » Fri Jan 28, 2011 2:27 pm

I tacked on to the above script to bring my Hurricane Electric 6in4 tunnel up:

index.php
User avatar
Void Main
Site Admin
Site Admin
 
Posts: 5705
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA


Return to OpenWrt

Who is online

Users browsing this forum: No registered users and 1 guest

cron