- The first step is to download the OpenVPN configuration files to any folder on your machine.
- Extract the zip and choose a server configuration file based on the location of the server you would
like to connect to (one of the *.conf files, eg.
- Copy the selected .conf file and the following files from the downloaded zip to any of the shared
folders on your diskstation. Eg:
Now we need to enable SSH access in DSM. Open DSM, navigate to Control Panel -> Terminal & SNMP.
Check the box Enable SSH service and click Apply. You can disable SSH access once the steps are complete. Alternatively you can enable the Telnet service and use a telnet client to connect to the NAS instead of SSH.
- Now we setup a placeholder OpenVPN connection. In DSM, go to Control Panel -> Network -> Network Interface tab.
Select Create -> Create VPN Profile.
- Select OpenVPN radio button and click Next.
Complete the form with the following information
Only your account ID is used for the authentication. The password field can be empty or set to anything, like "ivpn", if your client requires a non-blank password.
- The Profile name can be anything and is displayed in the DSM Network Interfaces panel.
- Server address is the address of the server which is in the .conf file you have previously
- Enter your IVPN account ID that begins with letters 'ivpn' and any password in the Username & Password fields respectively.
- Port is the port of the connection which is in the .conf file you have previously decided to
- Protocol is also dependent on the configuration you have chosen to use, TCP versions have their own config files (either UDP or TCP). If you're not sure what to select see what are TCP connections.
- Certificate - Select the certificate file
ca.crtfrom where you downloaded the configuration files to earlier.
- Select Next.
Select all check boxes on the next form and select Apply.
You'll now have a VPN connection in the Network Interfaces section. Attempting to connect will fail though. The DSM configuration file will need to be updated and some extra files copied to the NAS drive.
Now we need to SSH into DSM. Open an SSH client and connect to DSM (your address may not be 'diskstation' as in the screenshot) using the root account. Password will be the same as the 'admin' account password for DSM (you can change this password by logging into DSM using any account that is in the administrator group and going to Control panel -> Users).
- Go to directory
Check directory contents as below.
- If you only have one OpenVPN configured there will one file called
client_oxxxxxxxxxx. This is the configuration file for the VPN profile you created in DSM earlier.
Copy this file to a shared folder somewhere on the diskstation eg.
Now we need to edit the OpenVPN configuration files. In a text editor open the file you just copied
(client_oxxxxxxxxxx)it will look similar to below with differences depending on your VPN profile setup.
- Open your selected *.conf file in a text editor from the downloaded files you extracted earlier.
Copy the highlighted lines from this file as below.
Paste the copied lines at the bottom of the
client_oxxxxxxxxfile you opened earlier and save the file.
Go back to the SSH session and navigate to the shared folder you copied files to earlier (eg:
Copy the following files from the DSM shared folder that you copied files to earlier (eg:
/volume1/Files/Temp/) to the vpn configuration folder in DSM -
NOTE: When copying use 'cp –f' to force overwrite of existing files in the destination.
Navigate to the OpenVPN configuration directory and make sure the files you just copied exist.
Open up DSM again and go back to Control Panel -> Network -> Network Interfaces tab. Click connect on the VPN profile you created earlier. It should successfully connect.Please note that if you make any changes to VPN profile using the DSM GUI the changes you made to the configuration file will be overwritten and it will have to be edited again.Was this answer helpful?