Skip to content

Advanced guide to OpenVPN on SB Touch/Radio

This guide describes the procedure to install OpenVPN on your Squeezebox Touch or Squeezebox Radio. You can use this to connect your Squeezebox player to your remote home network using OpenVPN. This guide assumes you have a functioning OpenVPN setup on your network. Also this guide assumes basic knowledge of *nix administration (especially for the usage of vi).

Squeezebox Touch

We need the openvpn binary and the tun kernel module for the SB Touch and your ovpn.config as text.

Download the latest from Ralphy's repository and copy it into the SB Touch:

scp -O /path/to/ [email protected]:/dev

Then we ssh into the SB Touch and enter the following commands:

ssh [email protected]
cd /dev
mv /dev/openvpn /usr/sbin
chmod 755 /usr/sbin/openvpn
mv /dev/tun.ko /lib/modules/
mkdir -p /etc/openvpn

Next we create the file with vi and there you enter the text of your ovpn.config. Make sure you insert auth-user-pass /etc/openvpn/up into the config:

vi /etc/openvpn/TUN.ovpn

Next create the file up and enter your vpn username in first line and password in second line:

vi /etc/openvpn/up

Next is the rcS.local file which runs the stuff at boot:

vi /etc/init.d/rcS.local

We paste these two commands into that file:

# Load the tunnel kernel module.
insmod /lib/modules/
# Start openvpn
/usr/sbin/openvpn --config /etc/openvpn/TUN.ovpn --daemon

Then chmod that file:

chmod 755 /etc/init.d/rcS.local

Then we put a script which gets NTP time when network is up. We need this to get the right time to connect to vpn.

vi /etc/network/if-up.d/settime

Put the following contents into that file:

# /etc/network/if-up.d/settime
# Sets the hardware clock from an NTP server on reboot
# Replace this with the address of your local time server
# or with a public NTP server like or
# Log file with system time before and after synchronisation
if [ "$METHOD" != "loopback" ]; then
date >> $LOG_FILE
echo "Synchronizing time with $NTP_SERVER via $IFACE" >> $LOG_FILE
msntp -r -P no $NTP_SERVER && hwclock -w -u
date >> $LOG_FILE

Then we chmod that file:

chmod +x /etc/network/if-up.d/settime

That’s it, we are done, hope it is running fine. We can now reboot:


Squeezebox Radio

For the Radio it is the same, only 2 differences:

scp -O /path/to/ [email protected]:/dev
mv /dev/tun.ko /lib/modules/

The rcS.local should have this line instead:

insmod /lib/modules/