Port forwarding in Linux
David Hoffman
dhoffman2004 at gmail.com
Sun Feb 13 04:13:36 UTC 2005
On Sat, 12 Feb 2005 18:45:54 -0800, Jared Buck <JBuck814366460 at aol.com> wrote:
> I need a little assistance here.
>
> One of my friends tells me the reason Bittorrent is downloading so
> slowly is because a certain group of ports isn't open. I do not know
> how to open ports in Linux. I can tell you my computer is connected to
> the Internet through a DSL router since everyone in my family uses DSL.
>
> Could someone tell me how to open up the required ports? I looked
> through the archives and there's no record of a question of this type
> being asked.
>
Try google too.
Here are my rules:
intip=172.1.2.3 (the IP address of your ethernet port coming in from outside)
destip=192.168.x.x (the IP address of the machine on your internal network)
iptables -t nat -A PREROUTING -d $intip -p tcp --dport 6881:6999 -i
eth1 -j DNAT --to-destination $destip
iptables -t nat -A PREROUTING -d $intip -p udp --dport 6881:6999 -i
eth1 -j DNAT --to-destination $destip
iptables -t nat -A PREROUTING -d $intip -p tcp --dport 6346 -i eth1 -j
DNAT --to-destination $destip
iptables -t nat -A PREROUTING -d $intip -p udp --dport 6346 -i eth1 -j
DNAT --to-destination $destip
More information about the fedora-list
mailing list