FreeNAS 8.0 has been released a while ago, but it’s still lacking many features that nowadays are fundamental to any NAS (most of which will be fixed in 8.1). In particular it lacks any form of torrent manager, so I decided to install MLDonkey on my box and write a small HowTo about it.
Requirements:
- A computer running FreeNAS 8.0
- SSH access to said computer and root privileges
- A volume with a few megabytes free to download the packages
- A working internet connection
How does this work?
When installing FreeNAS 8.0 on a USB drive (at least when using dd to write the disk image), the UFS image used to mount the root partition has about 22 MiB free. Since MLDonkey (without GUI, made exception for the integrated web-server) and its dependencies require roughly 11 MiBs, there is more than enough space to install it.
Howto:
- Login in your FreeNAS box as root (the password is the same that you set for the admin user)
- Change directory to the one that will contain the downloaded files
cd /path/to/directory/
- Download this script (code shown below) by running
fetch http://nexus.thenexus.it/install_mldonkey_freenas8.sh
Please note that the script has been written by a lazy-bum (myself) and there is no error checking! Any improvements to the script are welcome.
- Execute the script you just downloaded by running
sh install_mldonkey_freenas8.sh
- MLDonkey is now installed, you can launch it by typing
mlnet
, further information and guides vailable at
Note:
At the time of writing the available packages were the following:
- net-p2p/mldonkey-core-3.0.6
- graphics/jpeg-8_3
- graphics/gd-2.0.35_7,1
You might need to change the file names appearing in the howto according to new releases.
The script’s code
#!/bin/bash ARCH=`uname -m` MACHINE=`uname -r | cut -d- -f1-2 | awk '{print tolower($0)}'` SERVER=ftp://ftp.freebsd.org ROOTDIR=/pub/FreeBSD/ports fetch ${SERVER}${ROOTDIR}/${ARCH}/packages-${MACHINE}/graphics/jpeg-8_3.tbz fetch ${SERVER}${ROOTDIR}/${ARCH}/packages-${MACHINE}/graphics/gd-2.0.35_7,1.tbz fetch ${SERVER}${ROOTDIR}/${ARCH}/packages-${MACHINE}/net-p2p/mldonkey-core-3.0.6.tbz mount -o rw -t ufs /dev/ufs/FreeNASs1a / pkg_add jpeg-8_3.tbz gd-2.0.35_7,1.tbz mldonkey-core-3.0.6.tbz mount -o ro -t ufs /dev/ufs/FreeNASs1a /
Hi! I installed it on FreeNAS 8.0.2 and when trying to start mlnet it says Command not found. I can’t even find a folder of mldonkey in the filesystem… ?
That’s strange. If the install went in the right way you should be able to launch mlnet.
Please check that the packages are still they same and haven’t been updated since I wrote this post: if even one of the files is missing the install will not proceed correctly.
The script downloads correctly the three files, of that I’m sure… I’m trying other releases of Freenas, now the 8.0 i386, let’s see what happens…
P.S: I forget to say I’m using virtualbox to try it.
Nothing to do even with 8.0 i386. I have a question: I used two (virtual) disks in mirror zfs formatted for the storage of the FreeNAS; did you do the installation using USF as filesystem? Can this be the problem? Thanks!
I used a ZFS volume, but that’s not the point. MlDonkey would be installed on the available free space on the install media (in my case it is a USB drive), not on data partitions.
Did you try to look for the mldonkey executable by using find?
Just to let you know, my mlnet executable is in /usr/local/bin/mlnet
for FreeNAS 8.0.4p1
you need additional packages:
graphics/png-1.4.5.tbz
textproc/expat-2.0.1_1.tbz
print/freetype2-2.4.4.tbz
x11-fonts/fontconfig-2.8.0,1.tbz
converters/libiconv-1.13.1_1.tbz
devel/pkg-config-0.25_1.tbz