Hi,
Well I am able to use both from my first ISP's shell account but I am told
that anywhere else is not working. I added tables T1 and T2 to
/etc/iproute2/rt_table
Is a good resource.
http://www.lartc.org/lartc.htmlhttp://www.lartc.org/lartc.html
I run through the various things and everything apears to look OK.
ip link list
ip address show
ip route list table T1
ip route list table T2
All look good.
I have put these commands into a file in /usr/local/bin/
#!/bin/bash
# Authors: Boyd Lynn Gerber
Boyd Lynn Gerber wrote:
Hi,
Well I am able to use both from my first ISP's shell account but I am told that anywhere else is not working. I added tables T1 and T2 to /etc/iproute2/rt_table
Is a good resource.
http://www.lartc.org/lartc.htmlhttp://www.lartc.org/lartc.html
[snip]
Any ideas on how to proceede?
Well, you basically start by looking at a message as it travels through the expected path - use e.g. tcpdump to track it. At some point the message will take the wrong path, then you work out why. Looking at your setup (snipped), you seem to have duplicated "ip rule add" statements. It doesn't hurt, but it's confusing. Also, if you intended to distribute the load over your two uplinks, I don't see anything doing that. -- Per Jessen, Zürich (13.1°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Fri, Aug 31, 2012 at 09:10:35AM +0200, Per Jessen wrote:
Boyd Lynn Gerber wrote:
Well I am able to use both from my first ISP's shell account but I am told that anywhere else is not working. I added tables T1 and T2 to /etc/iproute2/rt_table
Is a good resource.
http://www.lartc.org/lartc.htmlhttp://www.lartc.org/lartc.html
[snip]
Any ideas on how to proceede?
Well, you basically start by looking at a message as it travels through the expected path - use e.g. tcpdump to track it. At some point the message will take the wrong path, then you work out why.
Looking at your setup (snipped), you seem to have duplicated "ip rule add" statements. It doesn't hurt, but it's confusing. Also, if you intended to distribute the load over your two uplinks, I don't see anything doing that.
An older discussion, unfortunately in German language only, might help you. Cf. http://lists.openSUSE.org/opensuse-de/2010-08/msg01050.html and in particular http://lists.openSUSE.org/opensuse-de/2010-08/msg01061.html If your interface isn't a bridge use ethX instead of brX for the interface name. I guess you'll get the idea. As we've not seen this special requirement often enough till now - I guess we see it one or two times a year - I don't think we need to work on a general YaST, sysconfig, or anything else out of the box solution for this. Cheers, Lars -- Lars Müller [ˈlaː(r)z ˈmʏlɐ] Samba Team + SUSE Labs SUSE Linux, Maxfeldstraße 5, 90409 Nürnberg, Germany
On Fri, 31 Aug 2012, Lars Müller wrote:
On Fri, 31 Aug 2012, Per Jessen wrote:
On Thur, 30 Aug 2012 Boyd Gerber wrote: http://www.lartc.org/lartc.htmlhttp://www.lartc.org/lartc.html Any ideas on how to proceede?
Well, you basically start by looking at a message as it travels through the expected path - use e.g. tcpdump to track it. At some point the message will take the wrong path, then you work out why.
Looking at your setup (snipped), you seem to have duplicated "ip rule add" statements. It doesn't hurt, but it's confusing. Also, if you intended to distribute the load over your two uplinks, I don't see anything doing that.
An older discussion, unfortunately in German language only, might help you. Cf. http://lists.openSUSE.org/opensuse-de/2010-08/msg01050.html and in particular http://lists.openSUSE.org/opensuse-de/2010-08/msg01061.html
If your interface isn't a bridge use ethX instead of brX for the interface name. I guess you'll get the idea.
As we've not seen this special requirement often enough till now - I guess we see it one or two times a year - I don't think we need to work on a general YaST, sysconfig, or anything else out of the box solution for this.
Actually, I will not be doing any load sharing. Problem is CenturyLink
has added so much Fiber that my DSL connection through them with Xmission
now is almost un use-able. They will not route yhe public Class C networs
I have. I have to do something. I was forced to add their Fiber DSL
service and them as an ISP. I purchased 5 static IP's from them. I want
to just receive and send packets to each interface. only for that
interface. I am using one openSUSE machine as my router. Everything
inside is just fine. All I want is each interface
ISP 1 Xmission was a high speed connetion now it is only a
Up/Down 1.5M/900k 3 Class C networks.
eth0 sends and receives on 198.60.105.0 with gateway 198.60.105.2 which
controls 166.60.[62,63].0 and 198.60.105.0
Everything for this goes through an other openSUSE box withpulic IP
addresses.
CenturyLink DSL/Fiber Up/Down 12.5/1.0 M
eth1 sends and receves on 168.103.176.248'29
Other Machines
NAT eth1 |
local ---------------
Machines |openSUSE Server | DSL Modem
------------ --|Box Original |--Internet
------------ | | eth0 | |ISP 3 public |
|Local |----| |------ | Networks |
|192.169.x.x| |openSUSE | -----------------
------------- |Server |
| | eth 1 DSL Modem second ISP
| New |----------Internet
| | |
------------ | Modem NAT Machines
| 192.168.0.X
|----- Local Machines through
Above is my Network Diagram.
Ideally I would like the default on the new Intnet on the Server marked
New above. But still have it answer to the 251 IP's and virtual hosts
Being able to handle all services for 198.60.105.0 that it receives
Curently I have to have the default gateway set to eth0 for it to handle
all the services for 198.60.105.X except 198.60.105.2
This machine handled all of my 198.60.105 Class C network.
So I want it to respond with all services for 198.60.105 but have a
default route to eth1. My rules publised do not seem to really work this
way when I have the network configured from yast2 to default to eth1 They
do allow me to ping, traceroute and bring up many other serices in cluding
We properly from a shell on XMission to my other ISP when the default is
198.60.105.2. But currently from any location outside of XMission to my
CenturyLink network times out.
I know I have done this in the past but since my Stroke Like illness I
really strugle doing these things. I have to go over them many times. So
please forgive my lack of understand and trouble shooting skills. I have
been going over the packets with wireshark. Was not find what I wanted
with tcpdump.
Thanks,
--
Boyd Gerber
Corrected
Other 198.60.105 Machines
|
| Other Machines
NAT eth1 Switch |
local | ---------------
Machines | |openSUSE Server | DSL Modem
------------ | --|Box Original |--Internet
------------ | | | eth0 | |ISP 3 public |
|Local |----| |--------| | Networks |
|192.169.x.x| |openSUSE | -----------------
------------- |Server |
| | eth 1 DSL Modem second ISP
| New |----------Internet
| | |
------------ | Modem NAT Machines
| 192.168.0.X
|----- Local Machines through
Thanks,
--
Boyd Gerber
Boyd Lynn Gerber wrote:
ip route add $P1_NET dev $IF1 src $IP1 table T1 ip route add default via $P1 table T1 ip rule add from $IP1 table T1 ip route add $P2_NET dev $IF2 src $IP2 table T2 #ip route add $P2_NET dev $IF2 src $IP2a table T2 ip route add default via $P2 table T2 ip rule add from $IP2 table T2 ip rule add from $IP2a table T2 #ip route add $P1_NET_MASK dev $IF1 src $IP1 #ip route add $P2_NET_MASK dev $IF2 src $IP2 #ip route add default via $P1 ip route add default via $P2
You can only have one default route. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
James Knott [31.08.2012 14:19]:
Boyd Lynn Gerber wrote:
ip route add $P1_NET dev $IF1 src $IP1 table T1 ip route add default via $P1 table T1 ip rule add from $IP1 table T1 ip route add $P2_NET dev $IF2 src $IP2 table T2 #ip route add $P2_NET dev $IF2 src $IP2a table T2 ip route add default via $P2 table T2 ip rule add from $IP2 table T2 ip rule add from $IP2a table T2 #ip route add $P1_NET_MASK dev $IF1 src $IP1 #ip route add $P2_NET_MASK dev $IF2 src $IP2 #ip route add default via $P1 ip route add default via $P2
You can only have one default route.
Looking at http://lartc.org/howto/lartc.rpdb.multiple-links.html, "table Tn" makes the difference. So there is ip route add default via $P1 table T1 ip route add default via $P2 table T2 ip route add default via $P2 I think the commented lines were quoted only to raise the confusion factor ;-) Regards, Werner -- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Fri, 31 Aug 2012, Werner Flamme wrote:
James Knott [31.08.2012 14:19]:
Boyd Lynn Gerber wrote: You can only have one default route.
I think the commented lines were quoted only to raise the confusion factor ;-)
Sorry,
Here is the cleaned up version
IF1=eth0
IF2=eth1
IP1=198.60.105.164
IP2=168.103.176.49
P0=192.168.0.1
P1=198.60.105.2
P2=168.103.176.54
P0_NET=192.168.0.0/24
P1_NET=198.60.105.0/24
P2_NET=168.103.176.248/29
P0_NET_MASK=255.255.255.0
P1_NET_MASK=255.255.255.0
P2_NET_MASK=255.255.255.248
ip route add $P1_NET dev $IF1 src $IP1 table T1
ip route add default via $P1 table T1
ip route add $P2_NET dev $IF2 src $IP2 table T2
ip route add default via $P2 table T2
ip route add $P1_NET dev $IF1 src $IP1
ip route add $P2_NET dev $IF2 src $IP2
ip route add default via $P1
ip rule add from $IP1 table T1
ip rule add from $IP2 table T2
ip route add $P2_NET_MASK dev $IF2 table T1
ip route add 127.0.0.0/8 dev lo table T1
ip route add $P1_NET_MASK dev $IF1 table T2
ip route add 127.0.0.0/8 dev lo table T2
--
Boyd Gerber
With the rules below, 168.103.176.49 is working, But the second address
assigned 168.103.176.52 is not. I know I am very close and I just can not
seem to see the problem.
ip address show
...
3: eth1:
Here is the cleaned up version
IF1=eth0 IF2=eth1 IP1=198.60.105.164 IP2=168.103.176.49 P0=192.168.0.1 P1=198.60.105.2 P2=168.103.176.54 P0_NET=192.168.0.0/24 P1_NET=198.60.105.0/24 P2_NET=168.103.176.248/29 P0_NET_MASK=255.255.255.0 P1_NET_MASK=255.255.255.0 P2_NET_MASK=255.255.255.248 ip route add $P1_NET dev $IF1 src $IP1 table T1 ip route add default via $P1 table T1 ip route add $P2_NET dev $IF2 src $IP2 table T2 ip route add default via $P2 table T2 ip route add $P1_NET dev $IF1 src $IP1 ip route add $P2_NET dev $IF2 src $IP2 ip route add default via $P1 ip rule add from $IP1 table T1 ip rule add from $IP2 table T2 ip route add $P2_NET_MASK dev $IF2 table T1 ip route add 127.0.0.0/8 dev lo table T1 ip route add $P1_NET_MASK dev $IF1 table T2 ip route add 127.0.0.0/8 dev lo table T2
Thanks for all the assistence so far. I am really close.
Thanks for any more suggestiosn.
--
Boyd Gerber
Here is the cleaned up version that solves the problem
IF1=eth0
IF2=eth1
IP1=198.60.105.164
IP2=168.103.176.49
IP3=168.103.176.52
P0=192.168.0.1
P1=198.60.105.2
P2=168.103.176.54
P0_NET=192.168.0.0/24
P1_NET=198.60.105.0/24
P2_NET=168.103.176.248/29
P0_NET_MASK=255.255.255.0
P1_NET_MASK=255.255.255.0
P2_NET_MASK=255.255.255.248
ip route add $P1_NET dev $IF1 src $IP1 table T1
ip route add default via $P1 table T1
ip route add $P2_NET dev $IF2 src $IP2 table T2
ip route add $P2_NET dev $IF2 src $IP3 table T2
ip route add default via $P2 table T2
ip route add $P1_NET dev $IF1 src $IP1
ip route add $P2_NET dev $IF2 src $IP2
ip route add $P2_NET dev $IF2 src $IP3
ip route add default via $P1
ip rule add from $IP1 table T1
ip rule add from $IP2 table T2
ip rule add from $IP3 table T2
ip route add $P2_NET_MASK dev $IF2 table T1
ip route add 127.0.0.0/8 dev lo table T1
ip route add $P1_NET_MASK dev $IF1 table T2
ip route add 127.0.0.0/8 dev lo table T2
--
Boyd Gerber
On Fri, 31 Aug 2012, James Knott wrote:
Boyd Lynn Gerber wrote:
ip route add $P1_NET dev $IF1 src $IP1 table T1 ip route add default via $P1 table T1 ip rule add from $IP1 table T1 ip route add $P2_NET dev $IF2 src $IP2 table T2 ip route add default via $P2 table T2 ip rule add from $IP2 table T2 ip route add default via $P2
You can only have one default route.
Yes, I know, but you want the packets for a specific ISP to go back over
the same route. Removed comment lines as they are there to allow me to
switch things wuickly
--
Boyd Gerber
participants (5)
-
Boyd Lynn Gerber
-
James Knott
-
Lars Müller
-
Per Jessen
-
Werner Flamme