How to: Cisco IOS XRv in GNS3

By on 10 Jan 2017

Categories: Development Tech matters

Tags: , ,

17 Comments

Blog home

Whenever we provide training we ask participants for feedback on the quality and content of our training. We regularly get asked for enhanced hands-on modules for platforms that participants use in their workplace.

Cisco IOS XRv is one of the most popular platforms among network engineers. However, this platform is only available in high-end devices, which might not be available to all engineers. For this reason, engineers prefer to virtualize the OS and GNS3 is one of the most popular network simulators to do this.

GNS3 is based on Dynamips, Pemu/Qemu and Dynagen. Simulating Cisco IOS in GNS3 is pretty straightforward. Simulating the XR platform is not. But with new XRv image and a few tweaks, you can now run Cisco XR platform in GNS3.

In this post, I will explain in detail how you can run Cisco IOS XRv in GNS3.

Getting started

The Cisco IOS XRv Router is a Virtual Machine (VM)-based platform running 32-bit/ 64-bit IOS XR software with the QNX microkernel. This VM contains a single route processor (RP) with control plane functionality, and line card (LC) network interfaces with their associated functionality.

The software applications you’ll require are:

You’ll also need a Cisco IOS XRv Router image. During our lab exercises, we use iosxrv-demo-6.0.0.vmdk, which is free to use. The only limitation with using this is it has AAA hard coded users and a rate limit of 2 Mbps. See Cisco’s configuration guide for full features.

To download the image, visit https://upload.cisco.com/cgi-bin/swc/fileexg/main.cgi?CONTYPES=Cisco-IOS-XRv. Note: you’ll need a Cisco CCO account.

Step 1: IOS XRv working on VirtualBox

  1. Create a new VM

picture1

  1. For the VM choose:
    1. Name: rxv-1
    2. Type: Other
    3. Version: Other/Unknown (64-bit)

picture2

  1. For memory size choose at least 2GB (less than 2GB will lead to weird behaviour). In our labs we allocate 4GB.

picture3

  1. Use an existing virtual hard disk file and choose the image you just downloaded. Click Create.

picture4

  1. Now we need to change a couple of options. Go to Settings > System and disable Floppy & Optical. Go to the Audio tab and disable audio.
  2. Go to the Network tab and enable the first network adapter. This will be used for the management port.

picture5

For Adapter 1
Enable Network Adapter
Attached to: Bridged Adapter (Your Mgmt port will be statically addressed on your LAN)
Name: Your physical network adapter (WiFi or LAN interface)
Under Advanced option:
Adapter Type: Paravirtualized Network (virtio-net)
Promiscuous Mode: Allow All

  1. For rest of the Adapters choose the following options:

picture6

For Adapter 2 to 4
Enable Network Adapter
Attached to: Not attached
Under Advanced option:
Adapter Type: Paravirtualized Network (virtio-net)
Promiscuous Mode: Allow VMs

  1. Now clone the first VMs and make multiple copies.

picture7

Enable Reinitialize the MAC address of all network cards. Make a Full clone.

picture8

Step 2: Configure Cisco ISO XRv image in GNS3

  1. Open GNS3 and go to Edit > Preferences and from Virtual Machines menu, click New.

picture9

  1. This will start a new wizard. Select the VM that you have created in VirtualBox. Before you click Finish, go to Edit the VM and enable the following options.

picture10

Enable remote console
Start VM in headless mode

picture11

From the Network tab, increase the number of adapters to 8.

  1. After this, you will find a Cisco XRv image in the GNS3 device list. In our case, the name will be xrv-1. Drag this image to GNS3 dashboard.

picture12

  1. Build the topology and start the XRv IOS. Once it is started, right click on Device and click on Console.

picture13

While connecting make sure you start with e1, because e0 belongs to management ports
e0 is MgmtEth0/0/CPU0/0
e1 is GigabitEthernet0/0/0/0
e1 is GigabitEthernet0/0/0/1

e7 is GigabitEthernet0/0/0/6

  1.  Cisco XR image will take some time to load. During loading, it will give you the message “this (d)rp node is not ready or active for login /configuration”, which you can ignore. You can log in using a default username and password.
    For the demo image, the default username and password is cisco/cisco.

picture14

 

Now you have dropped into the XR console. Happy networking!

Rate this article

The views expressed by the authors of this blog are their own and do not necessarily reflect the views of APNIC. Please note a Code of Conduct applies to this blog.

17 Comments

  1. Juan Burga

    Hi.

    GDTR base address # 0xf
    Writing crashinfo done!

    Writing x86 kernel core file

    please you help, this error is show

    Reply
  2. Fakrul Alam

    Dear John,

    Could you please explain “cannot ping anything”? You can build topology in GNS3 and have necessary reachability. Please note that e0 is MgmtEth0.

    Reply
  3. john

    hi Fakrul,
    i followed the article, i am using linux mint 64 bit, gns 2,
    everything is fine until i need reachability, no pings, no nothing, routing protocols dont come up etc, i cant install the xr router into any topology as there is no rechability with any neighbors, it is dead,
    a lot of people are talking about this on google,
    i dont use e0,
    do you know what is happening?

    Reply
    1. Fakrul Alam

      Hi John,

      Right now I don’t have any platform with Linux mint 64 bit & GNS 2 and can’t test it. But I tried MacOS Sierra & Windows 10; both works.

      Thanks
      Fakrul

      Reply
  4. pungpond

    for those who has ping problem you can try delete and recreate the link between router.
    another solution is using command in windows command line under directory where virtualbox is installed.

    “VBoxManage controlvm XRv1 setlinkstate1 off”
    then followed by
    VBoxManage controlvm XRv1 setlinkstate1 on”
    ( note the XRv1 is the name of your VM in virtualbox. please change to match your setting)

    this work fine for me but we have to do it everytime restart the xrv VM

    Reply
  5. Rupesh Jain

    Hello,

    I am able to bringup the topology but unable to ping the xrv routers. xrv to other router reachability is fine.
    I tried all possible workaround suggested, deleted the link, virtual box commands as well. but nothing helped.
    “VBoxManage controlvm XRv1 setlinkstate1 off”
    then followed by
    VBoxManage controlvm XRv1 setlinkstate1 on”

    Reply
  6. Edgar R

    Hi Guys I’m using Oracle VM Virtualbox and GNS3 and facing the same issues, I can’t ping between routers and the protocos don’t coming up. I tried to off and on the interface from cli and doesn’t works.

    Also I’m using Windows 7 Pro (64 Bits), GNS 2.1.9.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

Top