Hurricane Electric's IPv6 Tunnel Broker Forums

Advanced search  

News:

Welcome to Hurricane Electric's Tunnelbroker.net forums!

Author Topic: Getting things working on OS X  (Read 4723 times)

fitzmorrispr

  • Newbie
  • *
  • Posts: 5
Getting things working on OS X
« on: November 17, 2010, 12:54:42 PM »

Hi there.

I'm at a bit of a loss. I used these instructions: http://pugio.net/2009/01/enable-ipv6-on-mac-os-x-the-tu.html
on both my old G3 PowerBook running 10.4.11 and on my eMac running 10.5.8

Both seemed to work, (ifconfig revealed a configured gif0 interface) except that ping6 would complain of being unable to resolve the host.

I guessed that maybe my router wasn't passing protocol 41 (although, i'd enabled ICMP, and the tunnel creation page thought all was well) and put my laptop in DMZ.
No change.

Then, I noticed that the inet6 my laptop had under en1 was not the same as the one i'd configured for gif0, and tried changing it via the GUI. ping6 ceased complaining that it couldn't resolve, but had 100% packet loss (trying both pugio.net and ipv6.google.com)

Same thing happened on the eMac

eMac's ifconfig output, prior to manually configuring the IPv6 address: (note, after configuring it, en0 had no inet6 entry at all)
Code: [Select]
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
        inet 127.0.0.1 netmask 0xff000000
        inet6 ::1 prefixlen 128
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
        inet6 fe80::20a:95ff:fe8a:f836%gif0 prefixlen 64 scopeid 0x2
        inet6 2001:470:c:b79::bad:cafe prefixlen 64
        inet6 2001:470:c:b79::2 --> 2001:470:c:b79::1 prefixlen 128
stf0: flags=0<> mtu 1280
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        inet 192.168.1.69 netmask 0xffffff00 broadcast 192.168.1.255
        inet6 fe80::20a:95ff:fe8a:f836%en0 prefixlen 64 scopeid 0x4
        ether 00:0a:95:8a:f8:36
        media: autoselect (100baseTX <full-duplex>) status: active
        supported media: none autoselect 10baseT/UTP <half-duplex> 10baseT/UTP
<full-duplex> 10baseT/UTP <full-duplex,flow-control> 10baseT/UTP <full-duplex,hw-loopback> 100baseTX
<half-duplex> 100baseTX <full-duplex> 100baseTX <full-duplex,flow-control> 100baseTX <full-duplex,hw-loopback>
fw0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 2030
        lladdr 00:0a:95:ff:fe:8a:f8:36
        media: autoselect <full-duplex> status: inactive
        supported media: autoselect <full-duplex>
en1: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        ether 00:0d:93:82:f9:f6
        media: autoselect (<unknown type>) status: inactive
        supported media: autoselect

I'm not sure how to proceed, at this point. Anyone got some ideas?
« Last Edit: November 17, 2010, 12:58:42 PM by fitzmorrispr »
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2709
Re: Getting things working on OS X
« Reply #1 on: November 17, 2010, 01:00:36 PM »

Did you create your tunnel using your NAT address?
Logged

fitzmorrispr

  • Newbie
  • *
  • Posts: 5
Re: Getting things working on OS X
« Reply #2 on: November 17, 2010, 07:14:35 PM »

oh, i knew I was forgetting to mention something.

I set up the tunnel with the endpoint being my router's public IP, and I fed my LAN IP to the script which sets up gif0. (actually, the script gets that from the system automatically, so...)
It's odd. I just now noticed that the eMac's ifconfig doesn't print the line 'tunnel $LOCAL_IP --> $SERVER_IPv4' under gif0
The powerbook does, though.

Both have the same problem, though they are running different versions of the OS.
Do you think that's the problem?
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2709
Re: Getting things working on OS X
« Reply #3 on: November 17, 2010, 07:16:18 PM »

I guess I'm confused.

Where do you want to host your tunnel?  If it's on your router, fine, use the public IP.  If it's on your mac, then you need to use the private IP
Logged

fitzmorrispr

  • Newbie
  • *
  • Posts: 5
Re: Getting things working on OS X
« Reply #4 on: November 17, 2010, 07:18:43 PM »

wait, use my mac's local IP on the tunnel creation page? i thought you had to use a publicly viewable IP address on that page.
Logged

cholzhauer

  • Hero Member
  • *****
  • Posts: 2709
Re: Getting things working on OS X
« Reply #5 on: November 17, 2010, 07:42:03 PM »

No.  You need to use your public IP address on the tunnel page.

However, when you create the tunnel on the mac, you need to use your NAT'd IP address instead of the public IP address.
Logged

fitzmorrispr

  • Newbie
  • *
  • Posts: 5
Re: Getting things working on OS X
« Reply #6 on: November 17, 2010, 07:48:33 PM »

Oh, OK. I did that. Or rather, the script I used, from http://pugio.net/2009/01/enable-ipv6-on-mac-os-x-the-tu.html did that automatically ( did i mention that earlier? )

These lines:
MYIF="en1" (i changed it to en0, per the script's internal documentation)
LOCAL_IP=`ifconfig $MYIF |grep -E 'inet.[0-9]' | grep -v '127.0.0.1' | awk '{ print $2}'`
ifconfig gif0 tunnel $LOCAL_IP $HETUNEND

When i DMZ'd the laptop, i changed it so that LOCAL_IP=$NEW_IP (again, per the script's internal documentation).
$NEW_IP contains the output of http://ifconfig.me/ip
(that's another modification. It's the same output as the URL used in the original gives, though)
« Last Edit: November 17, 2010, 07:52:59 PM by fitzmorrispr »
Logged

jdh

  • Newbie
  • *
  • Posts: 8
Re: Getting things working on OS X
« Reply #7 on: December 02, 2010, 12:26:08 PM »

You should use your private internal address regardless of the DMZ setting on your router. The gif0 tunnel needs to be bound to an address that is actually on your Mac, regardless of whether it's dynamically or statically (DMZ) mapped to your public IP address.

Logged

fitzmorrispr

  • Newbie
  • *
  • Posts: 5
Re: Getting things working on OS X
« Reply #8 on: December 03, 2010, 09:44:00 AM »

My router uses some trickery, so that when DMZ'd, the computer is assigned the router's public address. this gives it the idea that there is no router, just a DSL modem.
(IOW, when DMZ'd, the computer's private address IS the router's public address)
Logged

jdh

  • Newbie
  • *
  • Posts: 8
Re: Getting things working on OS X
« Reply #9 on: December 04, 2010, 09:21:16 PM »

Well, if the computer is actually being assigned the real external address, then there shouldn't be any need to modify the script to set LOCAL_IP=$NEW_IP as the script should pick it up from the ifconfig command anyway...   
Logged