Why can't I connect to an AFP server over VPN on OS X 10.8

6,974

I am not sure, for once, if this is a proper answer. I will make up for whatever is missing as we move on.

You have no VPN configured whatsoever. You routing table is correct for a pc connected to a local LAN, nothing else.

It is possible that the error is rooted in the fact that you seem to have (please correct me if I am wrong) the very same subnet at home and at work: 192.168.1.0/24. I deduce this from your current routing table, and from this statement of yours:

But when I go to Go > Connect to Server and try to connect using the local address (that works when I am at the office:

 afp://192.168.1.104

.....

If this is the case, no matter what other errors you may have in the configuration of the VPN, it will not work. In fact, there might be pcs with the same IP addresses, and in any case, when confronted with an address like, for instance, 192.168.1.104 your kernel, your local router, your remote router, will be unable to understand whether you are referring to an IP address this side of the tun0, or on the opposite side.

If I am right on this (same subnet for home and work), then we will be unable to make progress until this is sorted out.

Share:
6,974

Related videos on Youtube

Finglish
Author by

Finglish

Updated on September 18, 2022

Comments

  • Finglish
    Finglish over 1 year

    I have set up a VPN connection on my MacBook Pro OS X 10.8.5 laptop, to my office network so I can access my AFP file server from home.

    The VPN connection appears to be working correctly. The Status reads Connected and I am getting both a connect time and an IP address.

    So far so good.

    But when I go to Go > Connect to Server and try to connect using the local address (that works when I am at the office):

    afp://192.168.1.104

    I get the classic error

    "The server may not exist or it is unavailable at this time"

    I tried pinging the server from the command line and get a "No route to host"

    As my IP address is not changing when the VPN is connected it is clear that not all my traffic is going through the VPN, so I thought I would try setting it up to route everything.

    According to this post I should be able to re-direct all the traffic using this by setting the "Send all traffic over VPN connection" option under the Advanced menu in my VPN network settings.

    I should be seeing something like:

    enter image description here

    But when I click "Advanced", what I see is this:

    enter image description here

    Any ideas where I am going wrong?

    ifconfig output:

    lo0: flags=8049 mtu 16384
        options=3
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1 
        inet 127.0.0.1 netmask 0xff000000 
        inet6 ::1 prefixlen 128 
    gif0: flags=8010 mtu 1280
    stf0: flags=0 mtu 1280
    en0: flags=8863 mtu 1500
        ether 14:10:9f:d1:ba:93 
        inet6 fe80::1610:9fff:fed1:ba93%en0 prefixlen 64 scopeid 0x4 
        inet 192.168.1.65 netmask 0xffffff00 broadcast 192.168.1.255
        media: autoselect
        status: active
    p2p0: flags=8843 mtu 2304
        ether 06:10:9f:d1:ba:93 
        media: autoselect
        status: inactive
    utun0: flags=8051 mtu 1280
        inet 172.18.10.3 --> 172.18.10.3 netmask 0xffffffff 
    

    Routing table

    Internet:
    Destination        Gateway            Flags        Refs      Use   Netif Expire
    default            192.168.1.1        UGSc           40        0     en0 
    default            utun0              UCSI            1        0   utun0
    127                127.0.0.1          UCS             0        0     lo0
    127.0.0.1          127.0.0.1          UH              3   112823     lo0
    169.254            link#4             UCS             0        0     en0
    172.18.10.3        172.18.10.3        UH              0       12   utun0
    192.168.1          link#4             UCS             6        0     en0
    192.168.1.1        8:76:ff:42:9a:17   UHLWIir        42     4836     en0    735
    192.168.1.1        utun0              UHW3Ii          0       11   utun0      3
    192.168.1.5        link#4             UHLWIi          1      198     en0
    192.168.1.65       127.0.0.1          UHS             0        0     lo0  
    192.168.1.110      link#4             UHRLWIi         0       49     en0     14
    192.168.1.248      link#4             UHLWIi          0        2     en0 
    192.168.1.253      a:76:ff:42:9a:17   UHLWIi          0      546     en0   1192
    192.168.1.255      ff:ff:ff:ff:ff:ff  UHLWbI          0       12     en0
    212.182.213.186    192.168.1.1        UGHS            0        0     en0
    
    Internet6:
    Destination                             Gateway                         Flags                Netif Expire
    ::1                                     link#1                          UHL             lo0
    fe80::%lo0/64                           fe80::1%lo0                     UcI             lo0
    fe80::1%lo0                             link#1                          UHLI            lo0
    fe80::%en0/64                           link#4                          UCI             en0
    fe80::1610:9fff:fed1:ba93%en0           14:10:9f:d1:ba:93               UHLI            lo0
    ff01::%lo0/32                           fe80::1%lo0                     UmCI            lo0
    ff01::%en0/32                           link#4                          UmCI            en0
    ff02::%lo0/32                           fe80::1%lo0                     UmCI            lo0
    ff02::%en0/32                           link#4                          UmCI            en0
    
    • Finglish
      Finglish over 10 years
      @MariusMatutiae the ifconfig output if very long, is there a specific part I should post?
    • MariusMatutiae
      MariusMatutiae over 10 years
      your routing table, pls?
    • Finglish
      Finglish over 10 years
      @MariusMatutiae sorry i ment netstat -n, I have added the ifconfig output to the bottom of the question
    • MariusMatutiae
      MariusMatutiae over 10 years
      netstat -nr is really necessary, sorry
    • Finglish
      Finglish over 10 years
      @MariusMatutiae OK, got it. I have added the routing table
  • Finglish
    Finglish over 10 years
    Sorry, my VPN had turned itself off before I printed the table and I didn't notice (long day). I have updated it. The subnet issue sounds on the money. I guess I will have to change it on my home network.