Switch>enable
Switch#conf terminal
Switch(config)#interface vlan 1
switch(config-if)#no shutdown
switch(config-if)#ip address 192.168.1.1 255.255.255.0
switch(config-if)#exit
Switch(config)#enable secret cisco....(OR)....Switch(config)#enable password cisco
Switch(config)#line vty 0 15
Switch(config-line)#password cisco
Switch(config-line)#login