- If your Torrent Server has a direct connection to the internet, and is not behind a firewall or a network-address-translation (NAT) enabled router, then you most likely do not need to make any networking changes.
- It is highly recommended (if not mandatory) to configure a static IP address when behind a NAT router, or when running an Amazon EC2 instance.
TurnKey Torrent Servers peer-to-peer (P2P) engine is called mldonkey. P2P means that other P2P users need to connect to your server to upload or download files. For that purpose, Torrent Server listens on certain ports and requires that they are reachable from the internet.
For the impatient, this is what your looking for:
- BitTorrent: 6881-6889/TCP
- EDonkey: 6298/TCP, 6302/UDP
- Kademlia: 19955/UDP
- Overnet: 4696/TCP+UDP
- Torrent Server Handler: 12322/TCP
This is a general guide on how to open which ports. Since there are countless different routers, firewalls and NAT configurations, its almost impossible to include step-by-step instructions for every case. None the less, this guide should provide enough information to help you configure your setup correctly. You might want to refer to your routers/firewalls manual if you get stuck. If you are still having problems, consider posting to the forum. Lastly, if you successfully configure your connection but with different settings to those explained here, please update this guide or add a comment at the end.
OK, down to business...
These are exemplary steps on how to setup a TurnKey Torrent Server VM/ISO when behind a NAT router. If you are using the Amazon EC2 instance (recommended as it provides an extremely fast network connection), you will need to create appropriate "security group" with the ports described below.
1. Boot the VM or install the ISO
2. Once booted/installed, the configuration console will appear
Note that your IP address will differ.
3. If using the VM/EC2, you will want to change the default passwords
Change the root password
Set the mldonkey/webgmui/extplorer admin password and restart the services
/usr/local/bin/mldonkey-passwd p4ssw0rd /etc/init.d/mldonkey-server start /etc/init.d/webgmui start
4. Log into the TurnKey web control panel (http://appliance_ip) and perform a porttest
Click on "port test"
Log in to mldonkey with username admin and the password you provided during install or in step 3 above.
The below screenshot displays a failed porttest. If your porttest succeeds, then your done. If not, continue reading, thats what this guide is for.
Note that you might need to "refresh results".
5. Log into the router administration console and configure port forwarding
If you don't know the router's IP address, you can determine it as follows:
route -n | grep UG
As mentioned above, its almost impossible to include step-by-step instructions for every router configuration. The below screenshots are specific for a DLINK wireless router I have access to, but they should be generic enough to help configure other routers.
Enable the NAT module, and then continue to Port Forwarding:
Enable and configure port forwarding:
Note: Many routers have built-in firewalls, if enabled be sure to set the appropriate configuration there as well.
6. Perform a porttest
You're done. Enjoy!
7. Bonus: Torrent Server Handler Firefox extension
It is recommended to install the TorrentServer Handler Firefox extension on computers connected to your LAN. You will need to specify the Torrent Server's IP address.
You can also install the extension on other computers not connected to your LAN, such as a laptop so you can send downloads to the Torrent Server remotely. Note that you need to specify the IP address of your router when connecting remotely. This can be determined by using such services as whatismyip.com. Additionally, you might want to use Dynamic DNS (DDNS) if the IP address provided by your ISP is dynamic.