Set up Torguard VPN for Transmission on Freenas 11.1 – Updated for 2020!
Nowadays, it is prudent to protect your privacy when downloading torrents on the net. A few lawsuits have recently been brought against ISP's by businesses seeking damages from users allegedly downloading illegal content. Many of these lawsuits have centered on trying to get the ISP's to release lists of customer IP addresses along with their associated activity logs. In this post you will learn how to install a VPN in the Transmission jail and when correctly set up, all your Transmission traffic will subsequently go through the VPN. Using the Radarr Transmission and Medusa plugins, my NAS system is better than it has ever been and I was also able to import my ZFS raid disks from my old N4F server with no problems. By following this post carefully you will easily be able to get OpenVPN installed and working though the FreeNAS Transmission jail to ensure only protected traffic is tunneled through our BT client.
In my experience, this process is WAY easier that the setup required for N4F and I have setup 3 systems now with no problems using this method! Just so we're clear, this post is NOT meant to be a tutorial on how to set up FreeNas. There are many ways to configure the FN server that depend largely on your system architecture - so head on over to the FN forums if you have basic operational questions. This how-to is adapted from a post in the FN forums by Tango and I have modified it to work with Torguard though it might work with other VPN providers as well (your mileage may vary). This tutorial assumes you have your Freenas server setup and working correctly and that you have installed and tested the Transmission plugin to your satisfaction. I am currently using Torguard and I can highly recommend them. They offer many locations worldwide, are reasonably priced and have excellent customer service when you need it.
If you can't see the button below please disable your ADBLOCKER for my site. I promise will never give you ads or track you in any way, but unfortunately the ad blockers see the link below as an ad and erase it from the displayed HTML. Thank you for your cooperation!
[button color="accent-color" hover_text_color_override="#fff" url="
https://torguard.net/aff.php?aff=215/" text="Click Here to Try Torguard"
Here are the steps I followed to get VPN working on my FreeNas 11.1 server:
1 - You will need a VPN provider in order to get this going. Click here to try Torguard.
2 - SSH into freenas. (I use PuTTy)
3 - Get a list of jails:
4 - jexec into the jail (mine happens to be 3 - yours may vary)
5 - Install bash. May be prompted several times - reply Y then press enter each time.
6 - Install nano. Again, may be prompted several times. Reply Y each time.
7 - Move to the /etc folder.
8 - Fetch Portsnap via portsnap fetch: **This will take a while to download and ask for several prompts - you know the drill.
9 - Extract Ports to /usr/ports **This will also take a long time and A LOT of scrolling will happen. It's normal.
10 - Navigate to /usr/ports/security/openvpn
11 - Make a clean install which allows us to set the option of a password file.
**Blue screen should appear. Press the DOWN arrow and the SPACE bar to ensure the [ ] next to PW_Save ( 5th option down) has an X in it.
Should look this:
x+[X] PW_Save Interactive passwords may be read from a file (On latest versions of openvpn (Mar. 2016) you MAY NOT get an option #5 as described above, but openvpn appears to read passwords from a textfile anyways so you can safely skip this step.)**then press enter. Lots of things should happen now...
12 - Go to root directory of the transmission_1 jail:
13 - Enter Bash
14 - Make a directory for OpenVPN & our files that we will download from Torguard:
15 - Add lines to the rc.conf so OpenVPN starts when the jail starts:
16 - Move to a new folder (helps me keep things straight):
17 - Grab the Torguard files, you'll likely need to grab them manually and install them through the FreeNas GUI as Torguard does not allow wget
file transfers. If you have created your Transmission jail storage correctly (see link at beginning of article) you should be able to drag
the Torguard files into your shared NAS 'downloads' directory and see them symlinked in your jail's '/media' directory.You will need a login
CLICK HERE to check out Torguard. Here is the link once you are logged in: https://torguard.net/downloads.php. You will want to grab the
'Standard Port 443/TCP Configs" in the "OpenVPN Config Files and Scripts" section (near the bottom).
18 - Unzip the Torguard openvpn files into the 'Media' folder:
18 - Make a pass.txt file to hold your username and password.
19 - Configure the .ovpn file of your selected server. (I used a Canadian-based.ovpn' as it is still legal to torrent in Canada at this time. Torguard asks that you NOT use US-based servers for torrenting)
20 - Move the fixed Torguard files** into the correct folder we just created**The actual OpenVPN files we created in Step 20 above.
21 - Start your OpenVPN server:
22 - Check your install. You should be able to query the VPN tunnel:
23 - Congratulations! Your Transmission packets are now using Torguard!
24 - One caveat worth mentioning here: You probably won't be able to automagically update the Transmission client from the GUI as I have never been able to get it to successfully update itself. Whether that is the fault of our modifications or just a bug in Freenas I am not sure. To update, just make a note of your Transmission jail's storage structure and delete the plugin and re-install according to the guide again. It's a bit of a PITA - but for now, it is the only way.
Not Working? Check out these useful commands and troubleshooting tips.
Useful Open VPN Commands:
Still not working as you expect? Check out the log files in Freenas before you post a comment.[snippet slug=vpn-22 lang=bash]Still not working? Check this post for clues (it's a good troubleshooting primer as well). Just telling me it's not working does not provide enough information to troubleshoot your problem. You wouldn't take your car into the garage and say, "my car doesn't work!" - you need to give me some clues to help you fix your problem. Check your steps carefully, every command has to be issued as it is shown in the how to. If you find any mistakes please let me know and I will fix them right away.