cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4921
Views
0
Helpful
2
Replies

using the command (Autocommand)

omar.elmohri
Level 1
Level 1

Hello,

i'm asking about something that I encounter, when using the command 'autocommand'

When I use it in the line mode router(config-line)# that works when I log in the line.

But that don't work when using it with the command (config)#username [usr] autocommand.

Any idea to fix that ?

Regards,

2 Replies 2

didyap
Level 6
Level 6

To automatically execute a command when a user connects to a particular line, use the autocommand command in line configuration mode. To disable the automatic execution, use the no form of this command.

autocommand command

where command Any appropriate EXEC command, including the host name and any switches that occur with the EXEC command.

For the furthere details follow the URL :

http://www.cisco.com/en/US/docs/ios/12_3/termserv/command/reference/ter_a1g.html#wp998780

Yes, I did it.

But what i'm looking for is to execute a command not in a specific line but for a specific user.

I used it with the command user autocommand, but that don't work.

Regards,