advertising a non-existent network?
mguy
Member Posts: 167 ■■■□□□□□□□
in CCNA & CCENT
I have a general question. two, actually. been bugging me.
#1 How come I can't have RIP advertise a non-existent network?
I'm trying to practice NATing and I want R2 to think R1 has the network I just performed NAT on.
(R1)ip nat inside source list 1 1.1.1.1 overload
(R1)router rip
network 1.1.1.1
Result: R2 will not see I that R1 has network and will just drop the packet
#2 This bugs me
When you perform a network statement how come you don't have to include the mask?
Say I have a network: 192.168.1.8 255.255.255.255.248
So..
(R1) router rip
(R1) version 2
(R1) network 192.168.1.0
but tadah! it knows the mask.. automagically.. ? :
#1 How come I can't have RIP advertise a non-existent network?
I'm trying to practice NATing and I want R2 to think R1 has the network I just performed NAT on.
(R1)ip nat inside source list 1 1.1.1.1 overload
(R1)router rip
network 1.1.1.1
Result: R2 will not see I that R1 has network and will just drop the packet
#2 This bugs me
When you perform a network statement how come you don't have to include the mask?
Say I have a network: 192.168.1.8 255.255.255.255.248
So..
(R1) router rip
(R1) version 2
(R1) network 192.168.1.0
but tadah! it knows the mask.. automagically.. ? :
Comments
-
stlsmoore Member Posts: 515 ■■■□□□□□□□I think for #2 RIPv2 assumes the subnet mask is 255.255.255.248 because there's an interface on that router a part of that particular subnet already. Hopefully, someone smarter than me can chime in though lol.My Cisco Blog Adventure: http://shawnmoorecisco.blogspot.com/
Don't Forget to Add me on LinkedIn!
https://www.linkedin.com/in/shawnrmoore -
NetworkVeteran Member Posts: 2,338 ■■■■■■■■□□#1 How come I can't have RIP advertise a non-existent network?
R1(config)#ip route 2.0.0.0 255.0.0.0 null0
R1(config)#router rip
R1(config-router)#network 1.0.0.0
R1(config-router)#redistribute static
R1(config-router)#end
R1#sh
*Mar 1 09:15:41.477: %SYS-5-CONFIG_I: Configured from console by console
R1#show ip rip database
1.0.0.0/8 auto-summary
1.1.1.0/24 directly connected, FastEthernet0/0
2.0.0.0/8 auto-summary
2.0.0.0/8 redistributed
[1] via 0.0.0.0,#2 This bugs me
When you perform a network statement how come you don't have to include the mask?... (R1) network 192.168.1.0Hopefully, someone smarter than me can chime in though lol. -
networker050184 Mod Posts: 11,962 ModI think your confusion comes from what the network command actually does. The network command is there to tell the router what interface to include in the routing process. It doesn't actually tell the router what network to advertise, that is taken from the actual configuration on the interface.An expert is a man who has made all the mistakes which can be made.
-
mguy Member Posts: 167 ■■■□□□□□□□So the network command doesn't make the router say "Hi other routers! I know about this network!!(1.1.1.0)" but rather it is merely activating the interfaces that fall into the network.
Thus,
(R1) network 1.1.1.0
without an actual interface configured with that IP address, doesnt activate the sending of advertisements on a valid interface address, and thus null. So basically, you can't advertise a non-existent network because you will need an interface in that non-existend network in the first place?! At least until ICDN2.. dunno about redistribution.. yet.. -
Zartanasaurus Member Posts: 2,008 ■■■■■■■■■□
Right. The network command is including interfaces into the RIP process and advertising the network associated with that interface. If none of your interfaces match the network statement, then it doesn't include anything in the process. The network statement is pretty vanilla in RIP vs EIGRP/OSPF where you can use a mask to be more specific with which interfaces you want to include (OSPF even takes it further by allowing you to activate OSPF directly under the interface).
Also remember that RIPv2 includes the subnet mask in its update messages, whereas RIPv1 doesn't. So it's RIPv1 that makes assumptions about what the mask is based on the receiving interface. RIPv2 neighbors are told explicitly.
Now if you ever get to BGP, forget everything we just told you about how the network command works.Currently reading:
IPSec VPN Design 44%
Mastering VMWare vSphere 5 42.8% -
NetworkVeteran Member Posts: 2,338 ■■■■■■■■□□dunno about redistribution.. yet..So basically, you can't advertise a non-existent network because you will need an interface in that non-existend network in the first place?!
Even ignoring the redistribute command, there are multiple ways to advertise networks that don't really physically exist in your autonomous system--
R1(config)#router rip
R1(config-router)#network 1.0.0.0
R1(config-router)#default-information originate
R1(config-router)#end
R1#sh ip r
*Mar 2 07:38:00.448: %SYS-5-CONFIG_I: Configured from console by console
R1#sh ip rip database
0.0.0.0/0 auto-summary
0.0.0.0/0 redistributed
[1] via 0.0.0.0,
1.0.0.0/8 auto-summary
1.1.1.0/24 directly connected, FastEthernet0/0
This is the entirety of what RIP actually sends on the Fa0/0 interface--
Routing Information Protocol
Command: Response (2)
Version: RIPv1 (1)
IP Address: 0.0.0.0, Metric: 1
Address Family: IP (2)
IP Address: 0.0.0.0 (0.0.0.0)
Metric: 1