Differences

This shows you the differences between two versions of the page.

Link to this comparison view

rb:cicso-misc [15/08/2019 16:49] (current)
andrew created
Line 1: Line 1:
 +====== Cisco Misc info ======
  
 +===== Page Breaks (in sh run etc..) =====
 +
 +
 +To stop the page breaks:
 +  ​
 +  # terminal length 0
 +  ​
 +To resume them:
 +  ​
 +  # terminal no length 0 (or number ex. 24)
 +
 +===== Capture console messages to VTY =====
 +
 +Console messages are not usually logged to a telnet / ssh vty session, ''​term mon''​ enables this and ''​no term mon''​ disables.
 +
 +  # terminal monitor
 +===== Usernames in logins =====
 +
 +<​code>​
 +sw-1(config)#​service password-encryption
 +sw-1(config)#​username myuser password topsecret
 +</​code>​
 +
 +This results in:-
 +
 +  sw-1#sh run
 +  Building configuration...
 +  ...edited...
 +    username myuser password 7 <​encrypted password>​
 +
 +Each line needs to be configured to use the local password database:-
 +
 +<​code>​
 +sw-1(config)#​line vty 0 4
 +sw-1(config-line)#​login local
 +</​code>​
 +
 +
 +
 +===== SSH access to switch =====
 +
 +
 +==== Config ssh ====
 +
 +<​code>​
 +sw-1(config)#​ip ssh version 2
 +crypto key generate rsa modulus 2048
 +ip ssh time-out 60  ​
 +ip ssh authentication-retries 3 
 +</​code>​
 +
 +==== Force ssh only by disabling telnet ====
 +
 +
 +<​code>​
 +line vty 0 4
 + ​password 7 07062341165B4150
 + login local
 + ​transport input ssh
 +line vty 5 15
 + ​password 7 07062341165B4150
 + login local
 + ​transport input ssh
 +</​code>​

rb/cicso-misc.txt ยท Last modified: 15/08/2019 16:49 by andrew