Yesterday I had moved on to try with R3.2 (so that’s why I couldn’t check or 
attach the content of “/var/log/contrail/contrail-vrouter-dpdk-stdout.log” file 
yesterday) ; but I faced some compilation error there so I reverted back to 
trunk (stable versions)
However this time, crash is not observed. It gives following error instead—

contrail@contrail-23:~/dev/contrail-installer$ /usr/bin/contrail-vrouter-dpdk 
--no-daemon --socket-mem 1024,1024
ERROR: this system does not support “SSE4_2”.
Please check that RTE_MACHINE is set correctly.

After debugging the root-cause of above issue, I found that in file 
“third_party/dpdk/mk/machine/native/rte.vars.mk”, following check (marked in 
red) is missing. I came to this conclusion because—


1.      On my setup, compiler doesn’t report SSE4_2 support

a.      checked with command “gcc -march=native -dM -E - < /dev/null | grep 
SSE4_2”



2.      File “/var/run/dmesg.boot” is not present

Based on above points and following code, “MACHINE_CFLAGS” will get set to 
“-march=corei7”

# on FreeBSD systems, sometimes the correct cputype is not picked up.
# To get everything to compile, we need SSE4.2 support, so check if that is
# reported by compiler. If not, check if the CPU actually supports it, and if
# so, set the compilation target to be a corei7, minimum target with SSE4.2
SSE42_SUPPORT=$(shell $(CC) -march=native -dM -E - < /dev/null | grep SSE4_2)
ifeq ($(SSE42_SUPPORT),)
  CPU_SSE42_SUPPORT=$(shell if [ -f /var/run/dmesg.boot ] ; then grep SSE4\.2 
/var/run/dmesg.boot ; fi)
  ifneq ($(CPU_SSE42_SUPPORT),)
    MACHINE_CFLAGS= -march=corei7
  endif
endif

Ref: http://dpdk.org/ml/archives/dev/2014-July/004053.html

So I added to the line above content as highlighted in RED. Recompiled DPDK 
library as well as contrail-vrouter-dpdk binary and tried to run it. However 
still same error is received


PS: I had tried with GDB with the generated core and it crashed on the 
following statement only. Cpu_core_mask value was 15, i.e. 0x0F. I tried 
changing it to some toher value but same result. If I set it as 0 then only it 
didn’t crash—

287        core_mask_count = __builtin_popcountll((unsigned long 
long)cpu_core_mask);

Br, Deepak

From: Rajagopalan Sivaramakrishnan [mailto:r...@juniper.net]
Sent: 06 April 2017 23:42
To: Deepak Tiwari <deepak.tiw...@aricent.com>; dev@lists.opencontrail.org
Subject: Re: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi Deepak,
    3.2 would be a better although the issue is probably due to provisioning 
not being complete.
Can you please send the log file? Also, did you try stepping through 
contrail-vrouter-dpdk in gdb?

Raja

From: Deepak Tiwari 
<deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>>
Date: Thursday, April 6, 2017 at 3:35 AM
To: Rajagopalan Sivaramakrishnan <r...@juniper.net<mailto:r...@juniper.net>>, 
"dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>" 
<dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>>
Subject: RE: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi Raja,

Yes, I had setup huge-pages through following commands—

cat /proc/meminfo
sysctl -w vm.nr_hugepages=2048
mount -t hugetlbfs nodev /mnt/huge/

Initially I had tried using taskset command only but when I got into this error 
I tried without taskset just in case… ☺

I was wondering if trunk/master branch (I am using last stable commits of trunk 
as current trunk is broken) works with DPDK enabled? Or should I try with R3.2 
branch

Br, Deepak

From: Rajagopalan Sivaramakrishnan [mailto:r...@juniper.net]
Sent: 06 April 2017 11:00
To: Deepak Tiwari 
<deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>>; 
dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>
Subject: Re: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi Deepak,
    Did you set up huge pages (in sysctl.conf or from the shell)? We usually 
spawn the vrouter-dpdk process using taskset to bind it to a specific
set of CPU cores, but the command line below should work, so I suspect it is 
not correctly provisioned. Can you please take a look at the logs in
/var/log/contrail/contrail-vrouter-dpdk-stdout.log for any clues?

Raja

From: Dev 
<dev-boun...@lists.opencontrail.org<mailto:dev-boun...@lists.opencontrail.org>> 
on behalf of Deepak Tiwari 
<deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>>
Date: Tuesday, April 4, 2017 at 5:02 AM
To: "dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>" 
<dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>>
Subject: Re: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi,

