Template File |
Top Previous Next |
Template File Location: Windows: C:\Program Files (x86)\Net-Sense\generic_send_cmds_template.txt Linux: /usr/local/net-sense/templates/generic_send_cmds_template.txt
############################################################ # Template file for generic_send_cmds script ############################################################
########################################################################## # This is the prompt that the user sees when trying to # login to a device and a Username/Login_name is required. # Some examples include "Username:" or "Login:" (case sensitive) # Note, this variable is not reference if a Username/login_name is not # used ########################################################################## set LOGIN_PROMPT "Login"
########################################################################## # The prompt that asks you for a first level password (case sensitive) ########################################################################## set PASSWORD_PROMPT "Password:"
########################################################################## # First level prompt character(s). This is the character(s) usually # following the device name when in 1st level access mode. An example # of a Cisco router is # NY-router1> # So the value of 1ST_LEVEL_PROMPT would be ">" # If there is a "space" after this character, the space must be included! # E.g. "# " ########################################################################## set 1ST_LEVEL_PROMPT ">"
########################################################################## # This is the command that will allow the device to send # data to the user terminal without prompting the user to enter "return" # or "space-bar" if more than one screen full of data is sent to the # user terminal. For Cisco devices, the the command # is "terminal length 0". # If this does not apply to your devices, then set this value to an empty # string. Example: # set TERM_LENGTH_ZERO_CMD "" ########################################################################## set TERM_LENGTH_ZERO_CMD "term len 0"
########################################################################## # The command that you would enter to go into a "priviledged" mode on the # the device. For some devices this concept does not apply as there # are multiple usernames/passwords for different levels of access # This variable will only be referenced if the "-ual 2" option is used # on the command line when running the script ########################################################################## set 2ND_LEVEL_ACCESS_CMD "enable"
########################################################################## # The prompt that asks you for the second level password. Again, this # would only apply if the "-ual 2" option is used on the command line # when running the script ########################################################################## set 2ND_LEVEL_PASSWORD_PROMPT "Password: "
########################################################################## # Second level prompt character(s). This is the character(s) usually # following the device name when in 2nd level access mode. An example # of a Cisco router is # NY-router1# # So the value of 2ND_LEVEL_PROMPT would be "#" # Again, this would only apply if the "-ual 2" option is used on # the command line when running the script # If there is a "space" after this character, the space must be included! # E.g. "# " ########################################################################## set 2ND_LEVEL_PROMPT "# "
########################################################################## # Exit Command for this device. This is the command that will immediately # log you off of the device. # Examples: exit, quit, logoff # If the variable EXIT_CMD is not defined, the default EXIT_CMD is "exit" ########################################################################## set EXIT_CMD "exit"
########################################################################## # This is a character or string that will be displayed if an invalid # command is sent to the device or the device rejects the command # The program will only look for this character/string starting # at the beginning of a line. # For example, on a Cisco device, if an errored command is entered, the # error message will be written on a new-line beginngin with the # percent character (%). # Cisco Example: # NY_router1>show junk # ^ # % Invalid input detected at '^' marker. # # us-ce3>
# # If you don't know what this error character/string is then make # this value something you know will never come up when entering # a command. For example, set it to "kdfjdkfjkj" # set ERROR_STRING "kdfjdkfjkj" ########################################################################## set ERROR_STRING "%" |