cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
88150
Views
11
Helpful
28
Replies

problem setting vty password in packet tracer

Clay Plaga
Level 3
Level 3

I'm trying to configure a vty password in packet tracer and I think I'm doing something wrong. These are the commands I'm using:

line vty 0

password test

end

When I do showrun I can see the command, but when I try to get access to the vty line, it never ask's me for the password. What am I doing wrong.

Screen shot included. Thanks.

 

 

28 Replies 28

Well if you can't ping then you can't telnet.

You need to work out why you have no connectivity.

Jon

I got it to work. First I removed the console port, and replaced with a straight through cable between the PC and sw02. Then I did show run and I could see that the interface was shut down. I just brought it up and now I can ping and telnet to both switches. Thank You.

As I suspected, it would be appreciated if you could rate those whose posts were useful.

Martin

I have a similar type of problem
I configured the sw2 like this
enable secret cisco

line vty 0 15
password secret cisco
login
interf vlan 1
ip address 10.0.0.2 255.255.255.0

SW3
enable secret cisco

line vty 0 15
password cisco
login
interf vlan 1
ip address 10.0.0.4 255.255.255.0

I can ping between each other but both the switches  but when I telnet they say my password cisco is wrong
please help

Are the SVI's in the up/up state?

Martin

You type that command on the switch.

However, the other switch will need an IP address (on the same network) for the two to communicate.

Martin

Martin Carr
Level 4
Level 4

It sounds like you do not understand the difference between console and VTY lines...

line con 0 is what is used when you are physically connected to the switch, which from what you have said, I suspect to be the case.

VTY lines are used for connecting remotely, hence why you are not getting prompted.

If this is the case, then you need to configure the above in the same manor, in addition you need to issue the 'login' command.

Martin

Thank You for the information. Yes, last night I did realize that the username & password will only work if reconnect via telnet or SSH, which I am not--I'm connected via the console cable in packet tracer. Is there a way I can connect to a switch with putty using packet tracer? Is there a packet tracer lab where I can practice setting up telnet or ssh, and then log into the switch using putty with the private IP address within the LAN and the public IP address from outside the LAN?

Thanks.

As far as Im aware, Packet Tracer doesn't do any layer 3 routing, so you can't set up an IP address on the switch.

Doing it with routers instead will work fine in Packet Tracer.

This is not correct, PT can route, but irrespective you don't need it to assign an address to a SVI, which is what the OP needs to do, so he can establish a Telnet session.

OP, if you do not know how to do this then say.

For the public side you could use a ML switch with two SVI's, this simulates connecting via the internet, as far as your concerned.

In reality, this isn't what happens at all, as there are many other aspects involved, i.e. PAT/NAT, firewalls, but this is outside the scope of this discussion.

Martin

As far as I know, you can't assign an IP address to an individual interface, but you can assign an administrative IP address to the switch itself. This screen shot is the commands that I used to assign an ip address, subnet mask & gateway. And I have done this on real 2960g.

 

Now you can see the commands. The screen shot is attached.

You cannot create a routed interface on a 2960, to do this you need a ML switch, 3560, 3750 etc.

You have done as I said above, so now you can connect to it via IP.

Martin

Hi,

 

You can check using below steps,

1. Connect two switches

2. Configure IP address in Vlan 1 interface on any one switch

3. Configure enable password

4. Configure line vty on same switch

Then telnet configured ip from another switch.

Example,

Step 2:

Switch1(config)#int vlan1
Switch1(config-if)#ip address 10.0.0.1 255.0.0.0
Switch1(config-if)#no shut

Step 3:

Switch1(config)#enable password cisco

Step 4:

Switch1(config)#line vty 0 4
Switch1(config-line)#password cisco
Switch1(config-line)#login

To check:

Switch2#telnet 10.0.0.1

Review Cisco Networking for a $25 gift card