DNS-325, like its elder brother DNS-323, is a very versatile NAS that can be extended heavily by installing fun_plug script.
The main advantage of DNS-325 over DNS-323 or even DNS-320, is its horse power (1.2 GHz processor) and its embedded RAM (256 Mb). We are in front of a real home server !
Fun_plug script opens the gate to some very interesting extension possibilities.
It will focus on few other important aspects :
- detection of the DNS-325 NAS device in your LAN from a Linux workstation (without the Windows utility)
- installation of third-party software repositories (Fonz, Uli, Optware)
- installation of basic packages that will be used by many others (python, ...)
Once your have gone thru all these steps, you can focus on some much more rewarding procedures for your DNS-325 :
- install a LAMP server
- Install a Transmission client
- Install an OpenVPN server
- Send mails thru Gmail account from shell scripts
This article has been tested on a DNS-325 with firmware 1.02.
fun_plug 0.5 is kind of deprecated.
You are advised to follow the latest one DNS 325 - Fun_plug 0.7 : Extend your NAS possibilities.
1. Linux - Detect DNS-325 IP address
The first time you connect your DNS-325 NAS device on your LAN, it will get an DHCP IP address. So you can't guess what will be its address.
If you are running a Ubuntu (or any other flavor of Linux) workstation, you can not use the D-Link provided CD, as it is meant exclusively for Windows clients.
So, you will need some other detection mecanism to find your NAS IP address on your LAN.
To do the job you will need to install the umit utility, which is a GUI of nmap.
# sudo apt-get install umit
You can now start the program with root power :
# sudo umit
You will then need to configure the detection according to your LAN netmask :
- target : your LAN netmask (192.168.0.*, 10.0.1.*, ...)
- Profile : Quick Operating System Detection
To start the detection process, select Scan. It will take some time.
The detection report on the right side will list all the devices found on the network.
DNS-325 will be detected as follow :
Nmap scan report for xxx.xxx.xxx.73
Host is up (0.0014s latency).
Not shown: 998 closed ports
PORT STATE SERVICE
80/tcp open http
443/tcp open https
MAC Address: aa:aa:aa:aa:aa:aa (Unknown)
No exact OS matches for host (If you know what OS is running on it, see http://nmap.org/submit/ ).
Uptime guess: 0.011 days (since Wed Nov 23 23:51:09 2011)
Network Distance: 1 hop
TCP Sequence Prediction: Difficulty=209 (Good luck!)
IP ID Sequence Generation: All zeros
You now know that your DNS-325 device is accessible thru xxx.xxx.xxx.73.
You can connect with your web browser to check. Please note that the admin password is empty by default.
2. Install Fun_plug script
You just have to be sure to follow the specific parts for DNS-325 (the article was first written for DNS-323).
Be specially careful about the password modification procedure where you should throw these commands in your DNS-325 telnet console :
# wget http://wolf-u.li/u/172/ -O /ffp/sbin/store-passwd.sh
3. Declare additionnal packages repository
All the following command have to be executed form the DNS-325 Telnet or SSH console.
They suppose that you have fully completed the fun_plug install procedure on your DNS-325.
You can now install easily some additionnal packages from some specific repository.
3.1. Fonz repository
First repository is provided by Fonz. You can install it with these commands :
# mkdir -p /ffp/pkg/
# cd /ffp/pkg/
# /ffp/bin/rsync -av --delete inreto.de::dns323/fun-plug/0.5/packages .
Note that :
- the "." at the end of the line is very important
- the packages are together over 120 MBytes, so it can take a while.
After the last file you get some statistics and return to the command prompt.
This step results in roughly 100 packages being copied (as tarballs) to the folder /ffp/pkg/packages/.
3.2. Uli repository
Next, you can download additional packages provided by Uli repository.
# /ffp/bin/rsync -av --delete ffp.wolf-u.li::ffp/additional .
After the last file you also get some statistics and return to the command prompt.
This step results in a few packages being copied (as tarballs) to the folder /ffp/pkg/additional/ and its subdirectories.
4. Update existing packages
This procedure has to be followed from begin to end in one step.
If you don't follow all the steps, you met get an instable NAS, and worse, you can even be locked out of your NAS without telnet and SSH access.
To be on the safe side, it's better to enable Telnet … just in case.
# chmod a+x /ffp/start/telnetd.sh
Then, you can start the package upgrade procedure
# funpkg -u /ffp/pkg/packages/funpkg*.tgz
# funpkg -u /ffp/pkg/packages/*.tgz
# funpkg -u /ffp/pkg/additional/*/*.tgz
Finally, re-enable SSH daemon, in case it has been updated and it has lost the execute right
# chmod a+x /ffp/start/sshd.sh
If you check, you should see Telnet and SSH allowed to automatically start during next reboot
# ls -l /ffp/start/*.sh
-rwxr-xr-x 1 root root 971 Jul 29 16:30 sshd.sh
-rwxr-xr-x 1 root root 169 Aug 12 22:17 telnetd.sh
You can now reboot
If you can connect thru SSH without problem, you can now disable Telnet access
# chmod a-x /ffp/start/telnetd.sh
5. Install Nano editor
Install the package
# funpkg -i /ffp/pkg/additional/*/nano*.tgz
Installing package nano-2.0.9-2 ...
Executing install script for nano-2.0.9-2 ...
Copy the configuration file and edit it.
# cp /ffp/etc/examples/nanorc /ffp/etc/
# nano /ffp/etc/nanorc
By uncommenting some lines, you can enable the syntax highlight according to your needs.
In my case, I just need the shell scripts highlighting.
## Bourne shell scripts
6. Install Optware repository
Optware, originally initiated for the NSLU2, can provide some very interesting packages for the DNS-325.
To have access to the Optware repository, the only thing to do is to get a startup script provided by Uli.
# wget http://wolf-u.li/u/233 -O /ffp/start/optware.sh
# chmod a+x /ffp/start/optware.sh
# /ffp/start/optware.sh start
Once done, just reboot the NAS to make it fully operational.
7. Install Python
Python langage is available from Optware repository, along with some nice extension.
So, to install Python and the main libraries, you just need to install these Optware packages :
# ipkg install python
# ipkg install py-crypto
# ipkg install py-gd
# ipkg install py-xml
In case you are interested, some more python libraries are available from Optware. You can list them with
# ipkg list | grep py-
You are now ready to install some very interesting pieces of software on your DNS-325.
It should help in many ways ...