cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
858
Views
0
Helpful
5
Replies

default-gateway on a switch

why we configure default-gateway on a switch ? Can someone give an example ? As i know switches makes forwarding decisions based on layer 2 ( i mean layer 2 switches).

5 Replies 5

Mark Yeates
Level 7
Level 7

The "ip default-gateway" command is used to enter your router's default gateway, just as you would do on your normal Windows machine. This is used for the management of the switch so that it can be reached from outside networks. This is mainly used on layer 2 switches, and layer 3 switches that are not doing any routing.

Mark

so if switch has management interface 172.16.1.1/24 and i want to telnet it from 192.168.1.33/24,they are at different networks,do i have to use default-gateway command?

Yes you will need a gateway to route between the networks. You will need a router or a layer 3 switch to do this function.

thank you for your answer.

You are most welcome! Best of luck on the implementation of your switch.

Mark

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: