* [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ?
@ 2004-07-05 16:14 Chris Bolton
2004-07-05 19:21 ` [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi James Sneeringer
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: Chris Bolton @ 2004-07-05 16:14 UTC (permalink / raw)
To: lartc
>>Our ISP has given us 5 static IP address plus one router IP address
>>and I was wondering if I could get rid of their stupid EN5861 router
>>and set up the linux machine to handle all the static addresses and
>>routing. I figured I'd have to set up alises for other IP addresses
>>eg ifconfig eth0:0
>>xx.xx.xx.193 but once I've done that I've found out I cant use ip
>>route to configure it eg ip route add default dev eth0:0 table server.
>>Whats the best way to go about this?
>>
>>Cheers.
>>
>>By the way I'm running redhat 9 with two adsl connections, on is a
>>speedtouch USB modem and the other is the EN5861 router.
>>
>>
>
>I'm not quite sure why you tagged this on to the end of a thread about htb
classes? As a result many people may not even read your question...?
Erm no reason I was just half asleep at the time.
>I have one of those EN5861 router things, and actually I find it pretty
>good. The biggest issue is that it's a bit of a timebomb, the
>powersupply dies after a few years, and unless you have a spare it's a
>bit of a weak link
>Do you need to do some particularly advanced routing that's stopping you
just using the en5861?
No I am using the EN5861, just that we have two ADSL lines and only one
EN5861 and rather than buying another I'd like to use linux to do the same
job as the en5861, if you know what I mean.
So far I've set up ppp0:0 which I've assigned one of the static ip addresses
supplied to us by our ISP but when I try and route through it i.e. ip route
add default dev ppp0:0 table T1 then it returns the error no such device,
which it's quite right there isn't. If I route through it using the ip
address of ppp0:0 i.e ip route add default via x.x.x.193 table T1 then it
does work but anything that goes through it ends up using the IP address of
ppp0.
So how can I set up the linux box to use these static IP addresses in the
same way I can with the EN5861?
I hope I'd made myself clear, it's hard trying to explain something when
your not to sure exactly what your talking about. Anyway any help with be
gladly received.
Cheers,
Chris.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
@ 2004-07-05 19:21 ` James Sneeringer
2004-07-06 7:22 ` FW: " Chris Bolton
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: James Sneeringer @ 2004-07-05 19:21 UTC (permalink / raw)
To: lartc
On Mon, Jul 05, 2004 at 05:14:20PM +0100, Chris Bolton wrote:
> No I am using the EN5861, just that we have two ADSL lines and only one
> EN5861 and rather than buying another I'd like to use linux to do the same
> job as the en5861, if you know what I mean.
You can, but since you have two ADSL lines, you'll need two ADSL devices of
some kind, whether it's a pair of 5861s, or a 5861 and an ADSL port adapter
(external modem, PCI card, whatever) that Linux supports.
The simplest solution will be to have the same setup for both lines. Either
use two 5861s, or get two ADSL adapters that Linux can talk to.
> So far I've set up ppp0:0 which I've assigned one of the static ip addresses
> supplied to us by our ISP but when I try and route through it i.e. ip route
> add default dev ppp0:0 table T1 then it returns the error no such device,
> which it's quite right there isn't. If I route through it using the ip
> address of ppp0:0 i.e ip route add default via x.x.x.193 table T1 then it
> does work but anything that goes through it ends up using the IP address of
> ppp0.
So both lines were supplied by the same ISP?
> So how can I set up the linux box to use these static IP addresses in the
> same way I can with the EN5861?
If you want to remove the 5861 from the picture entirely, you'll need to
replace it with some sort of ADSL adapter. You can't just plug a DSL line
into an ethernet card.
> I hope I'd made myself clear, it's hard trying to explain something when
> your not to sure exactly what your talking about. Anyway any help with be
> gladly received.
It would help if you could draw a diagram of your network so we could get a
better idea of what yo're trying to do.
-James
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
2004-07-05 19:21 ` [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi James Sneeringer
@ 2004-07-06 7:22 ` Chris Bolton
2004-07-06 10:33 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Chris Bolton @ 2004-07-06 7:22 UTC (permalink / raw)
To: lartc
>> No I am using the EN5861, just that we have two ADSL lines and only
>> one
>> EN5861 and rather than buying another I'd like to use linux to do the
>> same job as the en5861, if you know what I mean.
>
>You can, but since you have two ADSL lines, you'll need two ADSL devices of
some kind, whether it's a pair of 5861s, or a 5861 and an ADSL port adapter
(external modem, PCI card, whatever) that Linux supports.
>
>The simplest solution will be to have the same setup for both lines.
Either use two 5861s, or get two ADSL adapters that Linux >can talk to.
>
>> So far I've set up ppp0:0 which I've assigned one of the static ip
>> addresses supplied to us by our ISP but when I try and route through
>> it i.e. ip route add default dev ppp0:0 table T1 then it returns the
>> error no such device, which it's quite right there isn't. If I route
>> through it using the ip address of ppp0:0 i.e ip route add default via
>> x.x.x.193 table T1 then it does work but anything that goes through it
>> ends up using the IP address of ppp0.
>
>So both lines were supplied by the same ISP?
They sure are. Due to our location we can't have an ADSL line faster than
512kbs so we've got two and I'm trying to load balance them.. But that's
another story.
>
>> So how can I set up the linux box to use these static IP addresses in
>> the same way I can with the EN5861?
>
>If you want to remove the 5861 from the picture entirely, you'll need to
replace it with some sort of ADSL adapter. You can't just plug a DSL line
into an ethernet card.
>> I hope I'd made myself clear, it's hard trying to explain something
>> when your not to sure exactly what your talking about. Anyway any
>> help with be gladly received.
>
>It would help if you could draw a diagram of your network so we could get a
better idea of what yo're trying to do.
Ok I'm not the best at ASCII diagrams but here goes anyway... (well I'll
modify the one in the advanced routing howto)
+------------+ /
+---------------| | | IP
ADDRESSES
| +----------+ EN5861 +------- EN5861
- 217.x.196.222
__ | | | | / eth0 -
10.0.0.152
___/ \_ +------+-------+ +------------+ | eth1 -
217.x.196.217
_/ \__ | eth2 eth1 | / eth2 -
217.x.196.218
/ \eth0 | | | ppp0 -
217.x.230.198
| Local network -----+ Linux router | | ppp0:0
- 217.x.230.193
\_ __/ | | | Internet
\__ __/ | ppp0 | \
\___/ +------+-------+ +------------+ |
| | | \
+-------------+ USB +-------
| Speedtouch | |
+------------+
As you can see the linux router has 3 network adapters, eth0 being the local
lan and eth1 & eth2 are both connected to the EN5861 router. I've done that
because I couldn't work out any other way to use the static IP address that
out ISP have given us. For each connection we've got 5 IP addresses plus
one for for the router. Eth1 & eth2 work fine ie both have the correct
static IP address given to us by our ISP but it seems impraticle putting in
another 3 cards to make use of the other IP addresses we have, there must be
another way.
Cheers for the replies, I hope this makes things a bit easier to understand.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: FW: [LARTC] Static ip addresses/aliases previously (my mistake)
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
2004-07-05 19:21 ` [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi James Sneeringer
2004-07-06 7:22 ` FW: " Chris Bolton
@ 2004-07-06 10:33 ` Ed Wildgoose
2004-07-06 12:54 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons Chris Bolton
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Ed Wildgoose @ 2004-07-06 10:33 UTC (permalink / raw)
To: lartc
>eth1 & eth2 are both connected to the EN5861 router. I've done that
>because I couldn't work out any other way to use the static IP address that
>out ISP have given us.
>
Aha, this is a config question. You can just add as many ip addresses
to each physical card as you like. I forget the exact syntax, but check
man pages for "ifconfig" and look for "aliases".
Chances are your distro already has support for this. For example in
gentoo you edit /etc/conf.d/net and edit the aliases line. Different
configs for all "normal" distros, but same idea
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
` (2 preceding siblings ...)
2004-07-06 10:33 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
@ 2004-07-06 12:54 ` Chris Bolton
2004-07-06 15:07 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Chris Bolton @ 2004-07-06 12:54 UTC (permalink / raw)
To: lartc
>>eth1 & eth2 are both connected to the EN5861 router. I've done that
>>because I couldn't work out any other way to use the static IP address
>>that out ISP have given us.
>>
>
>Aha, this is a config question. You can just add as many ip addresses to
each physical card as you like. I forget the exact syntax, but check man
pages for "ifconfig" and look for "aliases".
Right getting the hang of this now, managed to set up aliases for eth0 named
eth0:0 and eth0:1 with the correct Ip addresses but how can I route with
them? When I do something like ip route add default dev eth0:0 it complains
that it cant find eth0:0 as its not a real adapter. I've been searching on
google to no avail and have come to a bit of a full stop.
Cheers.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake)
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
` (3 preceding siblings ...)
2004-07-06 12:54 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons Chris Bolton
@ 2004-07-06 15:07 ` Ed Wildgoose
2004-07-06 15:52 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons James Sneeringer
2004-07-06 16:15 ` FW: " Chris Bolton
6 siblings, 0 replies; 8+ messages in thread
From: Ed Wildgoose @ 2004-07-06 15:07 UTC (permalink / raw)
To: lartc
Chris Bolton wrote:
>>>eth1 & eth2 are both connected to the EN5861 router. I've done that
>>>because I couldn't work out any other way to use the static IP address
>>>that out ISP have given us.
>>>
>>>
>>>
>>Aha, this is a config question. You can just add as many ip addresses to
>>
>>
>each physical card as you like. I forget the exact syntax, but check man
>pages for "ifconfig" and look for "aliases".
>
>Right getting the hang of this now, managed to set up aliases for eth0 named
>eth0:0 and eth0:1 with the correct Ip addresses but how can I route with
>them? When I do something like ip route add default dev eth0:0 it complains
>that it cant find eth0:0 as its not a real adapter. I've been searching on
>google to no avail and have come to a bit of a full stop.
>
>
Hmm, why would you need to route to a specific IP address? Basically it
goes out on eth0 or it doesn't...? What else could it do?
Perhaps you want to mangle things in IPTables or some such first? (eg NAT?)
Ed W
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
` (4 preceding siblings ...)
2004-07-06 15:07 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
@ 2004-07-06 15:52 ` James Sneeringer
2004-07-06 16:15 ` FW: " Chris Bolton
6 siblings, 0 replies; 8+ messages in thread
From: James Sneeringer @ 2004-07-06 15:52 UTC (permalink / raw)
To: lartc
[Sorry if this is received twice. Sent it with the wrong address once, not
sure if the moderator will approve it.]
On Tue, Jul 06, 2004 at 08:22:42AM +0100, Chris Bolton wrote:
> Ok I'm not the best at ASCII diagrams but here goes anyway... (well I'll
> modify the one in the advanced routing howto)
Does this look right? Forget eth0 on Linux for a moment.
---------- ----------
| | eth1 217.x.196.217/29 --- 217.x.196.222/29 | EN5861 | ___ DSL ___
| | eth2 217.x.196.218/29 --------------- eth0 | router | #1
| Linux | ----------
| router | --------------
| | ppp0 217.x.230.198/29 ---------------- | Speedtouch | ___ DSL ___
| | ppp0:0 217.x.230.193/29 -----' | DSL bridge | #2
---------- --------------
> As you can see the linux router has 3 network adapters, eth0 being the local
> lan and eth1 & eth2 are both connected to the EN5861 router. I've done that
> because I couldn't work out any other way to use the static IP address that
> out ISP have given us. For each connection we've got 5 IP addresses plus
> one for for the router. Eth1 & eth2 work fine ie both have the correct
> static IP address given to us by our ISP but it seems impraticle putting in
> another 3 cards to make use of the other IP addresses we have, there must be
> another way.
Ok, so the Speedtouch is some sort of DSL bridge, right? Meaning when you
establish PPP (PPPoE?) to your ISP, you really have another ethernet card
(eth3?) connected to the Speedtouch?
First, as someone else pointed out, the eth1/eth2 connections to the EN5861
are redundant. You can set up interface aliases on eth1 so it has both IP
addresses.
% ip addr add 217.x.196.217/29 brd 217.x.196.223 dev eth1
% ip addr add 217.x.196.218/29 brd 217.x.196.223 dev eth1 label eth1:0
PPP is set up similarly. (PPPoE might configure ppp0 for you.)
% ip addr add 217.x.230.198/29 brd 217.x.230.199 dev ppp0
% ip addr add 217.x.230.193/29 brd 217.x.230.199 dev ppp0 label ppp0:0
You can continue to add as many aliases to either interface as you like.
Your problem then becomes load-balancing outbound traffic, because you have
two potential default routes. One is the PPPoE connection via the
Speedtouch (the remote IP is probably the DSL concentrator at your ISP).
The other is the EN5861 on 217.x.196.222/29 (which in turn is probably
talking to the same DSL concentrator as the Speedtouch).
The simplest approach (aside from defaulting everything out one interface,
which you probably don't want) is to policy route based on source IP. If
the source IP of a packet as it leaves the Linux router is 217.x.196.x/29,
the packet should get routed via eth1 to the EN5861. If the source is
217.x.230.x/29, it should be routed via ppp0 to the Speedpath. There are
examples of this in the LARTC HOWTO. How you want to set up your NAT for
eth0 to take advantage of one connection or the other is up to you.
-James
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
* FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
` (5 preceding siblings ...)
2004-07-06 15:52 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons James Sneeringer
@ 2004-07-06 16:15 ` Chris Bolton
6 siblings, 0 replies; 8+ messages in thread
From: Chris Bolton @ 2004-07-06 16:15 UTC (permalink / raw)
To: lartc
Brillient, cheers for that, appears to be approching 5.30 so I'll have to
read through it tomorrow morning.
First glance it appears its exactly want I need to impliment. I've learnt
so much today with all this its untrue.
Thanks to all whos helped.
-----Original Message-----
From: lartc-admin@mailman.ds9a.nl [mailto:lartc-admin@mailman.ds9a.nl] On
Behalf Of James Sneeringer
Sent: 06 July 2004 16:53
To: lartc@mailman.ds9a.nl
Subject: Re: FW: [LARTC] Static ip addresses/aliases previously (my mistake)
htb: class 10007 isn't work conserving ?!
[Sorry if this is received twice. Sent it with the wrong address once, not
sure if the moderator will approve it.]
On Tue, Jul 06, 2004 at 08:22:42AM +0100, Chris Bolton wrote:
> Ok I'm not the best at ASCII diagrams but here goes anyway... (well
> I'll modify the one in the advanced routing howto)
Does this look right? Forget eth0 on Linux for a moment.
---------- ----------
| | eth1 217.x.196.217/29 --- 217.x.196.222/29 | EN5861 | ___ DSL ___
| | eth2 217.x.196.218/29 --------------- eth0 | router | #1
| Linux | ----------
| router | --------------
| | ppp0 217.x.230.198/29 ---------------- | Speedtouch | ___ DSL ___
| | ppp0:0 217.x.230.193/29 -----' | DSL bridge | #2
---------- --------------
> As you can see the linux router has 3 network adapters, eth0 being the
> local lan and eth1 & eth2 are both connected to the EN5861 router.
> I've done that because I couldn't work out any other way to use the
> static IP address that out ISP have given us. For each connection
> we've got 5 IP addresses plus one for for the router. Eth1 & eth2
> work fine ie both have the correct static IP address given to us by
> our ISP but it seems impraticle putting in another 3 cards to make use
> of the other IP addresses we have, there must be another way.
Ok, so the Speedtouch is some sort of DSL bridge, right? Meaning when you
establish PPP (PPPoE?) to your ISP, you really have another ethernet card
(eth3?) connected to the Speedtouch?
First, as someone else pointed out, the eth1/eth2 connections to the EN5861
are redundant. You can set up interface aliases on eth1 so it has both IP
addresses.
% ip addr add 217.x.196.217/29 brd 217.x.196.223 dev eth1
% ip addr add 217.x.196.218/29 brd 217.x.196.223 dev eth1 label eth1:0
PPP is set up similarly. (PPPoE might configure ppp0 for you.)
% ip addr add 217.x.230.198/29 brd 217.x.230.199 dev ppp0
% ip addr add 217.x.230.193/29 brd 217.x.230.199 dev ppp0 label ppp0:0
You can continue to add as many aliases to either interface as you like.
Your problem then becomes load-balancing outbound traffic, because you have
two potential default routes. One is the PPPoE connection via the
Speedtouch (the remote IP is probably the DSL concentrator at your ISP).
The other is the EN5861 on 217.x.196.222/29 (which in turn is probably
talking to the same DSL concentrator as the Speedtouch).
The simplest approach (aside from defaulting everything out one interface,
which you probably don't want) is to policy route based on source IP. If
the source IP of a packet as it leaves the Linux router is 217.x.196.x/29,
the packet should get routed via eth1 to the EN5861. If the source is
217.x.230.x/29, it should be routed via ppp0 to the Speedpath. There are
examples of this in the LARTC HOWTO. How you want to set up your NAT for
eth0 to take advantage of one connection or the other is up to you.
-James
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2004-07-06 16:15 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-05 16:14 [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conserving ? Chris Bolton
2004-07-05 19:21 ` [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work conservi James Sneeringer
2004-07-06 7:22 ` FW: " Chris Bolton
2004-07-06 10:33 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
2004-07-06 12:54 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons Chris Bolton
2004-07-06 15:07 ` FW: FW: [LARTC] Static ip addresses/aliases previously (my mistake) Ed Wildgoose
2004-07-06 15:52 ` FW: [LARTC] Static ip addresses/aliases previously (my mistake) htb: class 10007 isn't work cons James Sneeringer
2004-07-06 16:15 ` FW: " Chris Bolton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.