background image
208
Chapter 4
Introduction to the Cisco IOS
Here's an example of how to configure both commands:
Router(config)#line con 0
Router(config-line)#exec-timeout ?
<0-35791> Timeout in minutes
Router(config-line)#exec-timeout 0 ?
<0-2147483> Timeout in seconds
<cr>
Router(config-line)#exec-timeout 0 0
Router(config-line)#logging synchronous
Telnet Password
To set the user-mode password for Telnet access into the router, use the line
vty
command. Routers that aren't running the Enterprise edition of the
Cisco IOS default to five VTY lines; 0 through 4. But if you have the Enter-
prise edition, you'll have significantly more. The best way to find out how
many lines you have is to use the question mark:
Router(config-line)#line vty 0 ?
<1-4> Last Line Number
<cr>
Router(config-line)#line vty 0 4
Router(config-line)#login
Router(config-line)#password todd2
What happens if you try to telnet into a router that doesn't have a VTY pass-
word set? You'll receive an error stating that the connection is refused because
the password isn't set. But you can get around this and tell the router to allow
Telnet connections without a password by using the no login command:
Router(config-line)#line vty 0 4
Router(config-line)#no login
After your routers are configured with an IP address, you can use the Tel-
net program to configure and check your routers instead of having to use
a console cable. You can use the Telnet program by typing telnet from
any command prompt (DOS or Cisco). Anything Telnet is covered more
thoroughly in Chapter 7.
If you can ping a router but are unable to telnet into it, the likely problem is
that you didn't set the password on the VTY lines.
Copyright ©2002 SYBEX, Inc., Alameda, CA
www.sybex.com