cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
725
Views
5
Helpful
13
Replies

ccna question

jonk34567
Level 4
Level 4

question is attached below. what is the answer ?

1 Accepted Solution

Accepted Solutions

No, this default gateway is not for InterVlan routing. Now Switch SVI VLAN 1 is working same as your system NIC. It should be aware, If It doesn't have routing information (except local subnet) then where the packet will send. So Default gateway is telling to switch is this is your default route.

 

Regards,

Deepak Kumar

Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

View solution in original post

13 Replies 13

Deepak Kumar
VIP Alumni
VIP Alumni
The answer is D.

Regards,
Deepak Kumar
Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

if the default gateway is not assigned for host B then how it can ping A and C ?

Please read the answer. It is for the switch. The default gateway is not assigned to the switch.

Regards,
Deepak Kumar
Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

ok if switch is not assigned Default Gateway how host B can ping host A or C ?

yes. it is L2 device so if host A ( VLAN-1 ) needs to ping host B ( vlan 32 ) , the intervlan routing should occur in the router interface.so the packet needs to leave the switch. how can that happen without any default gateway assigned to switch ? 

Hi,

you are confused between switch's L2 mode and L3 mode. While a switch will in L2 mode, it will take packet forwarding decision based on the MAC Table and L3 mode is taking a decision on the routing table. 

So in your case, When Host B (VLAN 32) sending a packet to the router and router forwarding this packet to Host A (VLAN 1). Now your switch is not aware of the source and destination IP address, It is having MAC address in the MAC table and sending a packet to Host A and vice versa based on your L2 header of the packet. 

Now Switch is having manageable IP in VLAN 1 and you are trying to access from Host B (VLAN 32). Now router is forwarding packet to switch SVI and switch is not aware of the source IP address, which is in the packet and not aware of his gateway (L3) device. So packet dropped at the switch itself. (here, Switch MAC table will not be working because it should be replying to the l3 address).

 

Regards,

Deepak Kumar

 

 

Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

the question says

1.the host B can ping host A and host C

2.the host B can not telnet to Switch 

your answer to resolve this issue is to configure default gateway in switch B.

so now my question is how intervlan routing can occur without a default gateway. 

"so now my question is how intervlan routing can occur without a default gateway. "

As I mentioned that Inter VLAN routing is configured on the Router so all routing decision will take care of the router.
The switch is working as an L2 switch. It is responsible for L2 routing.

Regards,
Deepak Kumar

Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

for intervlan routing 

  1. need to configure sub interfaces in router 

            

Router(config)#int fa0/0.1
Router(config-subif)#encapsulation dot1q 10
Router(config-subif)#ip address 11.1.1.1 255.255.255.0
Router(config-subif)#no shut

2.need to assign ip address for vlan 

 

switch(config)#int vlan 1
switch(config-vlan)#ip address 10.1.1.1 255.255.255.0
Router(config-subif)#no shut

 3.configure ip default gateway on switch 

  swi

switch(config)#ip default-gateway 11.1.1.1

 Are my 3 steps correct for intervlan configuration ? ( just the steps. i used random ip addresses )

Hi, It is better that you will assign the same VLAN (VLAN 1) gateway as your SVI address in the switch (VLAN 1).


Regards,
Deepak Kumar
Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

my question is do we need step-3( default gateway )  for inter-vlan routing ? 

No, this default gateway is not for InterVlan routing. Now Switch SVI VLAN 1 is working same as your system NIC. It should be aware, If It doesn't have routing information (except local subnet) then where the packet will send. So Default gateway is telling to switch is this is your default route.

 

Regards,

Deepak Kumar

Regards,
Deepak Kumar,
Don't forget to vote and accept the solution if this comment will help you!

yes i got it now. thank you very much for helping me to figure it out.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: