Link to home
Start Free TrialLog in
Avatar of jskfan
jskfanFlag for Cyprus

asked on

When to use IP Default Gateway command.

When to use IP Default Gateway command.

IP default gateway command , if I am not wrong is used in L2 switches to set up a default gateway so that Administrators can remotely connect to the switch.

OK let's say we have  switch SW1 connected to R1 connected to SW2 and Administrator PC is connected to SW2 , what should be configured  on SW2, R1 , SW1 for Administrator PC to connect to SW1

Thank you
Avatar of Predrag Jovic
Predrag Jovic
Flag of Poland image

You are right. Default gateway should be configured on L2 switches.
Default gateway on all switches are targeting L3 device SVI in the same VLAN (management VLAN).
SOLUTION
Avatar of Qlemo
Qlemo
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jskfan

ASKER

So,  from the Administrator PC, you can telnet to the configured DG  IP address , and you will be in SW1 terminal ?
No. You are telnetting directly to devices (Targeting device management IP address as destination address).
telnet 10.10.10.10

Where 10.10.10.10 is switch management IP address
Also, telnet should not be used, SSH is preferred.
Avatar of jskfan

ASKER

OK..
so on Layer2  SW1 you need to configure :
interface Vlan1
IP address 10.10.10.10

IP Default Gateway 10.10.10.1  ( Ip address of R1 interface facing SW1)
on the PC you can Telnet or SSH to 10.10.10.10 and you will be on the Terminal window of the switch  ?
interface Vlan1
ip address 10.10.10.10 255.255.255.0
!
ip default-gateway 10.10.10.1
!
line vty 0 5
 no login

Open in new window

From device that can route (access) to device:
telnet 10.10.10.10
And you will be placed in exec mode
SW1>
Avatar of jskfan

ASKER

From device that can route (access) to device:
you mean from a PC ?
PC need to be able to get to router, and traffic from router need to be able to get to PC.
Predrag, unless you know a lot about the particular devices in use here, it's a far stretched to assume a particular switch manufacturer, no? And can we please stop talking about VLANs, as a switch can be configured with a management address  very well (usually) without setting up a VLAN (explicitly)?
Avatar of jskfan

ASKER

Qlemo

in L2 Switch, I believe there is only a default Vlan 1
you cannot create VLans.. so the Management interface will be Interface Vlan 1..the only option
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jskfan

ASKER

Thank you very much  for your Input Guys