Setting up an ad-blocking and OpenVPN server, the easy way

Moderators: mdrjr, odroid

Setting up an ad-blocking and OpenVPN server, the easy way

Unread postby WhiskerBiscuit » Sat May 12, 2018 2:33 pm

I initially got an ODROID because I wanted to setup a VPN so I could access my network from anywhere, mostly so I could access Netflix outside of the US. But in the process I also wanted to setup my own DNS server so I could use names instead of IP addresses when accessing network resources. The DNS server I chose is PiHole. It’s pretty slick. After you install it, you change your router settings to point to your ODROID. Make sure that is the only DNS server your router points to otherwise the ad-blocking might not work. Installing is pretty simple.

Code: Select all
curl -sSL https://install.pi-hole.net | bash


If you have trouble setting up or configuring PiHole, their discourse site is a great place to ask to get a quick answer.

OpenVPN is not an easy application to install. The instructions are sparse and not easy to follow. That’s where PiVPN shines. It too is easy to install:

Code: Select all
curl -L https://install.pivpn.io | bash


It has a graphical UI and asks only a few questions to setup and generate client certificates. The most difficult step in the process is getting the certificate off of the server (for that I just use a program like WinSCP). What used to take me an hour to setup can now be done in 2 minutes (not counting the 5-30 minutes it takes to generate your security keys). After you’ve installed both, this guide will show you how to configure PiHole and OpenVPN so they work and play nicely with each other. Don’t forget to modify your hosts file so you can add DNS entries on your local network. The benefit of this is that when you make an OpenVPN connection, say from a public WiFi at Starbucks, you will have a secure tunnel that you can access network resources by name. I really love this combination, as no matter where I am I can use my computers as if I were sitting at home. What a great time to be alive.
WhiskerBiscuit
 
Posts: 5
Joined: Thu Mar 15, 2018 6:45 am
languages_spoken: english
ODROIDs: O2

Re: Setting up an ad-blocking and OpenVPN server, the easy w

Unread postby mad_ady » Sat May 12, 2018 8:36 pm

Yes, what a great time to be alive indeed. One correction though - pidns is not a dns server, but it's a collection of servers and scripts that do a specific job. The DNS server used is dnsmasq.
User avatar
mad_ady
 
Posts: 4585
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1


Return to Ubuntu

Who is online

Users browsing this forum: No registered users and 1 guest