cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4537
Views
1
Helpful
2
Replies

Deleting all local username and password in one command

Tony.V
Level 1
Level 1

Deleting all local username and password in one command

I have1500 switches that have different local username and passwords.

I need to have a template that can clear any local username without checking what are the different usernames configured on each switch.

Is there a way to delete any local username and password without specifying the username .

for example in order to delete a local username and password we should at least know the username

no username cisco privilege 15 secret xxx

 

2 Replies 2

Hi @Tony.V 

 "no username 'username' " is enough, you dont need to use the password but, the thing is you need to inform the username.

 This job can not be done with one command, that´s for sure. If it possible, however, if you work in a script  either with Pyton or expect or whatever language you prefer and it will required some logic.

 You need to get into the switch, find the username in use, remove the username and move the next one.  If you had Cisco Prime, I would say it wouldn´t required programming but if not, then you need to run scripts.

you cannot delete all username in all SW, but you can do 
instead of using under vty login local use login and add password you want.
please notice this seriously must done carefull, you can loss telnet/SSH to SW's if you wrong do config.