Submit a ticketCall us

Bridging the ITSM Divide
Integrated help desk and remote support software for faster resolution

Join us on Wednesday, November 29, 2017 at 11 a.m. CT, as we discuss the benefits of effectively integrating your help desk software with remote support solutions to help increase the efficiency of IT administration, improve communication, and decrease mean time to resolution (MTTR) for IT issues of all sizes. This directly impacts end-user satisfaction and your business’ bottom line. Register Now.

Home > Success Center > Network Configuration Manager (NCM) > Download Multi Context Configs for Cisco ASA or Cisco FWSM

Download Multi Context Configs for Cisco ASA or Cisco FWSM

Table of contents

Updated September 20th, 2016


This procedure only applies to network devices that have multiple context with individual running configurations, and the IP address is not able to be added to NCM as a separate node.


All versions of NCM prior to NCM 7.4.x  For NCM 7.4 and after Click Here


  1. In Settings>NCM Settings>Configs , add a new Config Type for each context (for example Context1, Context2).

  1. Specify in your device template, how to switch to each context (see example below).
  2.  ${ConfigType} macro in the Reset Command.
  3. specify the RegEx value in the Reset command. Depending on your prompt settings, the value should be '#', '>', ']', etc.
  4. Avoid using ${ConfigType} macro in the DownloadConfig command. Make sure the command is the right one, e.g. "show configuration", "show running-config" and so forth.
  5. In the Command line defining the Context \ Config Type, defining the command, the Context name is case sensative
  6. The actual command may be different on different platforms. In this example, it is for a FWSM or an ASA with Multiple Contexts
  7. Because we have to flip logic in NCM to allow the changing of prompts, only able to receive either the running config or the startup config can be gathered for any context, to include the admin.


Device Template Example:

<Command Name="RESET" Value="${ConfigType}" RegEx="#" />

<Command Name="Context1" Value="command to switch to Context1"  />

<Command Name="Context2" Value="command to switch to Context2 "/>

<Command Name="DownloadConfig" Value="show configuration"/>

*** Note***

In the example above, the Words Context1 and Context2 need to be replaced with the actual Context  name as defined when creating the customized config type created in NCM.

Best practice would be the Config Type would be the actual Context name on the devices. 



When NCM downloads a configuration, the first command issued is the ‘Reset’ command defined in the device template.

The ${ConfigType} macros will be replaced by the appropriate switch context command, based on the config type selected for the dowload.

The context will be dynamically switched before the download command is executed.

When the context is changed, so is the prompt. In order to recognize the prompt, a regular expression (RegEx) must be used to ignore the variable part of the prompt.



Let’s assume the command mode prompt after login is : ASA#

  • After switching to Context1, the command mode prompt becomes ASA-Context1#.
  • After switching to Context2, the command mode prompt becomes ASA-Context2#.

The RegEx to use in the reset command should match the common portion of the prompt in both contexts. In this example this could be RegEx="#".


Last modified