-
March 26th, 2003, 05:11 PM
#11
Re: A Routing problem.. Please help? :-/
Originally posted here by ostefan
interface Ethernet0
ip address 219.18.129.205 255.255.255.252
half-duplex
!
interface FastEthernet0
ip address 84.12.145.41 255.255.255.248
speed auto
half-duplex
!
ip default-gateway 219.18.129.206
ip classless
ip route 0.0.0.0 0.0.0.0 219.18.129.206
ip route 84.12.145.40 255.255.255.248 FastEthernet0
ip route 194.19.32.96 255.255.255.224 FastEthernet0
I may have found it. Remove all the ip routes. And just add this:
ip default-gateway 219.18.129.206
ip route 194.19.32.96 255.255.255.224 84.12.145.43
That should make it work.
The ip route 194.19.32.96 255.255.255.224 FastEthernet0 told the router the 194.19.32.96 network was directly connected to FastEthernet0. It isn't, it should be routed by Debian #1.
-
March 26th, 2003, 05:12 PM
#12
Do you own all these IP's?
I would use private addresses
172.16.x.x-172.31.x.x
10.x.x.x
192.168.x.x
on any private interface and NAT that to the internet
-
March 26th, 2003, 05:18 PM
#13
Junior Member
Don't know what's up with the bcast address.. It should read 84.12.145.47.
I changed it manually, so now it looks like this:
eth0
inet addr:84.12.145.43 Bcast:84.12.145.47 Mask:255.255.255.248
It didn't help though..
Originally posted here by SirDice
I may have found it. Remove all the ip routes. And just add this:
ip default-gateway 219.18.129.206
ip route 194.19.32.96 255.255.255.224 84.12.145.43
That should make it work.
The ip route 194.19.32.96 255.255.255.224 FastEthernet0 told the router the 194.19.32.96 network was directly connected to FastEthernet0. It isn't, it should be routed by Debian #1.
YES!!!! IT WORKS!!
Thank allot SirDice, you've made my day, the whole week!!
- Ole S -
Oslo/Norway
-
March 26th, 2003, 05:41 PM
#14
Originally posted here by ostefan
YES!!!! IT WORKS!!
Thank allot SirDice, you've made my day, the whole week!!
Glad to help. Had to make a little drawing on paper to figure it out though.
Do you understand why it didn't work? That's the whole point of this exercise
-
March 26th, 2003, 05:54 PM
#15
Tell me if I'm wrong!
addresses & related mask seem weird:
e.g. 84.12.145.40 255.255.255.248
the mask means that the last byte is masked, in binary, by 11111000
so addresses belonging to that network are:
11111000: 248
11111001: 249
11111010: 250
11111011: 251
11111100: 252
11111101: 253
11111110: 254
84.12.145.40 does not belong to the subnet
[shadow] SHARING KNOWLEDGE[/shadow]
-
March 26th, 2003, 08:00 PM
#16
Junior Member
Originally posted here by Networker
Tell me if I'm wrong!
addresses & related mask seem weird:
e.g. 84.12.145.40 255.255.255.248
the mask means that the last byte is masked, in binary, by 11111000
so addresses belonging to that network are:
11111000: 248
11111001: 249
11111010: 250
11111011: 251
11111100: 252
11111101: 253
11111110: 254
84.12.145.40 does not belong to the subnet
Well.. if you try using a ipcalc of some kind it seems that 84.12.145.40/29 is a valid
subnet. the 84.12.145.40 address it the subnet address, 84.12.145.47 is the bcast address.
Maybe someone else can give the binary explanation? This is kind of new to me.
Originally posted here by SirDice
Glad to help. Had to make a little drawing on paper to figure it out though.
Do you understand why it didn't work? That's the whole point of this exercise
Hi,
Yes, I think I understand why it didn't work. As you said, the ip route 194.19.32.96 255.255.255.224 FastEthernet0 told the router to look for any address in that range on the router itself. And that doesn't do any good. The router cannot answer it's own requests. I guess the result will be some kind of loopback?
-
March 26th, 2003, 10:59 PM
#17
Originally posted here by ostefan
Hi,
Yes, I think I understand why it didn't work. As you said, the ip route 194.19.32.96 255.255.255.224 FastEthernet0 told the router to look for any address in that range on the router itself. And that doesn't do any good. The router cannot answer it's own requests. I guess the result will be some kind of loopback?
Allmost. There's no loopback. It just thought the host was connected to a segment on one of it's own interfaces. That's why you saw the ARP request on that segment. It should hand the packet over to Debian#1 and forget about it. Just let Debian#1 figure out where it goes next.
As for the subnetmask, the last 3 bits are for the hosts and the rest is to assign the network-number. As you said use an IP subnet calculator if you're not sure.
84.12.145.40 with netmask 255.255.255.248 is
84.12.145.40 (network address, don't use)
84.12.145.41 (first host in 84.12.145.40/29)
..
..
84.12.145.46 (last host in 84.12.145.40/29)
84.12.145.47 (subnet broadcast address)
(notice the 0..7 here, 3 bits
This means 84.12.145.48/29 is the next subnet.
-
March 27th, 2003, 10:34 AM
#18
Well, well, well,
I'm maybe from the old scholl? But I think that's more understandable in binary. I've to say you're absolutely right SirDice. (And I apologize for the poor quality of my previous post )
Sirdice wrote:
As for the subnetmask, the last 3 bits are for the hosts and the rest is to assign the network-number. As you said use an IP subnet calculator if you're not sure. [....]
Let me explain my theoritical point of view:
As example the subnet is 1.1.1.40/29 that's mean
Byte 1 Byte 2 Byte 3 Byte 4
Subnet @ 00000001 00000001 00000001 00101000
Mask 11111111 11111111 11111111 11111000
=>
Filter (inv AND) 11111110 11111110 11111110 11010111
The filter is used in the routing process to compare incoming frame with the route in the routing tabel there is one filter per route.
Incomming Packet to 1.1.1.44: Its binary value is compare to the filter
Packet 00000001 00000001 00000001 00101100
Filter 11111110 11111110 11111110 11010111
Result (AND) 11111111 11111111 11111111 11111111
The result is 255.255.255.255 => frame fits the route
Incomming Packet to 1.1.1.54: Its binary value is compare to the filter
Packet 00000001 00000001 00000001 00110110
Filter 11111110 11111110 11111110 11010111
Result (OR) 11111111 11111111 11111111 11110111
The result is not 255.255.255.255 => frames does not fit the route
[shadow] SHARING KNOWLEDGE[/shadow]
-
March 27th, 2003, 11:27 AM
#19
That's about it Networker :-)
Seeing that so many ppl still have trouble with ip subnet calculation i will see if i can write a proper tutorial about it (if i can find some spare time). Also alot of ppl don't know how to convert decimal to binary or hexadecimal, so i might do that one too.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|