OSX VPN Problems: Kill the racoon

Occasionally my Mac will refuse to connect to work’s IPSec VPN with the error message:
“A configuration error occured. Verify your settings and try reconnecting”

This usually happens to me after a long time between reboots, and a reboot usually allows me to successfully connect again. Rebooting when I’m in the middle of something can be a pain, so I did some research and found a better way. There’s a process called “racoon” – it performs key exchange operations to set up IPSec tunnels. Kill it (using kill or activity monitor) and your VPN will start working again.

Works on OSX 10.6.5 and 10.6.6

22 thoughts on “OSX VPN Problems: Kill the racoon”

  1. Bingo — this works like a charm — been having the same issue off and on.

    Here’s how I did it and things immediately started working:

    $ sudo killall racoon

    Thanks!

  2. You (and Google) just saved me from throwing my MacBook Pro over my balcony into the Atlantic. Thanks!

  3. A million thanks! I thought I had to drive into the office this weekend–but your tip did the trick! I was having problems on 10.6.7.

  4. Just wanted to weigh in on this annoying problem and agree that the solution above worked on my machine. Simplest command on OS 10.6 for me was “sudo kill PROCID”. You’ll of course need to enter the PROCID of the racoon process on your box.

  5. This solved several VPN hangs for me as well.

    But this is a truly inelegant solution. “If VPN hangs, kill the racoon” does not sound like an element of a professional system. Is there a real fix that causes racoon to not cause a hang?

    Don’t get me wrong, I found this post very helpful. But it seems there is another shoe to drop somewhere.

    Racoon is often referred to as part of an add-on package, but as far as I know, it was on my system out of the box (OSX 10.6.6, recently upgraded to 10.6.8).

  6. Many thanks. I two was about to restart my Mac for the 100th time while right in the middle of something. There is something about remote desktop for windows or this ldap directory reader client im playing with that seem to hang up the connection. In worst case it brings my whole mac to a grinding hault. Power button only exits.

    Still killing the racoon did the trick. im about to relay this info to everyone else in the company, lol.

  7. Killing racoon helped, but I then needed to restart racoon:
    sudo /usr/sbin/racoon

    Unfortunately, racoon would die when I disconnected from the VPN, so I have to use launchctl to run racoon:
    sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.racoon.plist

  8. sudo launchctl stop com.apple.racoon
    sudo launchctl start com.apple.racoon

    This should “restart” racoon

  9. In my case, my system is OS X 10.6.8, and i can’t find any racoon process running. However, the file /System/Library/LaunchDaemons/com.apple.racoon.plist does exist.

    Removing it away doesn’t solve the problem.

Leave a Reply

Your email address will not be published.