Troubleshooting on OS X

Martin martinmoen at gmail.com
Sat Jan 9 05:46:02 CET 2016


Hi,

I've got it deployed across multiple macs never had to install tuntap
manually, however I don't use port, I use homebrew which might have a
different process to install tuntap on osx.
Yes, you do have to run kextload on the tuntap module.
Otherwise the process is identical to the nix machines.
On 8 Jan 2016 10:49 p.m., "Ned Twigg" <ned.twigg at diffplug.com> wrote:

> Thanks very much!  It's alive!  For others who are having problems, this
> is a summary of the differences I needed between Linux and OS X:
>
> You'll need to install http://tuntaposx.sourceforge.net/ manually.
>
> On tinc.conf:
> > Linux
> Name = ntwigg2014linux
> AddressFamily = ipv4
> Interface = dpsfVPN
> ConnectTo = dpserver001
> > Mac
> Same, but remove the Interface line entirely
>
> On tinc-up:
> > Linux
> ifconfig $INTERFACE 10.0.0.12 netmask 255.255.255.0
> > Mac
> ifconfig $INTERFACE 10.0.0.12/24 10.0.0.100  ; 10.0.0.100 is dpserver001
> above
> route add -net 10.0.0.0 10.0.0.12 255.255.255.0
>
> With the files above, I can ping dpserver001 (10.0.0.100).  My network is
> a star (all the endpoints go to dpserver001 for now).  My windows box can
> ping the linux box, but not the mac box.  The linux and mac boxes can't
> ping anyone except the server.  That works fine for my usecase, but just a
> notable limitation for anyone else who is tinkering with this stuff.
>
> Thanks again!
>
>
> Ned Twigg
> Lead Software Architect, DiffPlug LLC
> 949-264-3433
> 340 S Lemon Ave #3433, Walnut, CA 91789
>
> On Thu, Jan 7, 2016 at 2:37 PM, pjv <pjv at pjv.me> wrote:
>
>> I might be able to help with this. Here is an email that I sent to Guus
>> some time ago:
>>
>> Having moved onward from setting up a private tinc router-mode mesh on my
>> routers and linux servers, I finally got around to installing and setting
>> tinc up on my mac laptop. When I wanted to set up the mac so it could see
>> my tinc network (but NOT route everything through it, road-warrior style),
>> I couldn’t find the right config anywhere and when I tried to just copy the
>> configs I used on my linux server boxes (setting them up with something
>> like <ifconfig $INTERFACE 10.112.1.1 netmask 255.255.0.0>) so it would be a
>> single leaf node and be able to see and be seen by the rest of the mesh, I
>> was thwarted by the FreeBSD ifconfig command which forces you to create a
>> ptp link when configuring a tun device by specifying both the IP address of
>> the device AND a specific device on the other end of the ptp link (you
>> cannot specify a network).
>>
>> This is a tinc-up script that mimics the linux behavior. you may want to
>> add this to the wiki page here:
>> http://www.tinc-vpn.org/examples/osx-install/
>>
>>
>> tinc-up (for OS X yosemite):
>>
>> #!/bin/sh
>>
>> ifconfig $INTERFACE 10.112.1.2/16 10.112.1.2
>> route add -net 10.112.0.0 10.112.1.2 255.255.0.0
>>
>>
>> hope that helps.
>>
>> On Jan 7, 2016, at 3:25 PM, Ned Twigg <ned.twigg at diffplug.com> wrote:
>>
>> > kextload /Library/Extensions/tun.kext/
>>
>> I didn't have a /Library/Extensions/tun.kext/ on my machine.  I googled
>> around, and downloaded and installed from
>> http://tuntaposx.sourceforge.net/.  Not sure why the macports install
>> didn't work, but it seems I'm making progress.
>>
>> Now I get this:
>> > sudo tincd -n dpsf -D -d3
>> tincd 1.0.21 (Feb  3 2015 20:09:36) starting, debug level 3
>> /dev/tun0 is a Generic BSD tun device
>> Executing script tinc-up
>> ifconfig: interface dpsfVPN does not exist
>> Script tinc-up exited with non-zero status 1
>> Listening on 0.0.0.0 port 655
>> Ready
>> Trying to connect to dpserver001 (71.202.38.86 port 655)
>> Connected to dpserver001 (71.202.38.86 port 655)
>> Sending ID to dpserver001 (71.202.38.86 port 655)
>> ... (lots of stuff, but I can't ping through the VPN)
>>
>> So then I tried changing the interface in my conf.vpn to tun0, but then I
>> get
>>
>> > sudo tincd -n dpsf -D -d
>> tincd 1.0.21 (Feb  3 2015 20:09:36) starting, debug level 1
>> /dev/tun0 is a Generic BSD tun device
>> ifconfig: ioctl (SIOCAIFADDR): Destination address required
>> Script tinc-up exited with non-zero status 1
>> ... (lots of stuff, but ping doesn't work).
>>
>> I tried Spencer's suggestion re: the FAQ
>> http://tinc-vpn.org/faq/#index5h3
>>
>> > ifconfig tap0 10.0.0.13
>> ifconfig: interface tap0 does not exist
>> > ifconfig dpsfVPN 10.0.0.13
>> ifconfig: interface dpsfVPN does not exist
>> > ifconfig tun0 10.0.0.13
>> ifconfig: ioctl (SIOCAIFADDR): Destination address required
>>
>> Thanks for the help, I think I'm closer!  Any ideas for next steps?
>>
>> Ned Twigg
>> Lead Software Architect, DiffPlug LLC
>> 949-264-3433
>> 340 S Lemon Ave #3433, Walnut, CA 91789
>>
>> On Thu, Jan 7, 2016 at 11:16 AM, Guus Sliepen <guus at tinc-vpn.org> wrote:
>>
>>> On Thu, Jan 07, 2016 at 09:55:14AM -0800, Ned Twigg wrote:
>>>
>>> > > sudo tincd -n dpsf -D -d3
>>> > tincd 1.0.21 (Feb  3 2015 20:09:36) starting, debug level 3
>>> > Could not open /dev/tun0: No such file or directory
>>> > Terminating
>>>
>>> That sounds like the tun module is not loaded. If you didn't reboot
>>> since installing the tuntaposx modules, try running the following
>>> command:
>>>
>>> kextload /Library/Extensions/tun.kext/
>>>
>>> Then try to start tinc again.
>>>
>>> > And here's the contents of my files in /opt/local/etc/tinc:
>>> >
>>> > > dpsf/tinc.conf
>>> > Name = ntwigg2009mac
>>> > AddressFamily = ipv4
>>> > Interface = dpsfVPN
>>> > ConnectTo = dpserver001
>>> >
>>> > > dpsf/tinc-up
>>> > #!/bin/sh
>>> > ifconfig $INTERFACE 10.0.0.13 netmask 255.255.255.0
>>> >
>>> > > dpsf/tinc-down
>>> > #!/bin/sh
>>> > ifconfig $INTERFACE down
>>>
>>> All that looks OK.
>>>
>>> > > sudo launchctl load -w
>>> > /Library/LaunchDaemons/org.macports.tuntaposx.plist
>>> >
>>> /opt/local/etc/LaunchDaemons/org.macports.tuntaposx/org.macports.tuntaposx.plist:
>>> > Operation already in progress
>>>
>>> Hm, that's weird. I don't know what that error message means here.
>>>
>>
>>
>>
>>
>> _______________________________________________
>> tinc mailing list
>> tinc at tinc-vpn.org
>> http://www.tinc-vpn.org/cgi-bin/mailman/listinfo/tinc
>>
>>
>
> _______________________________________________
> tinc mailing list
> tinc at tinc-vpn.org
> http://www.tinc-vpn.org/cgi-bin/mailman/listinfo/tinc
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.tinc-vpn.org/pipermail/tinc/attachments/20160109/fecab8e7/attachment-0001.html>


More information about the tinc mailing list