Debugging vhost0 not created issues - ganeshahv/Contrail_SRE GitHub Wiki

Problem

vhost0 interface is not created

Symptom - 1

agent containers restarting

Solution1

Credits: https://www.thegeekdiary.com/centos-rhel-7-change-default-kernel-boot-with-old-kernel/

uname -a
awk -F\' '$1=="menuentry " {print $2}' /etc/grub2.cfg
grub2-set-default <correct_kernel index number>
grub2-mkconfig -o /boot/grub2/grub.cfg
reboot -h now

Solution2(upgrade the kernel and bring up the agent docker afresh)

yum upgrade kernel
init 6
docker stop vrouter_vrouter-agent_1
docker rm vrouter_vrouter-agent_1
cd /etc/contrail/vrouter/
docker-compose up -d
ifconfig
contrail-status

Symptom - 2 (This is for R2008 onwards and with DPDK)

INFO: start '/bin/taskset 1 /usr/bin/contrail-vrouter-dpdk --no-daemon  --socket-mem 1024 --vdev eth_bond_bond0,mode=4,xmit_policy=l23,socket_id=0,mac=3c:fd:fe:9e:55:d0,lacp_rate=0,slave=0000:03:00.0,slave=0000:03:00.1'
INFO: init vhost0... 1
Device "vhost0" does not exist.
2020-08-19 17:32:19,315 VROUTER: vRouter version: {"build-info": [{"build-time": "2020-08-18 05:31:37.768836", "build-hostname": "contrail-build-r2008-rhel-59-generic-20200817204509.novalocal", "build-user": "contrail-builder", "build-ver
sion": "2008"}]}
2020-08-19 17:32:19,315 VROUTER: DPDK version: DPDK 19.11.0
INFO: wait DPDK agent to run... 1
2020-08-19 17:32:19,336 VROUTER: Error configuring lcores: forwarding lcores should be more than 1
2020-08-19 17:32:19,336 VROUTER: Error updating EAL arguments

Solution

cd /etc/sysconfig/network-scripts/
vi ifcfg-vhost0

Change CPU_LIST to 0xf

ifdown vhost0
ifup vhost0