Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.networking > #1258

Re: linux as multi-port (subnet) router using Ubuntu 11.10 server

From Pascal Hambourg <boite-a-spam@plouf.fr.eu.org>
Newsgroups comp.os.linux.networking
Subject Re: linux as multi-port (subnet) router using Ubuntu 11.10 server
Date 2012-04-09 21:01 +0200
Organization Plouf !
Message-ID <jlvbm4$u16$1@saria.nerim.net> (permalink)
References (7 earlier) <26518308.9.1333903498341.JavaMail.geo-discussion-forums@pbtd9> <jlsjd0$2u7i$1@saria.nerim.net> <13689836.1943.1333930427032.JavaMail.geo-discussion-forums@pbvs10> <jlu7ip$g2l$1@saria.nerim.net> <23753461.82.1333978858232.JavaMail.geo-discussion-forums@pbvy6>

Show all headers | View raw


lincy a écrit :
> Sorry, I was wrong. I was issue some iptable rule.

It cannot possibly be an issue with some iptables rule, as iptables-save
showed no rule at all.

> dump for eth2:
> 21:00:36.457244 ARP, Request who-has 192.168.3.51 tell 192.168.51.1, length 28

Huh ? "tell 192.168.51.1" ? What is the address configured on eth2 ?

> 21:00:36.457510 ARP, Reply 192.168.3.51 is-at 70:5a:b6:40:02:d5, length 46
> 21:00:36.593887 IP 192.168.2.181 > 192.168.3.51: ICMP echo request, id 3, seq 56228, length 40
[...]
So the echo request is forwarded, but no reply ever comes back.
I can see only two explanations :
- host 192.168.3.51 default route is misconfigured or missing
- or it has a firewall which drops requests from other subnets.

> Ok, here is what I try...
> 
> iptables -t nat -A POSTROUTING -s 192.168.2.0/24 -d 192.168.3.0/24 -j SNAT --to 192.168.3.1
> iptables -t nat -A POSTROUTING -s 192.168.3.0/24 -d 192.168.2.0/24 -j SNAT --to 192.168.2.1

Ah, SNAT aka masquerading. It is called "masquerading" because it
masquerades the source address, but I like to say that it is actually
used to masquerade the real - routing of filtering - problem.

> now can ping from 192.168.2.x to 192.168.3.x,  vice versa.

Back to comp.os.linux.networking | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 05:50 -0700
  Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2012-04-08 17:16 +0300
    Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 08:26 -0700
      Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 08:47 -0700
        Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 18:13 +0200
          Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 09:24 -0700
            Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 18:31 +0200
              Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 09:44 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 19:54 +0200
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 17:13 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-09 10:45 +0200
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-09 06:40 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-09 21:01 +0200
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-09 12:56 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-09 23:33 +0200
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2012-04-10 08:55 +0300
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-09 23:40 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2012-04-10 14:39 +0300
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-10 08:22 -0700
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2012-04-08 21:13 +0300
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 20:48 +0200
                Re: linux as multi-port (subnet) router using Ubuntu 11.10 server lincy <lincylin@gmail.com> - 2012-04-08 17:25 -0700

csiph-web