Networking Forums

Networking Forums > Computer Networking > Linux Networking > how to migrate the iptables from RedHat to FedoraCore4

Reply
Thread Tools Display Modes

how to migrate the iptables from RedHat to FedoraCore4

 
 
nick
Guest
Posts: n/a

 
      11-21-2005, 01:45 PM
the follow rules is work in RedHat9, but when i put it in FedoraCore4
,some errors occur, so how to solve these problems?
thanks!


################################################## #############
### Define interfaces here
INT_DEV=eth0
EXT_DEV=ppp0
INT_NET=192.168.1.0/24

### Loading firewall modules
modprobe ip_conntrack
modprobe ip_conntrack_ftp

################################################## #############
### Enable Packet Forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward

### Remove all previous rules, and delete any user defined chains
iptables -F
iptables -X
iptables -t nat -F

iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -P OUTPUT ACCEPT
iptables -A INPUT -i lo -j ACCEPT
iptables -A FORWARD -i eth0 -o eth1 -p tcp --dport 3389 -j ACCEPT
iptables -A INPUT -i eth1 -s 192.168.0.0/24 -j ACCEPT
iptables -A FORWARD -i eth0 -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD -i eth1 -o eth0 -s 192.168.1.0/24 -j ACCEPT
iptables -t nat -A POSTROUTING -o eth0 -s 192.168.1.0/24 -j MASQUERADE
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 3389 -j DNAT
--to-destination 192.168.0.2:3389
echo 1 > /proc/sys/net/ipv4/ip_forward
 
Reply With Quote
 
 
 
 
Michael Heiming
Guest
Posts: n/a

 
      11-21-2005, 05:31 PM
In comp.os.linux.networking nick <(E-Mail Removed)>:
> the follow rules is work in RedHat9, but when i put it in FedoraCore4
> ,some errors occur, so how to solve these problems?
> thanks!


> ################################################## #############
> ### Define interfaces here
> INT_DEV=eth0
> EXT_DEV=ppp0
> INT_NET=192.168.1.0/24


> ### Loading firewall modules
> modprobe ip_conntrack
> modprobe ip_conntrack_ftp


> ################################################## #############
> ### Enable Packet Forwarding
> echo 1 > /proc/sys/net/ipv4/ip_forward


> ### Remove all previous rules, and delete any user defined chains
> iptables -F
> iptables -X
> iptables -t nat -F


> iptables -P INPUT DROP
> iptables -P FORWARD DROP
> iptables -P OUTPUT ACCEPT
> iptables -A INPUT -i lo -j ACCEPT
> iptables -A FORWARD -i eth0 -o eth1 -p tcp --dport 3389 -j ACCEPT
> iptables -A INPUT -i eth1 -s 192.168.0.0/24 -j ACCEPT
> iptables -A FORWARD -i eth0 -m state --state ESTABLISHED,RELATED -j ACCEPT
> iptables -A FORWARD -i eth1 -o eth0 -s 192.168.1.0/24 -j ACCEPT
> iptables -t nat -A POSTROUTING -o eth0 -s 192.168.1.0/24 -j MASQUERADE
> iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 3389 -j DNAT
> --to-destination 192.168.0.2:3389
> echo 1 > /proc/sys/net/ipv4/ip_forward


Doesn't look that bad, perhaps module names changed, who knows.
Simply show us the exact error messages, via (cut&paste) so we
can have a look, or should we guess?

--
Michael Heiming (X-PGP-Sig > GPG-Key ID: EDD27B94)
mail: echo (E-Mail Removed) | perl -pe 'y/a-z/n-za-m/'
#bofh excuse 279: The static electricity routing is acting up...
 
Reply With Quote
 
Robert
Guest
Posts: n/a

 
      11-22-2005, 05:14 AM
On Mon, 21 Nov 2005 22:45:19 +0800, nick wrote:

> the follow rules is work in RedHat9, but when i put it in FedoraCore4
> ,some errors occur, so how to solve these problems?
> thanks!


Stop reposting and wait for an answer is how you solve it!

See my reply to your original post.


--

Regards
Robert

Smile... it increases your face value!


----== Posted via Newsfeeds.Com - Unlimited-Unrestricted-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to migrate server traffic with iptables howard.fore@gmail.com Linux Networking 1 01-31-2006 10:08 PM
Migrate away from e7 - but where to ? Rob382 Broadband 16 01-20-2006 07:23 PM
Can't get PCI Network Card to Work - Knoppix 4.0.2/Redhat 7.2/Redhat 8.0 deja@chronofish.com Linux Networking 0 11-20-2005 05:02 PM
Looking to migrate? Dan Broadband 5 01-09-2005 09:06 AM
IPTABLES on redhat question Paco Jones Linux Networking 2 04-27-2004 07:32 PM



1 2 3 4 5 6 7 8 9 10 11