Restore VPN settings after hardware change
If you change the hardware of your Mac computer using Mac OS X but keep the harddrive / the system installation, you have to make some changes in order to restore VPN configuration under network settings. This site explains how to chieve this:

  I figured out a way to do this, so thought I would post for anyone following me that has a bunch of VPN settings and doesn't want to manually key them back in. You will basically have to copy & paste a few GUIDs to make your old prefs data match your new system. This worked for me going from one Mac OS X 10.6 SL system to another SL system. I would imagine similar steps would work for Mac OS X 10.5 Leopard and possibly 10.7 Lion. Here we go:

    First, go to Network Preferences on your new machine and add VPN (L2TP), VPN (PPTP), or whatever VPN "interfaces" you need. Do not create any new VPN configurations at this time. Close Network Prefs.

    Open System Profiler, select and copy to the clipboard the Hardware UUID from the Hardware tab.

    Navigate to ~/Library/Preferences/ByHost and find your old NetworkConnections prefs file. It will have the form of Make a copy of this file. Replace the portion w/ the one you copied in step #2. Don't forget to remove any spaces and the " copy" tag. You should now have a new file called

    Open 2 files in an editor that can handle .plist files (I used TextWrangler): the file you just made, and /Library/Preferences/SystemConfiguration/preferences.plist.

    In preferences.plist, look for the GUID of each VPN interface that you've created. The "UserDefinedName" string at the end of the key will tip you off:

  <key>14A4B264-C231-41FE-857B-EE5557B69851</key> <dict> <key>DNS</key> <dict/> <key>IPv4</key> <dict> <key>ConfigMethod</key> <string>PPP</string> </dict> ... <key>UserDefinedName</key> <string>VPN (L2TP)</string> </dict>

  The first long string ("14A4B264...") is the part you need. Copy this to the clipboard.

    Now move over to your file. Find the key that has all of your old VPN settings for that VPN type contained w/in it. Select all of the key name (which is the GUID of your VPN interface on your old Mac), then paste to replace it w/ the new GUID.

    Repeat steps 5 & 6 for each VPN interface you need. In my case, there were 2: L2TP and PPTP.

    Save your changes and close the file. Close the preferences.plist file WITHOUT saving anything.

    Open your Network Preferences, select your VPN interface(s), and you should see your past configurations.

admin / Dec 06, 2012
2004 - 2019 /