cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
274
Views
0
Helpful
1
Replies

Alias Command on CSS11500

bs6825
Level 1
Level 1

To make things easier for my client I want to make an alias command to run the config synch script. The format of the command is:

alias usermode alias-name "command in double quotes"

this leads to my attempt at this:

alias superuser synchronize "script play commit_redundancy "172.16.2.2 -d -s" "

Notice the imbedded quotes? The CSS did and didn't like them. I have tried the normal things like using "" to represent an inbedded quote, no luck.

Anyone been there and done this?

Thanks in advance.

1 Reply 1

Gilles Dufour
Cisco Employee
Cisco Employee

I don't think you can have an alias using quote.

So, you have to get rid of the quote.

You could set the ip with the command

set REMOTE_IP "172.16.2.2"

save_profile

Then you could simply have an alias

alias superuser synchronize "script play commit_redundancy"

If you really need the options -d and -s, you could extract the commit_redundancy file [it's a text file] and in the function Check_Arguments replace the IF statement in order to always set -f and -d by default.

Then copy the script back to the CSS via ftp.

Gilles.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: