VTY question

e24ohme24ohm Member Posts: 151
Folks:
I am trying to configure my vty lines.

config t
line vty 0 4
password
login

I want to only configure a password on line vty 0; however, I understand that line vty 0 4 can not be deleted, which leads me to my next question.

How do you specifiy which vty line to come in on?
Utini!

Comments

  • peanutnogginpeanutnoggin Member Posts: 1,096 ■■■□□□□□□□
    You can just type:
    line vty 0 0
    password ABC123
    login
    

    That will limit you to only one telnet/ssh session (via VTY 0). When you specify "line vty 0 4" that means include 0,1,2,3,&4. HTH.

    -Peanut
    We cannot have a superior democracy with an inferior education system!

    -Mayor Cory Booker
  • e24ohme24ohm Member Posts: 151
    You can just type:
    line vty 0 0
    password ABC123
    login
    

    That will limit you to only one telnet/ssh session (via VTY 0). When you specify "line vty 0 4" that means include 0,1,2,3,&4. HTH.

    -Peanut

    Ok thanks, that is what I was looking for. In addition, how do you specifiy which vty line to come in onto the router? Or does it use the first line (0), then uses the next line (1) if someone is already on line vty 0?

    I guess, I can configure different passwords for each line vty; however, I'm just trying to understand which line is used when, or how the process takes place.

    thanks again.
    Utini!
  • peanutnogginpeanutnoggin Member Posts: 1,096 ■■■□□□□□□□
    I believe you're right... you come in on line 0, then if that one is tied up, line 1, etc... like you suggested, the best way to test it out is to configure different passwords for each line. Let us know your results...

    -Peanut
    We cannot have a superior democracy with an inferior education system!

    -Mayor Cory Booker
  • StoticStotic Member Posts: 248
    You come on each line in sequential order. Sometimes the line won't time out, so if you login again quickly you'll take the next available vty. An easy way to see which vty you're logged into is to issue the show line command and look for the vty line with the *.
  • e24ohme24ohm Member Posts: 151
    I believe you're right... you come in on line 0, then if that one is tied up, line 1, etc... like you suggested, the best way to test it out is to configure different passwords for each line. Let us know your results...

    -Peanut

    Ok was able to check this, and this is what I found.

    Specs of router
    Sytem Boostrap, Version 12.1(3r)T2
    Cisco 2650
    System image file is "flash:c2600-jls2-mz.123-15.bin"

    ----
    Connected use telnet from Ubuntu 9.10
    ----

    i configured a different password for each line vty.

    --The first attempt at connection via telnet.
    asked for password, I used the password for line vty 2; however, this did not work.

    Used the password for line vty 3, and this did not work.

    Ended up trying password for line vty 0, and this worked.

    --Second telnet connection
    used password for vty line 2, but did not work

    used password for vty line 3, but thsi did not work.

    used password for vty line 1, which worked.

    ====

    It looks like we are right. The first telnet connection will use line vty 0. The second telnet connection will use line 1.

    However, when i do a sh line vty 0 4command. I notice a catagory labled "user", so I am not sure if I am able to create users on my IOS version, of if that is for SSH users when configured.

    thanks again.
    Utini!
  • e24ohme24ohm Member Posts: 151
    Stotic wrote: »
    You come on each line in sequential order. Sometimes the line won't time out, so if you login again quickly you'll take the next available vty. An easy way to see which vty you're logged into is to issue the show line command and look for the vty line with the *.

    I did notice the *. Thanks for pointing that out.
    Utini!
  • MonkerzMonkerz Member Posts: 842
    e24ohm wrote: »
    I want to only configure a password on line vty 0; however, I understand that line vty 0 4 can not be deleted.

    If you only want to allow connections on vty 0, you will need to disable the other lines leaving only one line for connections. You can do this by:

    Router#conf t
    Router(config)#line vty 0
    Router(config-line)#password cisco
    Router(config-line)#login
    Router(config)#line vty 1 4
    Router(config-line)#no login
    Router(config-line)#exit

    Your config should look like this:

    !
    line con 0
    line vty 0
    password cisco
    login
    line vty 1 4
    no login
    !
  • alan2308alan2308 Member Posts: 1,854 ■■■■■■■■□□
    Monkerz wrote: »
    If you only want to allow connections on vty 0, you will need to disable the other lines leaving only one line for connections. You can do this by:

    Router#conf t
    Router(config)#line vty 0
    Router(config-line)#password cisco
    Router(config-line)#login
    Router(config)#line vty 1 4
    Router(config-line)#no login
    Router(config-line)#exit

    Your config should look like this:

    !
    line con 0
    line vty 0
    password cisco
    login
    line vty 1 4
    no login
    !

    no login doesn't mean that you won't be able log in, it means that you won't be prompted for a password on those lines when you telnet in.
  • MonkerzMonkerz Member Posts: 842
    I've been up too late, I meant to type login without specifying a password. Sorry.
Sign In or Register to comment.