Warning!

Make sure you are in root@pod01-srv2 during these steps.

Configure base Operating System on pod01-srv2

Step 1 - Configure HOSTS file for Name Resolution

Setting proper hostnames definition plays a key role in the setup of various components of Contiv There are three things that need to match for Contiv to properly operate. The first part is that the hostname is correct in the file /etc/hosts. The second is the environment variable HOSTNAME that is derived in the system. The third is the hostname definition in /etc/hostname.

pod01-srv2
1
# This is the copy group: 1
cat <<EOF > /etc/hosts 127.0.0.1 localhost localhost.localdomain 10.0.236.17 netmaster 10.0.236.49 pod01-srv2 pod01-srv2.ecatsrtpdmz.cisco.com EOF
pod01-srv2
2
# This is the copy group: 2
cat <<EOF > /etc/hostname pod01-srv2 EOF

Step 2 - Disable Network Manager Service and Enable Network

After we have modified the Hosts Name Resolution, we need to restart the network services in order to take effect the previous changes.

pod01-srv2
3
# This is the copy group: 3
systemctl disable NetworkManager.service systemctl stop NetworkManager.service systemctl mask NetworkManager.service chkconfig network on systemctl restart network

Step 3 - Disable FirewallD

In this step you will be disabling the FirewallD service in order to install Contiv.

pod01-srv2
4
# This is the copy group: 4
systemctl stop firewalld systemctl disable firewalld
pod01-srv2
5
# This is the copy group: 5
systemctl status firewalld
    # systemctl status firewalld
    firewalld.service - firewalld - dynamic firewall daemon
       Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
       Active: inactive (dead)
    

Now flush the iptables chains to ensure that everything has been cleaned up.

pod01-srv2
6
# This is the copy group: 6
iptables -F

Step 4 - Disable SELinux Enforcement

In this step you will be disabling SELinux enforcement. SELinux can operate in one of two modes:

pod01-srv2
7
# This is the copy group: 7
sudo setenforce 0
pod01-srv2
8
# This is the copy group: 8
sestatus
    [root@pod01-srv2 ~]# sestatus
    SELinux status:                 disabled  
    

Downloading and Upgrading software required for Contiv

In the following steps we will be downloanding some packages needed for Contiv to work properly. It is important to always check the required packages based in your version of code and system.

Step 5 - EPEL packages needed for Contiv

In the following steps we will be downloanding some packages needed for Contiv to work properly. It is important to always check the required packages based in your version of code and system.

pod01-srv2
9
# This is the copy group: 9
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm rpm -Uvh epel-release-latest-7.noarch.rpm

Step 6 - Packages needed for Contiv

pod01-srv2
10
# This is the copy group: 10
yum -y install bzip2 sudo easy_install pip pip install netaddr yum -y install python2-crypto.x86_64 yum -y install python2-paramiko

Step 7- Upgrade system packages

Upgrade all the packages from the original ISO PXEBOOT install disk.

pod01-srv2
11
# This is the copy group: 11
yum makecache yum -y upgrade

Interface Configuration

Step 8- Enable Interface

During this step we will enable the interface that connects to the ACI fabric

pod01-srv2
12
# This is the copy group: 12
ip a

[root@pod01-srv2 ~]# ip a
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0:  mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:50:56:0c:01:04 brd ff:ff:ff:ff:ff:ff
    inet 10.0.236.49/24 brd 10.0.236.255 scope global dynamic eth0
       valid_lft 320sec preferred_lft 320sec
    inet6 fe80::250:56ff:fe0c:104/64 scope link
       valid_lft forever preferred_lft forever
3: eth1:  mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
    link/ether 00:50:56:8c:42:0d brd ff:ff:ff:ff:ff:ff
    

Step 8 - Change the physical interface states to operational.

pod01-srv2
13
# This is the copy group: 13
ifconfig eth1 up

Step 9 - Restart network stack to activate interface.

pod01-srv2
14
# This is the copy group: 14
systemctl restart network

Step 10 - Check status of interfaces after network restart.

Using the command ip a we can see the status of the uplink interfaces that have been defined.

pod01-srv2
15
# This is the copy group: 15
ip a
[root@pod01-srv2 ~]#ip a
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0:  mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:50:56:0c:01:03 brd ff:ff:ff:ff:ff:ff
    inet 10.0.236.17/24 brd 10.0.236.255 scope global dynamic eth0
       valid_lft 544sec preferred_lft 544sec
    inet6 fe80::250:56ff:fe0c:103/64 scope link
       valid_lft forever preferred_lft forever
3: eth1:  mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:50:56:8c:2e:a5 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::250:56ff:fe8c:2ea5/64 scope link
       valid_lft forever preferred_lft forever
    
© Copyright Cisco Systems 2017