[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: iptabels and DNAT problem



Please dump your routing table and the /proc/sys/net/ipv4/ip_forward file.
Could be a routing problem?
Are these the only rulesets in your table?



Alessandro Caputo









> [please CC me as I'm not (yet) on the list, thank you]
>
> Hello,
>
> I'm having problems with iptables in a particular setup.
>
> I have defined following interfaces:
>
> eth0      Link encap:Ethernet  HWaddr 00:40:F4:74:52:7F
>           inet addr:157.x.x.100  Bcast:157.x.x.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:35403126 errors:50773 dropped:3204 overruns:43088
> frame:0
>           TX packets:11556310 errors:0 dropped:0 overruns:2 carrier:0
>           collisions:0 txqueuelen:100
>           RX bytes:1389250309 (1.2 GiB)  TX bytes:3291432340 (3.0 GiB)
>           Interrupt:10 Base address:0xa000
>
> eth0:1    Link encap:Ethernet  HWaddr 00:40:F4:74:52:7F
>           inet addr:157.x.x.9  Bcast:157.x.x.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           Interrupt:10 Base address:0xa000
>
> eth0:2    Link encap:Ethernet  HWaddr 00:40:F4:74:52:7F
>           inet addr:157.x.x.24  Bcast:157.x.x.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           Interrupt:10 Base address:0xa000
>
> eth1      Link encap:Ethernet  HWaddr 00:50:BA:C6:5D:14
>           inet addr:10.0.0.254  Bcast:10.0.0.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
>           RX packets:11618570 errors:0 dropped:16714 overruns:0 frame:0
>           TX packets:33498523 errors:0 dropped:0 overruns:0 carrier:0
>           collisions:0 txqueuelen:100
>           RX bytes:3306224212 (3.0 GiB)  TX bytes:1148042990 (1.0 GiB)
>           Interrupt:9 Base address:0x6100
>
> eth1 goes to a switch that has the 10.0.0.0/24 subnet behind it.
>
> The default policy of all tables is accept (for now)
> I want to forward all trafic on port 80 on eth0:1 to 10.0.0.75:80
> I want to forward all trafic on port 25 on eth0:2 to 10.0.0.76:25
> I want to forward all trafic on port 22 on eth0:2 to 10.0.0.76:22
>
> Also I want to



Reply to: