Ray: Experimental

My Visitor

Like this site!

Wanna help other found this site? +1 us now!

Google +1 Button Privacy Policy

Synology Tags

My WebHost

I recommend hostgator, here is why.

Install OpenVPN Client on Nexus S

Steps below is how I setup OpenVPN client on my Nexus S to connect to the OpenVPN server on my Synology NAS DS207+.

Root the phone first. Go to market and download busybox . Install busybox to /system/xbin. Go to market and download ES File Explorer. Using ES file explorer and mount root / [...]

Synology DS207+ modding series 34 – FreeRadius Accounting for OpenVPN with MySQL and daloRadius

Prerequisite

  1. Modding series 7 – Setup OpenVPN Server
  2. Modding series 21 – Install FreeRadius Server
  3. Modding series 22 – Install FreeRadius plugin for OpenVPN

I’m using daloRadius as accounting and reporting tools here. The management function is not used (except NAS client part).

Install daloRadius

Download daloRadius 0.9.9 package

# cd /volume1/web
# wget http://downloads.sourceforge.net/project/daloradius/daloradius/daloradius0.9-9/daloradius-0.9-9.tar.gz
# tar xvzf daloradius-0.9-9.tar.gz
# rm daloradius-0.9-9.tar.gz
# chown -R nobody:nobody /volume1/web/daloradius-0.9-9
# chown 644 /volume1/web/daloradius-0.9-9/library/daloradius.conf.php

Edit /volume1/web/daloradius-0.9-9/library/daloradius.conf.php, update the values as below


$configValues['CONFIG_DB_USER'] = 'radius';
$configValues['CONFIG_DB_PASS'] = 'radpass';
$configValues['CONFIG_DB_NAME'] = 'radiusdb';
$configValues['CONFIG_FILE_RADIUS_PROXY'] = '/opt/etc/raddb/proxy.conf';
$configValues['CONFIG_PATH_DALO_VARIABLE_DATA'] = '/opt/var/daloradius';
$configValues['CONFIG_LOG_FILE'] = '/opt/var/log/daloradius.log';

Follow up


# mkdir /opt/var/daloradius
# chown nobody:nobody /opt/var/daloradius
# touch /opt/var/log/daloradius.log
# chown nobody:nobody /opt/var/log/daloradius.log

Create and import the database


# /usr/syno/mysql/bin/mysql -u root -p

> CREATE DATABASE radiusdb;
> GRANT ALL ON radiusdb.* TO radius@localhost IDENTIFIED BY "radpass";
> GRANT ALL ON radiusdb.* TO radius@127.0.0.1 IDENTIFIED BY "radpass";
> exit;

# cd /volume1/web/daloradius-0.9-9/contrib/db
# /usr/syno/mysql/bin/mysql -u radius -p radiusdb < fr2-mysql-daloradius-and-freeradius.sql
# password: radpass

Install PHP extension

Install php-pear and php-pear-db

# ipkg install php-pear
# pear config-set php_bin /usr/bin/php
# cd /opt/share/pear
# wget http://download.pear.php.net/package/DB-1.7.14.tgz
# mv DB-1.7.14.tgz DB.tgz
# tar xvzf DB.tgz
# chown -R nobody:nobody /opt/share/pear

Edit php configuration

# vi /usr/syno/etc/php.ini

include_path = .:/php/includes:/opt/share/pear:/opt/share/pear/DB

# vi /usr/syno/etc/php/user-setting.ini

append /opt/share/pear:/opt/share/pear/DB to open_basedir

Install php-gd

# ipkg install php-gd

Synology DS207+ usage series 22 - Putting it all together - OpenVPN+FreeRadius+OpenLDAP

Pre-requisites

Install OpenVPN on DiskStation Install OpenLDAP on DiskStation Install FreeRadius and integrates with OpenLDAP

In order to let FreeRadius acting as authentication server for OpenVPN, we need a radius plugin. I’ve tried the RadiusPlugin and it is working well so far.

* I’m currently using version 2.0. The 2.1 beta plugin did not [...]

Synology DS207+ usage series 10 - Truncate and backup Openvpn log file

My OpenVPN server crashed everyday :’(. I have no idea why it crashed, I tried to read the log but I figured out that the log grown to 2GB whenever it crahsed XX( The log files is just too hugh to inspect.

I guess the root cause is the file size of the log file crashed the server. Luckily I have enabled incoming SSH access to fix this remotely.

So I just wrote couple lines in a shell script and made a scheduled job to truncate and backup the log file to prevent further issue.

Update Aug 4 2009

Yes it is indeed the root cause crashing the OpenVPN server. The script here works and prevent the VPN server crash again.

Continue reading Synology usage series 10 – Truncate and backup Openvpn log file

Synology DS207+ usage series 7 - Setup OpenVPN server (Routed mode) on DS207+ with dual authentication and Windows/DS101j/TomatoVPN OpenVPN Client

Synology already released openvpn package for their NAS. If you are using model 209 or other more recent model than you can download and install official package and skip this lengthy article.

This article describes all the steps to install OpenVPN in my environment so that I can access the resources (samba, ds207+ admin console, audio station..) on my DS207+ from any remote location in a secure way.

* I’ve tested and proved that OpenVPN even working on my DS101j for both server and client setup.

* Also working for DS107+ reported by user from synology forum


Tested platform:

DS207+ firmware version DSM 2.1-0844 , 2.2-0959, 3.1-1613
ipkg source http://ipkg.nslu2-linux.org/feeds/optware/syno-x07/cross/unstable/

DS101j firmware version DSM 2.0-0731
ipkg source http://ipkg.nslu2-linux.org/feeds/optware/ds101/cross/stable

Continue reading Synology usage series 7 – Setup OpenVPN server (Routed mode) with dual authentication and Windows/DS/TomatoVPN OpenVPN Client