tunnelblick icon Tunnelblick free software for OpenVPN on macOS We need translators for several languages…

Highlighted Articles
  News
  Installing Tunnelblick
  Uninstalling Tunnelblick
  Setting up Configurations
  Using Tunnelblick
  Getting VPN Service
  Common Problems
  Configuring OpenVPN
  Release Notes
  Thanks
  FAQ

Discussion Group
  Read Before You Post

Installing and Deleting VPN Configurations

Installing Configurations

There are several ways to install VPN configurations:

  1. Drag an OpenVPN configuration file or a Tunnelblick VPN Configuration and drop it on the Tunnelblick icon in the menu bar.
  2. Execute a command to simulate the drag-and-drop described above.
  3. Install a Tunnelblick VPN Configuration at the same time Tunnelblick is installed.
  4. Install a Tunnelblick VPN Configuration from the command line.

The first three methods require confirmation by the user and authorization from a computer administrator. The last method does not require any user interaction.

Drag and Drop

This is the usual way to install a VPN configuration. The user drags and drops one or more OpenVPN configuration files (".ovpn" files) or Tunnelblick VPN Configurations (".tblk" packages) onto the Tunnelblick icon in the menu bar.

  • If there is not existing VPN configurations with the same name, the user will be asked if the configurations are to be shared or private.
  • macOS asks for a computer administrator's authorization to install the configurations.

Simulate Drag and Drop

The drag and drop described above can be simulated with the following command:

     open   -a   /Applications/Tunnelblick.app   PATH...

where PATH... is the path or paths to the .ovpn files or .tblk configurations.

Install when Tunnelblick is Installed

Tunnelblick VPN Configurations can be installed at the same time Tunnelblick is installed, without requiring additional user interaction. See Automatically Install Configurations and Forced Preferences.

Install from the Command Line

Tunnelblick VPN Configurations can be installed without user interaction with a command executed as root.

This method cannot be used to install an OpenVPN configuration file, but you can create a Tunnelblick VPN Configuration from an OpenVPN configuration file; see Creating and Installing a Tunnelblick VPN Configuration.

To install Tunnelblick VPN Configurations, execute the following command as root:

/Applications/Tunnelblick.net/Contents/Resources/installer 0 PATH1 PATH2

where PATH1 is the path to a place to install the configuration:

  • For a "private" configuration, ~/Library/Application Support/Tunnelblick/Configurations/NAME
  • For a "shared" configuration, /Library/Application Support/Tunnelblick/Shared/NAME

and NAME is the name you want the configuration to have, with ".tblk" added to the end of the name.

and PATH2 is the path to the Tunnelblick VPN Configuration.

For example, after creating a Tunnelblick VPN Configuration at ~/Desktop/Office.tblk, you can install it as a shared configuration with

     /Applications/Tunnelblick.net/Contents/Resources/installer   0    /Library/Application\ Support/Tunnelblick/Shared/Office.tblk    ~/Desktop/Office.tblk

Deleting Configurations

There are two ways to delete VPN configurations:

  1. Interactively from Tunnelblick's "VPN Details" window.
  2. From the command line.

Deleting Configurations Interactively

To delete configurations interactively:

  1. Select the configuration or configurations in the list on the left side of the "Configurations" panel of Tunnelblick's "VPN Details" window.
  2. Click the little minus-sign button ("-") at the bottom of the list .

macOS will ask for a computer administrator's authorization to delete the configuration(s).

Deleting configurations from the Command Line

To delete a configuration from the command line without any user interaction, run the following command as root:

/Applications/Tunnelblick.net/Contents/Resources/installer 8192 PATH

where PATH is the path to the configuration. That path should either:

  • For a "private" configuration, ~/Library/Application Support/Tunnelblick/Configurations/NAME
  • For a "shared" configuration, /Library/Application Support/Tunnelblick/Shared/NAME

and NAME is the name of the configuration, with ".tblk" added to the end of the name.

For example, to delete a private configuration named "Office", execute the following command as root:

     /Applications/Tunnelblick.net/Contents/Resources/installer   8192    ~/Library/Application\ Support/Tunnelblick/Configurations/Office.tblk

Subfolders

When configurations are in subfolders, include the subfolders in the path to the configuration.

For example, if a configuration to be deleted is a private configuration named "Office" which is in the "MegaCorp" subfolder of the "Clients" subfolder, use

     /Applications/Tunnelblick.net/Contents/Resources/installer   8192    ~/Library/Application\ Support/Tunnelblick/Configurations/Clients/MegaCorp/Office.tblk