With reference to the original query about how to setup and provision, DPDK 
based vRouter, I have the contrail-vrouter-dpdk binary compiled.
Next in contrail.sh, I replaced the command to bring-up kernel based vrouter 
with the command to bring-up vrouter-dpdk binary—

/usr/bin/contrail-vrouter-dpdk –no-daemon –socket-mem 1024,1024

I also loaded the igb_uio and rte_kni modules and bound the NICs to DPDK

However the binary fails to come-up. All other contrail components came-up 
successfully except vrouter-agent because vrouter binary crashed and hence 
vrouter-agent couldn’t connect to it and it exits.

contrail@contrail-23:~/dev/contrail-installer$ /usr/bin/contrail-vrouter-dpdk 
--no-daemon --socket-mem 1024,1024
2017-04-04 17:21:52,196 VROUTER: vRouter/DPDK version: {"build-info": 
[{"build-time": "2017-04-04 09:06:01.548355", "build-hostname": "contrail-23", 
"build-user": "root", "build-version": "4.0.0.0"}]}
Illegal instruction (core dumped)
contrail@contrail-23:~/dev/contrail-installer$ gdb 
/usr/bin/contrail-vrouter-dpdk core
GNU gdb (Ubuntu 7.7.1-0ubuntu5~14.04.2) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/contrail-vrouter-dpdk...done.

warning: core file may not match specified executable file.
[New LWP 26874]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/contrail-vrouter-dpdk --no-daemon --socket-mem 
1024,1024'.
Program terminated with signal SIGILL, Illegal instruction.
#0  dpdk_core_mask_get (system_cpus_count=4) at vrouter/dpdk/dpdk_vrouter.c:287
287        core_mask_count = __builtin_popcountll((unsigned long 
long)cpu_core_mask);
(gdb) bt
#0  dpdk_core_mask_get (system_cpus_count=4) at vrouter/dpdk/dpdk_vrouter.c:287
#1  dpdk_argv_update () at vrouter/dpdk/dpdk_vrouter.c:491
#2  dpdk_init () at vrouter/dpdk/dpdk_vrouter.c:674
#3  main (argc=4, argv=0x7ffcc8e13668) at vrouter/dpdk/dpdk_vrouter.c:1162
(gdb)

Can anyone provide any clue on how do I proceed further?

Br, Deepak

From: Jakub Pavlik [mailto:jpav...@mirantis.com]
Sent: 20 March 2017 21:07
To: Deepak Tiwari <deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>>
Cc: dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>
Subject: Re: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi Deepak,

sorry put there oc311

root@ea05e1fe2291:/# apt-cache policy contrail-vrouter-dpdk-init
contrail-vrouter-dpdk-init:
  Installed: (none)
  Candidate: 3.1.1.x~20170317154826
  Version table:
     3.1.1.x~20170317154826 0
        500 http://apt-mk.mirantis.com/trusty/ nightly/oc311 amd64 Packages


Jakub

On Mon, Mar 20, 2017 at 1:54 PM, Deepak Tiwari 
<deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>> wrote:
Hi Paul,

Thanks for the response.
I checked the packages, but there I don’t see 'contrail-vrouter-dpdk-init' 
package there

Br, Deepak

From: Jakub Pavlik [mailto:jpav...@mirantis.com<mailto:jpav...@mirantis.com>]
Sent: 20 March 2017 15:51
To: Deepak Tiwari <deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>>
Cc: dev@lists.opencontrail.org<mailto:dev@lists.opencontrail.org>
Subject: Re: [opencontrail-dev] Need help in setting up vRouter in DPDK-enabled 
mode

Hi Deepak,

you can try our repository:

deb [arch=amd64] http://apt-mk.mirantis.com/trusty nightly mitaka oc3111

We have all those dpdk packages there.

jakub

On Mon, Mar 20, 2017 at 8:38 AM, Deepak Tiwari 
<deepak.tiw...@aricent.com<mailto:deepak.tiw...@aricent.com>> wrote:
Hi,

I have been trying to setup a single node development environment for Contrail 
with DPDK based vRouter. I am facing issues there and struggling to understand 
the overall process as I don’t find any online documentation in this regard. 
All information that I get is related to configuring DPDK based vRouter in 
binary-packages based setup. I would really appreciate if anyone out there can 
help me here

