09-16-2022 06:57 AM
09-16-2022 03:28 PM - edited 09-16-2022 03:45 PM
Ah, although your diagram uses symbols for L2 switches, I did wonder if they were L3 switches when you mentioned routing on them.
As @MHM Cisco World notes, you likely need to enable IP routing so you can route. (BTW, "likely" because on small Cisco L3 switches, often IP routing is off by default, but on large Cisco L3 switches, often IP routing is on by default.)
As @MHM Cisco World also notes, your default static route statement, on sw9 is incorrect. It should be:
ip route 0.0.0.0 0.0.0.0 12.0.0.105
I.e. the next hop for all your switches should be the directly connected router interface's IP.
Additionally, if R2 is representative of all your routers, they all will need the correct static route statements.
Basically, you need a static route statement for any network that's not on a directly connected router interface. In some situations, a default route statement can be used (as it can be used on the switches). For example, R1 and R3 only need a default static route statement using R2's interface IP that connects to them. R2, though, needs either a static route statement for each network on the "far side" of R1 and R3, or it could also use a default route statement in lieu of one or more of those individual route statements, e.g. a default route statement directly toward R1 would replace the two route statements needed for the two "far side" networks.
Making these noted changes should get your pings to work, but there are other "improvements" that might be made to your configs. Also, rather than using static route statements, you could use a dynamic routing protocol.
09-16-2022 07:48 AM
Hello,
what is the context of your question ? Do you have a network topology, configurations ?
09-16-2022 08:17 AM
"Can't ping switches over routers." and "I did all configuration right."
Laugh, well when things don't work, often the most common causes is something (or somethings) isn't (aren't) configured correctly.
"no default gateway in the switches"
That may, or may not, be relevant. Without (much) more information, cannot suggest why you "Can't ping switches over routers."
09-16-2022 08:29 AM
in the switches I create vlan and trunk , ip route.
in the routers I create ip in between the routers and, routers and switches sub interfaces.
09-16-2022 09:15 AM
Ah, that diagram is helpful.
Could you provide attachments of vIOS2's and Switch9's configs?
Could you also clarify, an example, of a ping that doesn't work? I.e. being done on/from what device, and what address is being pinged? (Ideally using devices vIOS2 and Switch9.)
09-16-2022 09:47 AM
09-16-2022 11:53 AM - edited 09-16-2022 11:56 AM
add only ip routing to switch and it will work
also you config next-hop in static route that out range of VLAN30 subnet ? this must be correct
12.0.0.97 - 12.0.0.126 |
09-16-2022 03:40 PM
I have write the ip routing, and change the VLAN 30 IP's subnet ... still the same no ping to the VLAN 30 IP and no default gateway.
09-16-2022 03:51 PM
Show me config of sw
09-16-2022 03:28 PM - edited 09-16-2022 03:45 PM
Ah, although your diagram uses symbols for L2 switches, I did wonder if they were L3 switches when you mentioned routing on them.
As @MHM Cisco World notes, you likely need to enable IP routing so you can route. (BTW, "likely" because on small Cisco L3 switches, often IP routing is off by default, but on large Cisco L3 switches, often IP routing is on by default.)
As @MHM Cisco World also notes, your default static route statement, on sw9 is incorrect. It should be:
ip route 0.0.0.0 0.0.0.0 12.0.0.105
I.e. the next hop for all your switches should be the directly connected router interface's IP.
Additionally, if R2 is representative of all your routers, they all will need the correct static route statements.
Basically, you need a static route statement for any network that's not on a directly connected router interface. In some situations, a default route statement can be used (as it can be used on the switches). For example, R1 and R3 only need a default static route statement using R2's interface IP that connects to them. R2, though, needs either a static route statement for each network on the "far side" of R1 and R3, or it could also use a default route statement in lieu of one or more of those individual route statements, e.g. a default route statement directly toward R1 would replace the two route statements needed for the two "far side" networks.
Making these noted changes should get your pings to work, but there are other "improvements" that might be made to your configs. Also, rather than using static route statements, you could use a dynamic routing protocol.
09-16-2022 04:26 PM
I want to clarify my self, now the Switch9 having default gateway but if I ping from vIOS2 to switch9 on VLAN 30, ip 12.0.0.107 not working.
and for vIOS2 how I put the ip route?
last thing... I have to create the same ip route as for all the switches ip route 0.0.0.0 0.0.0.0 12.0.0.0.5 or everyone for it's next hop ?