Install the CORE Network Emulator from source code

To install the CORE network emulator in recently released Linux distributions, including Ubuntu 16.04 and later, I recommend that you install it from the CORE Github source code repository.

The Debian and Ubuntu maintainers will remove CORE packages from their repositories in the near future so we cannot install CORE using a package manager, anymore. We also cannot use the packages available on the CORE web site until a new version of CORE is released, because newer Linux distributions may break some of the functionality in the version of CORE packages available there. For example, CORE fails to start Quagga routing daemons in newer Linux distributions. The issue is fixed in the latest version of the CORE source code available on Github.

The CORE source code is in two places: on the CORE web site, and on Github. It’s not completely clear which source code repository we should use to build CORE from. I asked the CORE team about this and it seems that both are valid, but are not kept 100% in sync with each other. Since a recent fix I needed was on the CORE Github repository, but not in the CORE web site nightly snapshots source code folder, I will use the CORE GitHub repository.

In this post, I provide a detailed procedure to install CORE from the source code on Github, and to set up your system to run network experiments using the CORE network emulator.

NOTE: This post is a major update to an old post. The original version of this post was written in 2014. Since then, two new versions of CORE were released and the project source code moved to Github. So, I refreshed this post and set it to the top of my blog’s timeline (May 11, 2017).

Install CORE from Github

The latest version of CORE is available on Github. To install CORE, first install prerequisite packages that allow you to build the CORE system.

$ sudo apt-get update
$ sudo apt-get install git
$ sudo apt-get install bash bridge-utils ebtables \
  iproute libev-dev python tcl8.5 tk8.5 libtk-img \
  autoconf automake gcc libev-dev make python-dev \
  libreadline-dev pkg-config imagemagick help2man

Then, clone the CORE source code from Github and run the install scripts.

$ cd
$ git clone https://github.com/coreemu/core.git
$ cd core
$ ./bootstrap.sh
$ ./configure
$ make
$ sudo make install

Then, restart the system. For some reason the core_daemon service will not start unless you first restart the system.

To update CORE in the future

To get the latest patches and upgrade CORE, pull the latest version of CORE from Github and run the install scripts again.

$ cd
$ cd core
$ git pull
$ ./bootstrap.sh
$ ./configure
$ make
$ sudo make install        

Install network software

To perform experiments, we need to install the network services that may be run on the containers that emulate network nodes in CORE.

The following list of prerequisite software support CORE installation in Ubuntu Linux. For other Linux distributions, check the prerequisite software specified in the CORE installation documentation.

$ sudo apt-get install quagga quagga-doc \ 
  openssh-server isc-dhcp-server isc-dhcp-client \
  vsftpd apache2 tcpdump radvd at ucarp openvpn \
  ipsec-tools racoon traceroute mgen wireshark \
  iperf3 tshark snmpd snmptrapd openssh-client

Also, set up Wireshark so normal users can capture data.

$ sudo setcap 'CAP_NET_RAW+eip CAP_NET_ADMIN+eip' /usr/bin/dumpcap
$ sudo adduser $USER wireshark

The logout and login again to activate these changes.

Set up Quagga

We’ll do our first experiments using Quagga with OSPF so set up the Quagga daemon config files:

$ sudo touch /etc/quagga/zebra.conf
$ sudo touch /etc/quagga/ospfd.conf
$ sudo touch /etc/quagga/ospf6d.conf
$ sudo touch /etc/quagga/ripd.conf
$ sudo touch /etc/quagga/ripngd.conf
$ sudo touch /etc/quagga/isisd.conf
$ sudo touch /etc/quagga/pimd.conf
$ sudo touch /etc/quagga/vtysh.conf                        
$ sudo chown quagga.quaggavty /etc/quagga/*.conf
$ sudo chown quagga.quaggavty /etc/quagga/*.conf
$ sudo chmod 666 /etc/quagga/*.conf

Edit the Quagga daemons file.

$ sudo nano /etc/quagga/daemons  

The new file should look like the listing below

zebra=yes
bgpd=no
ospfd=yes
ospf6d=no
ripd=no
ripngd=no
isisd=no
babeld=no

Set up environment variables so we avoid the Quagga vtysh END problem in Ubuntu Linux.

$ sudo bash -c 'echo "export VTYSH_PAGER=more" >>/etc/bash.bashrc'
$ sudo bash -c 'echo "VTYSH_PAGER=more" >>/etc/environment'

Run CORE

To test that the CORE Network Emulator is working, start the CORE daemon and the GUI.

First, start the CORE daemon:

$ sudo service core-daemon start

You may encounter an error at this point, if you did not restart after you installed CORE. If you see the error that tells you the file core-daemon.service does not exist, restart your system. After restarting, try starting the core-daemon service, again.

Then, run the CORE GUI

$ core-gui

This launches the CORE GUI. Note that you do not run the GUI as root.

Support

If you have questions, comments, or trouble, please use the CORE mailing lists:

Users should use the core-users mailing list:

Developers should use the core-dev mailing list but also send bug reports to the Github issues list.

Conclusion

We successfully installed the CORE Network Emulator from source code using a procedure that should work in most Linux distributions.

6 thoughts on “Install the CORE Network Emulator from source code”

  1. Pingback: Quagga vtysh shell (END) problem | Open-Source Routing and Network Simulation

  2. For fedora, use the following package names to install supporting software:

    yum install bash bridge-utils ebtables \
    iproute libev python tcl tk tkimg tkimg-devel \
    autoconf automake gcc libev-devel make python-devel \
    readline readline-devel pkgconfig ImageMagick help2man

  3. Pingback: Install the CORE Network Emulator on Amazon AWS | Open-Source Routing and Network Simulation

Comments are closed.

Scroll to Top