View Single Post
  #1   (View Single Post)  
Old 7th January 2009
tangram's Avatar
tangram tangram is offline
Real Name: Ricardo Jesus
Port Guard
Join Date: May 2008
Location: Portugal
Posts: 36
Default HOWTO: Install and setup MLDonkey on FreeBSD

MLDonkey is an open source, free software multi-network peer-to-peer application. Currently the following protocols are supported: eDonkey, Overnet, Bittorrent, Gnutella, Gnutella2, Fasttrack, FileTP and Kademlia.

Bellow are the steps needed to install MLDonkey on FreeBSD 7.x:

1. % su
2. # cd /usr/ports/net-p2p/mldonkey
3. # make WITHOUT_GUI=yes WITHOUT_X11="YES" WITHOUT_TK="YES" install clean
4. # rehash
Now that MLDonkey is installed let's activate it at boot time:

1. # echo 'mlnet_enable="YES"' >> /etc/rc.conf
2. # echo 'mlnet_user="p2p"' >> /etc/rc.conf
Notice the mlnet_user option, for added security we'll create a p2p user:

1. # pw user add p2p
2. # mkdir /home/p2p
3. # chown p2p:p2p /home/p2p
Restart the system for the changes to apply.

Now we are going to modify the MLDonkey configuration:

1. % su
2. # /usr/local/etc/rc.d/mlnet status
3. # exit
4. % telnet 4000
5. > auth admin ""
6. > passwd newpassword
7. > set allowed_ips ""
8. > save
9. > exit
Basically, we've checked to see if MLDonkey was running and accessed it through its telnet interface. Initially the application is configured without an admin password, so step 6 takes care of that. On step 7 we set the ips that are allowed to connect to the application, in the example the localhost and all clients in the local network.

MLDonkey's web server can be accessed on http://localhost:4080, so fire-up your browser and point to the address. If your planning to access the server from another computer replace localhost bit by the server's ip or hostname.

The following are a few useful commands that can be passed on to MLDonkey:

1. # /usr/local/etc/rc.d/mlnet start
2. # /usr/local/etc/rc.d/mlnet stop
3. # /usr/local/etc/rc.d/mlnet restart
4. # /usr/local/etc/rc.d/mlnet status
There are tons of configuration options available both in the telnet and web interfaces so I've opted to mention only the basic stuff. For more information I suggest browsing the project's website at
BSD and Linux tips and tutorials: Blog Linux/BSD: sharing experiences
Reply With Quote