Handling port forwarding for multiple BitTorrent clients behind a NAT firewall
August 29, 2006 - 12:23pmLast night, I learned all about handling BitTorrent behind an IPCop box. We have multiple systems in our new apartment, and we wanted to be able to run BitTorrent clients on each system, but were having connectivity problems. Specifically, new connections to files we were seeding were getting dropped.
The problem
The basic problem is that while a firewall that uses NAT to turn one public facing IP into a network that multiple internal systems uses (one-to-many NAT) works fine for more or less stateless protocols such as HTTP, peer to peer protocols such as BitTorrent have problems. When an outside client wants to leech from my BitTorrent seed, how does it know to grab the torrent I'm seeding, rather than hitting my roommate's computer, which may or may not be seeding anything, much less the torrent in question?
The solution
I started knowing that BitTorrent typically uses ports 6881-6889 (actually, 6881-6999 after BT 3.2). After a little dredging of BitTorrent FAQs. I found that "the client starts with the lowest port in the range and sequentially tries higher ports until it can find one to which it can bind." This immediately suggested a simple and elegant solution.
Given computer 1, computer 2, ... computer N, the solution is to port-forward (on your firewall) one part of the BitTorrent port range to computer 1, another part to another computer 2, and so on until you have as many port range segregations as you have computers. Then, configure the BitTorrent clients on each machine to use the port ranges you've assigned to that particular system. Problem solved.
Here's a sample configuration:
| Port range | Destination | Notes |
|---|---|---|
| 6881-6885 | 192.168.168.50 (Computer 1) | Pre-v3.2 ports |
| 6886-6889 | 192.168.168.70 (Computer 2) | Pre-v3.2 ports |
| 6890-6945 | 192.168.168.50 (Computer 1) | Post-v3.2 ports |
| 6946-6999 | 192.168.168.70 (Computer 2) | Post-v3.2 ports |
Note that these port ranges are set in two places: in your firewall's port-forwarding table, and on the BitTorrent clients on each system.
This is a simple and obvious solution once you know that BitTorrent clients don't force a single port for the peer-to-peer connection but select from a pool. It is possible that everybody knows that, so the solution is a no-brainer, or most BitTorrent users only connect from a single client or use UPnP, so partitioning the ports is irrelevant. If not, save yourself some trouble and segment your BitTorrent port range.
Comments
There are no comments right now.
出会い 出会い系 メル友 恋人 不倫 人妻 セフレ ご近所 出会い探し セックスフレンド 結婚
出会い系人妻祭り
逢える出会い系
出会い系2009最新作
出会い系でも結婚できる!
出会い系で会うならメイプルストーリー
出会い系-OFFICIAL SITE-
マジで会える出会い系の秘密あなただけにこっそり教えちゃいます!
出会い系選挙
みんなの出会い系
横綱出会い系
パーフェクト出会い系
http://www.出会い系.com
これならできる!出会い系
出会い系meets
出会い系サクセス
出会い系で彼氏・彼女探し
出会い系の卵
出会い系辞典
出会い系人4世
出会い系フリークPlusα
Abe said instead of enrolling her data processing serviceson's school years were normal,data processing but in high school he failed the data processuniversity his withdrawalentrance exam. data processing serviceThat is not unusual; most who data processingfail study for another yeardata process and try again. Abe's son said he was going to in a cram school.
laser engraving, laser engraver, laser engraving machine laser cutting machine cutting plotter, vinyl cutter
laser engraver, laser cutter, laser cutting machine, laser engraving machine, cutting plotter, vinyl cutter
used laser engraver used laser machine cnc router cheap laser engraver
Post new comment