Hurricane Electric's IPv6 Tunnel Broker Forums

Advanced search  

News:

Welcome to Hurricane Electric's Tunnelbroker.net forums!

Author Topic: Some interesting tidbits while trying to get my tunnel working today...  (Read 2358 times)

sysgeek

  • Newbie
  • *
  • Posts: 12

I had been banging my head against the wall today just trying to get my tunnel up and going. I've finally been getting around to it, after I've had my account for a couple of years. The example configurations for Linux gave me a good place to start. I generated a config, but could never get it up and going to where I could ping my gateway. The box that I'm setting this up on is my Internet firewall, running CentOS 5.5. I finally determined that my tunnel didn't know which interface to go out to build the tunnel, so I modified the command and added "dev eth0" at the end of the tunnel command. After I did that, my firewall started to attempt to connect, but still couldn't, so I ended up setting up my firewall as an pptp client and tunneling my ipv6 traffic through the pptp connection and so far that has been working most very well.

I wrote a script to automate the building of the connection and the tear down. The script it:

Code: [Select]
#!/usr/bin/perl

$pptpServer        = "xxxx.dal1.ipv6.he.net";
$pptpUsername    = "xxxxxxxx";
$pptpPassword    = "xxxxxxx";

$tunRemote        = "server ip address goes here";
$tunClient          = "client ip address goes here";

$client6             = "client ipv6 address goes here";

if(!$ARGV[0]) {
        print "$0 [start | stop]\n";
} elsif($ARGV[0] eq "start") {
        `pptpsetup --create ipv6 --server $pptpServer --username $pptpUsername --password $pptpPassword --start`;
        `ip tunnel add sixbone mode sit remote $tunRemote local $tunClient ttl 255 dev ppp0`;
        `ip link set sixbone up`;
        `ip addr add $client6 dev sixbone`;
        `ip route add ::/0 dev sixbone`;
        `ip route add 2000::/3 dev sixbone`;
} elsif($ARGV[0] eq "stop") {
        `ip route del ::/0 dev sixbone`;
        `ip route del 2000::/3 dev sixbone`;
        `ip addr del $client6 dev sixbone`;
        `ip link set sixbone down`;
        `ip tunnel del sixbone`;
        `pptpsetup --delete ipv6`;
        @ps = `ps ax | grep pptp`;
        foreach $proc (@ps) {
                @pid = split(/ +/,$proc);
                `kill -9 $pid[1]`;
        };
} else {
        print "$0 [start | stop]\n";
}
[root@darkstar ~]#

The pptp client software I am using is http://pptpclient.sourceforge.net/.

Now all I need to do is get the ip6tables config working properly and get radvd to hand out addresses on my LAN.
Logged