Jump to content


Assign IP to Cisco switch.


  • Please log in to reply
4 replies to this topic

#1 tom JA

tom JA

    Newbie

  • Members
  • Pip
  • 47 posts

Posted 23 November 2009 - 04:05 PM

Hi Guy,

I am new and have simple question how to Assign IP to Cisco switch.

Please advice.

  • 0

#2 kherona

kherona

    Member

  • Members
  • PipPip
  • 133 posts
  • Gender:Male

Posted 23 November 2009 - 04:26 PM

Depend on the switch model L2 or L3 switch, I will assume you have a layer 2 switch such as 2960 or 3540 etc.

Go to the VLAN interface, lets say you only have VLAN 1 configured.

conf t
interface vlan 1
ip address 192.168.1.1 255.255.255.0
no shutdown
exit


then you have to connect your machine to one of the switch ports, by default all switch ports will be in VLAN 1
if its configured for other VLANs then go to the physical interface config.

conf t
interface fastethernet0/1
switchport access vlan 1
exit

connect your machine to that port and viola!

Edited by kherona, 23 November 2009 - 04:26 PM.

  • 0

#3 new things

new things

    Advanced Member

  • Members
  • PipPipPip
  • 191 posts
  • Gender:Male

Posted 23 November 2009 - 05:24 PM

Hi Guy,

I am new and have simple question how to Assign IP to Cisco switch.

Please advice.

hi dude by default we cannot assign an ip address to switch port, first
it convert into non-switch port then we can assign an ip address to switchport
by using this command we can a switch port into non-switch port

config-if)#int fa0/0
config-if)#no switchport
  • 0

#4 kherona

kherona

    Member

  • Members
  • PipPip
  • 133 posts
  • Gender:Male

Posted 23 November 2009 - 06:12 PM

hi dude by default we cannot assign an ip address to switch port, first
it convert into non-switch port then we can assign an ip address to switchport
by using this command we can a switch port into non-switch port

config-if)#int fa0/0
config-if)#no switchport


You are talking about L3 switch such as 3560 or 3750, but if he has L2 switch then he won't be able to make the interface routed mode.
On the other hand this way is not proper way for management IP since you might need to connect to the switch through multiple ports and use the management IP
  • 0

#5 FreE StyleR

FreE StyleR

    Super Member

  • Members
  • PipPipPipPip
  • 890 posts
  • Gender:Male

Posted 03 December 2009 - 09:02 AM

kherona is right ... you have to assign ip to the vlan interface and then you have to enable vty like ;


en
conf t
line vty 0 4
password ***** <- your password here
login
exit
exit
copy run start


there now from any where you can telnet your switch, but make sure when you assign ip to vlan interface then make it no shut ... when i did that the first time ... i forget to make no shut and i spend 3 hours of embarrassment ... heheeheh




Regards,
  • 0





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users