Вы находитесь на странице: 1из 3

Press RETURN to get started.

Switch>enable
Switch#config t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hostname S1
S1(config)#banner motd "No unautorized access allowed!"
S1(config)#service pass
S1(config)#service password-encryption enable]
^
% Invalid input detected at '^' marker.
S1(config)#service password-encryption enable
^
% Invalid input detected at '^' marker.
S1(config)#service password-encryption
S1(config)#enable
% Incomplete command.
S1(config)#service pass
S1(config)#
S1(config)#enable sec
S1(config)#enable secret class12345
S1(config)#line console 0
S1(config-line)#login local
S1(config-line)#exec-t
S1(config-line)#exec-timeout 5 0
S1(config-line)#exit
S1(config)#username admin secret danscourses
S1(config)#line vty 0 15
S1(config-line)#login local
S1(config-line)#exec-t
S1(config-line)#exec-timeout 5 0
S1(config-line)#transport input ssh
S1(config-line)#exit
S1(config)#transport input ?
% Unrecognized command
S1(config)#line vty 0 15
S1(config-line)#transport input ssh
S1(config-line)#transport input
% Incomplete command.
S1(config-line)#transport input ?
all
All protocols
none
No protocols

ssh
TCP/IP SSH protocol
telnet TCP/IP Telnet protocol
S1(config-line)#transport input ssh
S1(config-line)#exit
S1(config)#ip domain-name danscourses.com
S1(config)#ip dom
S1(config)#ip domain
S1(config)#ip domainS1(config)#ip domainS1(config)#crypto key generate
S1(config)#crypto key generate rsa
The name for the keys will be: S1.danscourses.com
Choose the size of the key modulus in the range of 360 to 2048 for your
General Purpose Keys. Choosing a key modulus greater than 512 may take
a few minutes.
How many bits in the modulus [512]: 1024
% Generating 1024 bit RSA keys, keys will be non-exportable...[OK]
S1(config)#ip ssh version 2
*mrt 1 2:47:35.531: %SSH-5-ENABLED: SSH 1.99 has been enabled
S1(config)#

S1 con0 is now available

Press RETURN to get started.

No unautorized access allowed!


User Access Verification
Username: admin
Password:
% Login invalid
Username: admin
Password:

S1>
S1>config t
^
% Invalid input detected at '^' marker.
S1>configure t
^
% Invalid input detected at '^' marker.
S1>config
Translating "config"...domain server (255.255.255.255)
% Unknown command or computer name, or unable to find computer address
S1>config t
^
% Invalid input detected at '^' marker.
S1>enable
Password:
Password:
Password:
% Bad secrets
S1>config t
^
% Invalid input detected at '^' marker.
S1>enable
Password:
Password:
S1#config t
Enter configuration commands, one per line. End with CNTL/Z.
S1(config)#interface vlan 1
S1(config-if)#ip address 192.168.4.126 255.255.255.192
S1(config-if)#no shut
S1(config-if)#
%LINK-5-CHANGED: Interface Vlan1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan1, changed state to up
exit
S1(config)#ip defaultS1(config)#ip default-gateway 192.168.4.65
S1(config)#exit
S1#
%SYS-5-CONFIG_I: Configured from console by console
S1#copy run start
Destination filename [startup-config]?
Building configuration...
[OK]
S1#copy run tftp
Address or name of remote host []? 192.168.4.194
Destination filename [S1-confg]?
Writing running-config....!!
[OK - 1401 bytes]
1401 bytes copied in 3.008 secs (0 bytes/sec)
S1#config t

Вам также может понравиться