Re: iptables

"Eduardo" <[email protected]>
Newsgroups gmane.linux.redhat.piranha
Organization BuscaPé Inf. e Tec. Ltda,.
Message-ID <016801c2eff7$4bd36160$6f00a8c0@buscapelocal>
Hi,

Still not working. I´ve used tcpdump to track what is happening and have the
following.
obs1.)192.168.0.111 is the machine on "INTERNET"
obs2.)dump NOT done on all interface at the same time

eth0
192.168.1.23.http > 192.168.0.111.3558: S 334677169:334677169(0) ack
43548312

eth0:1
192.168.0.111.3618 > 192.168.1.23.http: S 43801942:43801942(0) win 8192

eth1
92.168.0.111.3634 > 192.168.1.23.http: S 43878039:43878039(0) win 8192

eth1:1
192.168.0.111.3646 > 192.168.1.23.http: S 43931824:43931824(0) win 8192

- x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x -
x - x - x - x - x - x

on the real server
192.168.1.23.http > 192.168.0.111.3658: S 765087170:765087170(0) ack
43976765 win 5840

- x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x - x -
x - x - x - x - x - x

It is like that MASQUERADE is not working !

Thank you,

Eduardo.

----- Original Message -----
From: "Peter J. Milanese" <[email protected]>
To: <[email protected]>
Sent: Friday, March 21, 2003 8:32 AM
Subject: Re: iptables


> Hey-
>
> Looks like you're not actually forwarding the port...
>
> try adding
>
> DNAT       tcp  --  anywhere             anywhere           tcp dpt:80
to:192.168.1.10:22
>
> which looks like:
>
> -A PREROUTING -p tcp -m tcp -i eth0 --dport 80 -j DNAT --to-destination
192.168.1.23:80
>
> in your /etc/sysconfig/iptables file
>
>
>
> Pete
>
> On Fri, 21 Mar 2003, Eduardo wrote:
>
> > Hi,
> >
> > It is like the Masquerading is not working, can somebody help me ?
> > My network is as follow (changing its IP), I can get "http" web page
> > of 192.168.1.23 requesting it from 192.168.0.222
> > but when I try to get the web page of 192.168.1.23 from INTERNET
> > I get a 500 TimeOut answer, verifying network state on
> > the real server I see the request stopped on SYN_RECV
> >
> > tcp        0      0 192.168.1.23:80         192.168.0.111:1532
SYN_RECV
> >
> >  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x -
x - x
> >
> >                           I N T E R N E T
> >
> >
> >                                     |  eth0 : 192.168.0.222       eth0:1
192.168.0.220 (virtual server IP)
> >                      |---------------------------|
> >                      |     router              |
> >                      |---------------------------|
> >                                     |  eth1 : 192.168.1.2
> >               -------------------------------------------------
gateway eth1:1 192.168.1.21
> >                                     |
> >                                     |
> >                                     |  eth0 : 192.168.1.23
> >                      |---------------------------|
> >                      |     real server 1    |
> >                      |---------------------------|
> >
> >  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x -
x - x
> > router server
> > >iptables -t nat -L
> > Chain PREROUTING (policy ACCEPT)
> > target     prot opt source               destination
> >
> > Chain POSTROUTING (policy ACCEPT)
> > target     prot opt source               destination
> > MASQUERADE  all  --  192.168.1.0/24       anywhere
> > LOG        all  --  anywhere             anywhere           LOG level
warning
> >
> > Chain OUTPUT (policy ACCEPT)
> > target     prot opt source               destination
> >
> >  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x - x - x  - x -
x - x
> >
> > Real server 1
> >
> > >netstat
> > tcp        0      0 192.168.1.23:80         192.168.0.111:1532
SYN_RECV
> >
> > >route
> > Kernel IP routing table
> > Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
> > 192.168.1.0     *               255.255.255.0   U     0      0        0
eth0
> > 127.0.0.0       *               255.0.0.0       U     0      0        0
lo
> > default         192.168.1.21    0.0.0.0         UG    0      0        0
eth0
> >
> > >ifconfig
> > eth0      Link encap:Ethernet  HWaddr xxxxxxxxx
> >           inet addr:192.168.1.23  Bcast:192.168.1.255
Mask:255.255.255.0
> >
> > Thank you,
> >
> > Eduardo.
> >
>
>
>
> _______________________________________________
> Piranha-list mailing list
> [email protected]
> https://listman.redhat.com/mailman/listinfo/piranha-list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.