This guide was produced using Diskstation Manager (DSM) v5.1 (5021 update 2)

DSM's GUI for connecting to OpenVPN doesn't allow for all of the required parameters to be set. Some manual steps are required to complete configuration of an OpenVPN connection to IVPN. It requires accessing and copying files outside of the DSM GUI by connecting to the NAS drive through SSH or telnet.

  1. The first step is to download the OpenVPN configuration files to any folder on your machine.
  2. 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. IVPN-Singlehop-Germany.conf).
  3. Copy the selected .conf file and the following files from the downloaded zip to any of the shared folders on your diskstation. Eg: \volume1\Files\Temp\
    • ca.crt
    • client1.crt
    • client1.key
    • ta.key
  4. Now we need to enable SSH access in DSM. Open DSM, navigate to Control Panel -> Terminal & SNMP.

    Step 1
  5. 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.

    Step 2
  6. Now we setup a placeholder OpenVPN connection. In DSM, go to Control Panel -> Network -> Network Interface tab.
  7. Select Create -> Create VPN Profile.

    Step 3
  8. Select OpenVPN radio button and click Next.
  9. Complete the form with the following information

    • 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 chosen. e.g.
    • Enter your IVPN account ID that begins with letters 'ivpn' and any password in the Username & Password fields respectively.
    • 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.
    • Port is the port of the connection which is in the .conf file you have previously decided to use. e.g. 2049.
    • 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.crt from where you downloaded the configuration files to earlier.
    • Select Next.
    Step 4
  10. Select all check boxes on the next form and select Apply.

    Step 5

    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.

    Step 6
  11. 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).

    Step 7
  12. Go to directory /usr/syno/etc/synovpnclient/openvpn.
  13. Check directory contents as below.

    Step 8
  14. 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.
  15. Copy this file to a shared folder somewhere on the diskstation eg. /volume1/Files/Temp

    Step 9
  16. 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.

    Step 10
  17. Open your selected *.conf file in a text editor from the downloaded files you extracted earlier.
  18. Copy the highlighted lines from this file as below.

    Step 11
  19. Paste the copied lines at the bottom of the client_oxxxxxxxx file you opened earlier and save the file.

    Step 12
  20. Go back to the SSH session and navigate to the shared folder you copied files to earlier (eg: /volume1/Files/Temp/)

    Step 13
  21. 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 - /usr/syno/etc/synovpnclient/openvpn

    • client1.crt
    • client1.key
    • ta.key
    • client_oxxxxxxxxx
    NOTE: When copying use 'cp –f' to force overwrite of existing files in the destination. Step 14
  22. Navigate to the OpenVPN configuration directory and make sure the files you just copied exist.

    Step 15
  23. 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.

    Step 16
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?

Can you please tell us how we can improve this article?