Following are the steps I followed—

Initially I followed contrail-installer guidelines as a reference—

https://github.com/Juniper/contrail-installer

Using above approach, though I was able to bring up a “Contrail + Devstack” 
setup up but it has vRouter installed as a Kernel module and no 
“contrail-vrouter-dpdk” binary is generated.

Therefore, I did following steps to generate a “contrail-vrouter-dpdk” binary—


1.      Downloaded dpdk code base (version 2.1) to “third_party/dpdk” folder

2.      Update packages.make to include CONTRAIL_VROUTER_DPDK in sources

3.      Some other tweaking in following files to get “countrail-vrouter-dpdk” 
binary compiled successfully

a.      /opt/stack/contrail/controller/src/config/utils/provision_vrouter.py,

b.      vRouter/SConscript,

c.      third_party/dpdk and vRouter/dpdk/ files

Thereafter taking reference from fabric-utils 
(contrail-fabric-utils\fabfile\tasks\install.py  and 
contrail-fabric-utils\fabfile\utils\install.py) files I get to the point where 
in ‘get_compute_pkgs’ routine, it tries to fetch 'contrail-vrouter-dpdk-init' 
package

However I am unable to locate this 'contrail-vrouter-dpdk-init' package 
anywhere.

Now I have two queries here—


1.      Is this package available online somewhere? And,

2.      Is there some other mechanism to Initialize/configure DPDK based 
vRouter on the compute node in development source based installation?

Br, Deepak
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for 
the use of the individual to whom it is addressed. It may contain privileged or 
confidential information and should not be circulated or used for any purpose 
other than for what it is intended. If you have received this message in error, 
please notify the originator immediately. If you are not the intended 
recipient, you are notified that you are strictly prohibited from using, 
copying, altering, or disclosing the contents of this message. Aricent accepts 
no responsibility for loss or damage arising from the use of the information 
transmitted by this email including damage from virus."

_______________________________________________
Dev mailing list
Dev@lists.opencontrail.org<mailto:Dev@lists.opencontrail.org>
http://lists.opencontrail.org/mailman/listinfo/dev_lists.opencontrail.org



--
Jakub Pavlik
+420 602 177 027<tel:+420%20602%20177%20027>
jpav...@mirantis.com<mailto:jpav...@mirantis.com>
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for 
the use of the individual to whom it is addressed. It may contain privileged or 
confidential information and should not be circulated or used for any purpose 
other than for what it is intended. If you have received this message in error, 
please notify the originator immediately. If you are not the intended 
recipient, you are notified that you are strictly prohibited from using, 
copying, altering, or disclosing the contents of this message. Aricent accepts 
no responsibility for loss or damage arising from the use of the information 
transmitted by this email including damage from virus."



--
Jakub Pavlik
+420 602 177 027
jpav...@mirantis.com<mailto:jpav...@mirantis.com>
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for 
the use of the individual to whom it is addressed. It may contain privileged or 
confidential information and should not be circulated or used for any purpose 
other than for what it is intended. If you have received this message in error, 
please notify the originator immediately. If you are not the intended 
recipient, you are notified that you are strictly prohibited from using, 
copying, altering, or disclosing the contents of this message. Aricent accepts 
no responsibility for loss or damage arising from the use of the information 
transmitted by this email including damage from virus."
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for 
the use of the individual to whom it is addressed. It may contain privileged or 
confidential information and should not be circulated or used for any purpose 
other than for what it is intended. If you have received this message in error, 
please notify the originator immediately. If you are not the intended 
recipient, you are notified that you are strictly prohibited from using, 
copying, altering, or disclosing the contents of this message. Aricent accepts 
no responsibility for loss or damage arising from the use of the information 
transmitted by this email including damage from virus."
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for 
the use of the individual to whom it is addressed. It may contain privileged or 
confidential information and should not be circulated or used for any purpose 
other than for what it is intended. If you have received this message in error, 
please notify the originator immediately. If you are not the intended 
recipient, you are notified that you are strictly prohibited from using, 
copying, altering, or disclosing the contents of this message. Aricent accepts 
no responsibility for loss or damage arising from the use of the information 
transmitted by this email including damage from virus."
_______________________________________________
Dev mailing list
Dev@lists.opencontrail.org
http://lists.opencontrail.org/mailman/listinfo/dev_lists.opencontrail.org

Reply via email to