NetConf CLI Simulation

  1. Table of Contents
  2. Overview
  3. This update package ships 2 device simulations of NETCONF YANG , suitable for applications based on Tail-f's ConfD library. Currently, only the mandatory SSH transport is supported.

  4. Prerequisites
  5. To run this simulation, you must have installed the following optional modules as documented in the online documentation:

    • TELNET
    • SSH
    • TFTP

    If you have not done so, use Protocol Wizard in MIMICview to install these optional modules.

    If you plan to record your own device's NETCONF, Tail-f's ConfD is recommended, which can be downloaded from this URL,

    To create the base SNMP device simulation you also need the MIMIC Recorder MIMICREC.

  6. Usage
  7. This Youtube video shows the first-time install and invocation:

    To run the simulation, invoke the File->Open menu from the MIMICView GUI, and select the cli-netconf.cfg file.

    Select the agent and change its IP addresses, if necessary. Start it using the Agent->Start menu item.

    After the agent starts completely and turns into green, you can test the CLI with a TELNET or SSH client.

    Agent 1 simulates IOS-XE version 17.1 , which responds with proper NETCONF YANG running configuration. Agent 2 is of IOS-XE version 15.4 , which gives NETCONF YANG exceptions.

    After the agent starts completely and turns into green, in a terminal, go to your ConfD installation area,

    $ cd /usr/local/confd/bin/
    $ # To get the running config
    $ ./netconf-console --host 10.1.10.19 --port 22 --user=lab --password=lab123 --get-config --db=running
    $ # it returns the full XML of running configuration
    

    To Change netconf TCP port from 22 to 830(the new default for Cisco devices)

    1. In MIMICview, Agent -> Configure -> SSH tab, change the port number to 830.

    2. In $MIMIC_PRIV_DIR/config/ssh.cfg , change 22 to 830 .

    3. Restart the simulated agent.

  8. Record your own device
  9. To get more YANG modeled objects you can record your own devices.

    Your NMS may parse XML with a set of YANG models. The set of yang models needs to be expanded to cover newer, previously unknown, XML contents that you record.

    Procedure to do the recording and create a new simulation:

    1. For example, if IOS-XE device is at 10.9.10.77, ConfD netconf-console is installed in /usr/local/confd/bin/ ,

      $ ./netconf-console --host 10.9.10.77 --port 22 --user lab --password=lab123  \
      --get-config --db=running > /tmp/running.xml
      

    2. On MIMIC host machine,

      $ export MIMIC_PRIV_DIR=~/mimic/
      $ mkdir -p $MIMIC_PRIV_DIR/data/sim/your-mimicrec-created-device/ios_fs/
      $ cp /tmp/running.xml $MIMIC_PRIV_DIR/data/sim/your-mimicrec-created-device/ios_fs/
      

    3. In MIMICview, Agent -> Configure, check TELNET and SSH, then in Agent -> Configure -> TELNET tab, select the cli_netconf.rul rule file, it will include the cli_netconf.mtcl script .

    4. Start the new simulation agent, run netconf-console program against the simulation. The running config output is identical to the real device.

  10. Compatibility
  11. Tail-f ConfDVersion 7.3
    IOS-XE Deviceversion 17 and higher

Copyright 2017 Gambit Communications Inc.