How to open bittorrent ports from the command line

Sponsored Link
By default, ubuntu is totally locked and will not allow any incoming connections. To fix this use the following command

sudo iptables -A INPUT -p tcp --dport 6881 -j ACCEPT

this is the port that the built in ubuntu bittorrent client uses.If you are using different port you need to enter instead of 6881.

If you want to lockdown your machine use the following command

sudo iptables -A INPUT -p tcp --dport 6881 -j DROP

You may also like...

7 Responses

  1. Arup says:

    Hi,

    By default, all ports in ubuntu are open unless firewall has been activated, in my case, all my inbound ports for Ktorrent, aMule etc. work fine, I don’t have firewall activated and use a router.

  2. allen says:

    i had try the command above but the error msg come out

    Bad argument `–dport’
    Try `iptables -h’ or ‘iptables –help’ for more information.

  3. Curtis says:

    Kind of a funny coincidence but while I was looking over these commands I noticed that all errors result from [OPTIONS] which require a double-hyphen. When viewed on here they render as a dash or a long single line while the need to be two separate hyphens.

    Make sure you check for this when copying commands to avoid errors. Took me awhile to figure it out 🙂

  4. James says:

    Hullo,
    I did what the instructions said and it only limited my down/up speed. But as soon as I dropped the port my down/up increased.

  5. Jordan says:

    I followed the instructions above, typed in my password, and can’t tell if anything happened. Transmission still says “Tracker is unable to connect to (IP address) to check BT port. Please try to unblock it or forward. How do I do this? Thanks

  6. Anon says:

    Jordan, make sure your router has the port open too.

  7. katsuya says:

    it says Sudo is not recognized as an internal or external command

Leave a Reply

Your email address will not be published. Required fields are marked *