Two interfaces
- From: "Jozza" <hmm@xxxxxxx>
- Date: Mon, 27 Oct 2008 11:04:04 +0100
Probably this is a standars problem...
I have two interfaces eth0 and eth1. The default interface is eth1. I am
having problems routing the voice traffic to eth0
eth0 10.58.16.28 gw: 10.58.0.1 mask:255.255.0.0.
eth1 192.168.1.110 gw:192.168.1.254: mask 255.255.255.0
I want all outgoing traffic designated to 10.xx.xx.xx to go out through eth0
and also to go through gw 10.58.0.1 when the destination is not in the mask
of eth0's mask, otherwise not.
What i've done so far is:
$iptables -t mangle -A OUTPUT -d 10.0.0.0/8 -j MARK --set-mark 2 #mark
outgoing traffic for 10....with 2
$iptables -t nat -A POSTROUTING -m mark --mark 2 -j SNAT --to 10.58.16.28
#change source address with mark 2 to 10....
$iproute rule add fwmark 2 table tm1 # send all traffic with mark 2 to table
tm1
$iproute route add default via 10.58.0.1 dev eth0 table tm1 #use eth0 and
this default gateway in table tm1
But i see a lot of these in tcpdump on eth0
arp who-has 10.58.0.1 tell 10.58.16.28
arp reply 10.58.0.1 is-at xx:xx:xx:xx:xx:xx
All addresses 192..., 10.58...., 10.22... are pingable, but on every other
call (randomly) there is no voice when it's supposed to go out to
10.22.12.xx. Tcpdump on eth0 shows packets ok:
IP 10.22.12.22.33214 > 10.58.16.28.31802: UDP, length 172
IP 10.58.16.28.1024 > 10.22.12.22.33214: UDP, length 172
and i also see all ok on the packet dump of the voice server.
I suspect there is a problem with lower level communication with gateway,
but i cant see why.
Any suggestions?
Thanks, Jozza
.
- Follow-Ups:
- Re: Two interfaces
- From: Pascal Hambourg
- Re: Two interfaces
- Prev by Date: Re: Overall networking issue...
- Next by Date: Re: Two interfaces
- Previous by thread: Overall networking issue...
- Next by thread: Re: Two interfaces
- Index(es):