Linux Netfilter discussions
 help / color / mirror / Atom feed
From: <jwexler@mail.usa.com>
To: netfilter@vger.kernel.org
Subject: RE: Bidirectionally Route all traffic to an ip to another ip
Date: Mon, 26 Jul 2010 20:07:33 +0900	[thread overview]
Message-ID: <00d501cb2cb2$c97f6000$5c7e2000$@usa.com> (raw)
In-Reply-To: <alpine.LSU.2.01.1007261133020.22382@obet.zrqbmnf.qr>

Thanks. It still did not work.

Should I only be doing a ip route add 192.168.50.1/32 via 192.168.40.1
statement or should I also be adding iptables commands?
I am having trouble getting the ip route add 192.168.50.1/32 to use dev eth1
instead of eth0.

When I do:
ip route add dev eth5 192.168.50.1/32 via 192.168.40.1
I get an error: RTNETLINK answers: No such process

Should I also be doing some kind of ip addr add dev eth5? And/or add src
192.168.50.1/32 to the ip route add command somehow?

I have tried many combinations but still have not gotten it to work yet.

Thanks!!
JW

-----Original Message-----
From: netfilter-owner@vger.kernel.org
[mailto:netfilter-owner@vger.kernel.org] On Behalf Of Jan Engelhardt
Sent: Monday, July 26, 2010 6:35 PM
To: jwexler@mail.usa.com
Cc: netfilter@vger.kernel.org
Subject: Re: Bidirectionally Route all traffic to an ip to another ip

On Monday 2010-07-26 11:23, jwexler@mail.usa.com wrote:

>Greetings,
>
>I need to be able to do the following:
>
>Physical Router located at 192.168.40.1
>
>On Ubuntu 10.04 Lucid machine:
>eth0 with static ip 192.168.40.2
>eth1 with static ip 192.168.40.3
>eth2 with static ip 192.168.40.4
>
>Associate a virtual address to eth1 with an entirely different network
>address such as 192.168.50.1
>Do the same (virtual address) for eth2 -- e.g. 192.168.60.1
>
>In the application:
>register phone number A at 192.168.40.1 (The application will automatically
>use eth0 for this)
>register phone number B at 192.168.50.1
>register phone number C at 192.168.60.1
>
>Somehow forward all traffic (including the register request) sent to
>192.168.50.1 to 192.168.40.1 as if the register had been made directly to
>192.168.40.1. In other words, the app "sends" registration and traffic to
>192.168.50.1 but then Ubuntu forwards it to 192.168.40.1 (but the app does
>not know that).


ip route add 192.168.50.1/32 via 192.168.40.1

etc.

--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


  reply	other threads:[~2010-07-26 11:07 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-26  9:23 Bidirectionally Route all traffic to an ip to another ip jwexler
2010-07-26  9:34 ` Jan Engelhardt
2010-07-26 11:07   ` jwexler [this message]
2010-07-28 10:46     ` jwexler
2010-07-28 11:28       ` jwexler

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='00d501cb2cb2$c97f6000$5c7e2000$@usa.com' \
    --to=jwexler@mail.usa.com \
    --cc=netfilter@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox