Re: [vpp-dev] question about reverting a change

2021-02-08 Thread Matthew Smith via lists.fd.io
On Mon, Feb 8, 2021 at 4:44 PM Matthew Smith via lists.fd.io  wrote:

> Hi all,
>
> I reviewed and submitted this change earlier today -
> https://gerrit.fd.io/r/c/vpp/+/31162. After it was merged, the jenkins
> job 'vpp-merge-master-ubuntu1804-x86_64' failed because two tests failed.
> The two failed tests seem related to the change so I created a new change
> to revert the earlier one - https://gerrit.fd.io/r/c/vpp/+/31178. The
> checkstyle job failed for the revert because the original patch removed
> some pre-existing '/* INDENT-(ON|OFF) */' so the revert adds them back in.
> It seems that checkstyle doesn't like that.
>
> My question is should I try to fix the checkstyle errors or just
> remove the -1 that jenkins set on the change and merge it as is? I don't
> know if doing the latter will cause checkstyle to continue complaining
> about INDENT-(ON|OFF) whenever someone submits a new change. It's somewhat
> easy to fix those errors, but then my "revert" would not be actually
> restoring the original code. Maybe that doesn't matter?
>
> Anyway, I'm trying to get the tests passing again while causing the least
> possible amount of pain and/or confusion to others. If anyone has a strong
> opinion on which option is better, I'd love to hear it.
>
> Thanks!
> -Matt
>
>
 I started to look into fixing the INDENT-(ON|OFF) that the checkstyle job
complained about with the reverted change (31178). When I ran checkstyle.sh
locally, it complained about many other formatting issues besides INDENT-ON
and INDENT-OFF. If I fixed them all, the "reverted" code would have looked
significantly different than the original code, which seems wrong. So I
just removed the jenkins -1 verify score and set it to +1 manually and
merged it.

-Matt

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18702): https://lists.fd.io/g/vpp-dev/message/18702
Mute This Topic: https://lists.fd.io/mt/80491116/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[vpp-dev] Make test failures on ubuntu-20.04 AARCH64

2021-02-08 Thread Dave Wallace

Folks,

There are a number of VPP make test jobs that are failing when running 
on ubuntu-20.04 AARCH64. I am testing the [promoted] 
vpp-verify-master-ubuntu2004-aarch64 job [0] in the jenkins sandbox 
against the VPP gerrit change [1] which changes the default 'make 
verify' OS to ubuntu-20.04.  Andrew & I have also enhanced the CI post 
build scripts to dump the VPP stacktrace instead of archiving the core 
file [2] which is also applied to the sandbox test jobs.  This can be 
found both in the console output as well as in the 'make test' FAILED 
archive directory in the file 'core.stacktrace.gz'


All of the production 'make test' testcases passed on X86_64 [3].
I have included the list of FAILED make test testcases below from the 
logs archive [4] of the test run.
Note: If there are less than 4 FAILED testcases in the archive then the 
test is failing intermittently and passed on a subsequent retry.


Please investigate and report back at your earliest convenience for any 
feature that you maintain.  These failures are holding up the deployment 
of [1] which will complete the change to ubuntu-20.04 as the primary VPP 
OS distro.


Thanks,
-daw-

[0] 
https://jenkins.fd.io/sandbox/job/daw_30773_31019-vpp-verify-master-ubuntu2004-aarch64/

[1] https://gerrit.fd.io/r/c/vpp/+/30734
[2] https://gerrit.fd.io/r/c/ci-management/+/31019
[3] 
https://jenkins.fd.io/sandbox/job/daw_30773_31019-vpp-verify-master-ubuntu2004-x86_64

https://logs.fd.io/sandbox/vex-yul-rot-jenkins-2/daw_30773_31019-vpp-verify-master-ubuntu2004-x86_64/4/
[4] 
https://logs.fd.io/sandbox/vex-yul-rot-jenkins-2/daw_30773_31019-vpp-verify-master-ubuntu2004-aarch64/4/

    vpp-unittest-QUICEchoIntMStreamTestCase-f5ywwo0l-FAILED
    vpp-unittest-TestBihash-_iohsbtr-FAILED
    vpp-unittest-TestInitiatorDelSAFromResponder-dgqdg78o-FAILED
    vpp-unittest-TestInitiatorKeepaliveMsg-0vo66yj2-FAILED
    vpp-unittest-TestInitiatorNATT-edyneyju-FAILED
    vpp-unittest-TestInitiatorPsk-m3vrysyi-FAILED
    vpp-unittest-TestInitiatorRekey-7lrb0f8t-FAILED
    vpp-unittest-TestInitiatorRequestWindowSize-4y4stlww-FAILED







-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18701): https://lists.fd.io/g/vpp-dev/message/18701
Mute This Topic: https://lists.fd.io/mt/80495347/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[vpp-dev] question about reverting a change

2021-02-08 Thread Matthew Smith via lists.fd.io
Hi all,

I reviewed and submitted this change earlier today -
https://gerrit.fd.io/r/c/vpp/+/31162. After it was merged, the jenkins job
'vpp-merge-master-ubuntu1804-x86_64' failed because two tests failed. The
two failed tests seem related to the change so I created a new change to
revert the earlier one - https://gerrit.fd.io/r/c/vpp/+/31178. The
checkstyle job failed for the revert because the original patch removed
some pre-existing '/* INDENT-(ON|OFF) */' so the revert adds them back in.
It seems that checkstyle doesn't like that.

My question is should I try to fix the checkstyle errors or just remove
the -1 that jenkins set on the change and merge it as is? I don't know if
doing the latter will cause checkstyle to continue complaining about
INDENT-(ON|OFF) whenever someone submits a new change. It's somewhat easy
to fix those errors, but then my "revert" would not be actually restoring
the original code. Maybe that doesn't matter?

Anyway, I'm trying to get the tests passing again while causing the least
possible amount of pain and/or confusion to others. If anyone has a strong
opinion on which option is better, I'd love to hear it.

Thanks!
-Matt

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18700): https://lists.fd.io/g/vpp-dev/message/18700
Mute This Topic: https://lists.fd.io/mt/80491116/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[vpp-dev] Minor api change in policer

2021-02-08 Thread Brian Russell
Hi all,

I’ve been consolidating the policer to use the common ip definitions for DSCP 
in its marking parameters rather than having its own duplicates. As part of 
that I tried a minor change to the .api:

diff --git a/src/vnet/policer/policer_types.api b/src/vnet/policer/policer_types
.api
index d48dc646e..2377790bf 100644
--- a/src/vnet/policer/policer_types.api
+++ b/src/vnet/policer/policer_types.api
@@ -14,6 +14,8 @@
  */
 option version = "1.0.0";
 
+import "vnet/ip/ip_types.api";
+
 enum sse2_qos_rate_type : u8
 {
   SSE2_QOS_RATE_API_KBPS = 0,
@@ -53,7 +55,7 @@ enum sse2_qos_action_type : u8
 typedef sse2_qos_action
 {
   vl_api_sse2_qos_action_type_t type;
-  u8 dscp;
+  vl_api_ip_dscp_t dscp;
 };


The dscp api type is

enum ip_dscp : u8 {
  IP_API_DSCP_CS0 =  0,
  IP_API_DSCP_CS1 = 8,
  IP_API_DSCP_AF11 = 10,
etc


so it ought to be ok but ...

modified: ** policer_add_del
modified: ** policer_details
crcchecker: Changing production APIs in an incompatible way
make: *** [Makefile:643: checkstyle-api] Error 255

Is this a bug in the checkstyle-api script?

Thanks,

Brian
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18698): https://lists.fd.io/g/vpp-dev/message/18698
Mute This Topic: https://lists.fd.io/mt/80483218/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [vpp-dev] Vpp is not routing packages when LACP is configured

2021-02-08 Thread Marcos - Mgiga
Thanks, I did what you suggested and I've found that it occurs When I set
the following parameters:

set interface nat44 in BondEthernet1 out BondEthernet0

Is there a problem for VPP routing packets When nat is enable?

Best regards



-Mensagem original-
De: vpp-dev@lists.fd.io  Em nome de Benoit Ganne
(bganne) via lists.fd.io
Enviada em: segunda-feira, 8 de fevereiro de 2021 05:35
Para: Marcos - Mgiga ; 'vpp-dev' 
Assunto: Re: [vpp-dev] Vpp is not routing packages when LACP is configured

Hi Marcos,

I'd suggest to use the packet tracer to see what is going-on. The basic flow
should be:
~# vppctl trace add  50

~# vppctl show trace
With  depending upon the driver you use:
 - dpdk-input for DPDK
 - avf-input for AVF
 - rdma-input for RDMA (Mellanox)
 - others (af_xdp-input, virtio-input...) depending upon your config If VPP
receives traffic and drops it, it will certainly tell you where and why.

Also check for errors in "show errors" and "show log".

Best
ben

> -Original Message-
> From: vpp-dev@lists.fd.io  On Behalf Of Marcos - 
> Mgiga
> Sent: vendredi 5 février 2021 20:33
> To: 'vpp-dev' 
> Subject: [vpp-dev] Vpp is not routing packages when LACP is configured
> 
> Hello VPP experts,
> 
> 
> 
> I have a peculiar case, When I use LACP links between VPP Server and 
> two switches ( see image bellow) vpp is not forwarding any packages 
> from router A to router B(and vice versa). If I remove LACP and adjust 
> addressing and routing everything works fine.
> 
> 
> 
> What do you suggest for me to find what is going on? I would like to 
> highlitght that connectivity between VPP and routers its ok, including 
> When it uses LACP. I tried VPP v20.09-release and v20.05-release, and 
> OS is Centos 7.8
> 
> 
> 
> 
> 
> 
> 
> Best Regards



-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18696): https://lists.fd.io/g/vpp-dev/message/18696
Mute This Topic: https://lists.fd.io/mt/80414840/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [vpp-dev] vlib_put_frame_to_node to udp-encap causes main-thread crash

2021-02-08 Thread Dave Barach
I’m in the process of adding a few ASSERTs() to catch this issue. Stay tuned...

 

D.

 

From: PRANAB DAS  
Sent: Sunday, February 7, 2021 1:40 PM
To: v...@barachs.net
Cc: vpp-dev@lists.fd.io
Subject: Re: [vpp-dev] vlib_put_frame_to_node to udp-encap causes main-thread 
crash

 

Thanks Dave, it was a rookie mistake. 

Is there a way to turn on VNET debug flags to detect these kinds of errors?

 

Thank you very much.

 

- Pranab K Das

 

 

On Sat, Feb 6, 2021 at 6:24 AM mailto:v...@barachs.net> > 
wrote:

Make sure that vm = vlib_mains [thread_index], not vm = vlib_mains[0] = 
_global_main. 

 

>From what you wrote, I suspect that’s the problem.

 

D. 

 

From: vpp-dev@lists.fd.io   mailto:vpp-dev@lists.fd.io> > On Behalf Of PRANAB DAS
Sent: Friday, February 5, 2021 7:38 PM
To: vpp-dev@lists.fd.io  
Subject: [vpp-dev] vlib_put_frame_to_node to udp-encap causes main-thread crash

 

Hi

 

I am puzzled by the crash in the main-thread caused by the following code 
snippet that I have used to send control message payload over a udp encap 
tunnel. The udp encap tunnel is created using udp encap vppcli. The code below 
works when only a few packets are sent. But when I tried to send a burst of 
these messages, for instance in a for loop with count 10 it causes a crash on 
the main-thread even though the call is made on a worker thread.  

 

Really appreciate it you could provide some information how to debug this.

 

Thank you

 

if (vlib_buffer_alloc (vm, , 1) != 1)
{
return -1;
}

b0 = vlib_get_buffer (vm, bi0);

udp4_encap_node = vlib_get_node_by_name(vm, (u8 *) "udp4-encap");
dp4_encap_node_index=udp4_encap_node->index;

vnet_buffer(b0)->sw_if_index[VLIB_RX] = 0;
vnet_buffer(b0)->ip.adj_index[VLIB_TX] = 0; // udp encap tunnel created with 
index 0

vlib_frame_t *f = vlib_get_frame_to_node(vm, udp4_encap_node_index);
u32 *to_next = vlib_frame_vector_args(f);
to_next[0] = bi0;
f->n_vectors = 1;
vlib_put_frame_to_node(vm, udp4_encap_node_index, f);

 

This is the back trace. I don't understand how vlib_put_frame_to_node on a 
worker thread can trigger a crash on the main thread. Is it caused by some 
corruption ?



Thread 1 "vpp_main" received signal SIGSEGV, Segmentation fault.
dispatch_pending_node (vm=vm@entry=0x7f55e8b94300 , 
pending_frame_index=pending_frame_index@entry=3, 
last_time_stamp=510933815354328)
at /usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/main.c:1500
1500  nf->flags |= VLIB_FRAME_IS_ALLOCATED;
(gdb) bt
#0  dispatch_pending_node (vm=vm@entry=0x7f55e8b94300 , 
pending_frame_index=pending_frame_index@entry=3, 
last_time_stamp=510933815354328)
at /usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/main.c:1500
#1  0x7f55e8938bf6 in vlib_main_or_worker_loop (is_main=1, 
vm=0x7f55e8b94300 )
at /usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/main.c:2013
#2  vlib_main_loop (vm=0x7f55e8b94300 ) at 
/usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/main.c:2141
#3  vlib_main (vm=, vm@entry=0x7f55e8b94300 , 
input=input@entry=0x7f55a7fd6fa0)
at /usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/main.c:2387
#4  0x7f55e8978c46 in thread0 (arg=140006953403136) at 
/usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/unix/main.c:673
#5  0x7f55e80243dc in clib_calljmp () from /lib64/libvppinfra.so.20.05.1
#6  0x7ffd742d0920 in ?? ()
#7  0x7f55e8979ced in vlib_unix_main (argc=, argv=)
at 
/usr/src/debug/vpp-20.05.1-2~gcb5420544_dirty.x86_64/src/vlib/unix/main.c:745


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18695): https://lists.fd.io/g/vpp-dev/message/18695
Mute This Topic: https://lists.fd.io/mt/80421445/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [vpp-dev] NAT44 how to control external address assignment from pool?

2021-02-08 Thread Юрий Иванов
Just an update, to perform manual translation we should do:

det44 plugin enable
det44 add in 10.0.1.0/29 out 1.0.0.7/32
det44 add in 10.0.1.16/29 out 1.0.0.5/32
...
set interface det44 inside GigabitEthernet0/5/0 outside GigabitEthernet0/4/0

Ignoring specific nat configuration.

Nevertheless, maybe there is some option to select different IP addres from 
pool?

От: vpp-dev@lists.fd.io  от имени Юрий Иванов 

Отправлено: 7 февраля 2021 г. 12:10
Кому: vpp-dev@lists.fd.io 
Тема: [vpp-dev] NAT44 how to control external address assignment from pool?

Hi,

I've got basic nat setup in a lab which works as expected except extarnat IP 
address allocation.

My clients, behind NAT, has addresses:
vpp# show ip neighbors
Time   IPFlags  Ethernet
  Interface
   1421.592910.0.1.30  D00:50:79:66:68:00 
GigabitEthernet0/5/0
   1424.360910.0.1.55  D00:50:79:66:68:02 
GigabitEthernet0/5/0
   1423.165010.0.1.41  D00:50:79:66:68:01 
GigabitEthernet0/5/0
   1389.292910.0.1.20  D00:50:79:66:68:04 
GigabitEthernet0/5/0
   1377.144910.0.1.2   D00:50:79:66:68:03 
GigabitEthernet0/5/0

All can reach external 1.0.0.2 IP which looks good, but for all client external 
address is 1.0.0.100 (the last IP in a range).
I think it will be more better to randomly select different address in range 
like nftables do with this configuration stranza:
"ip saddr 10.0.0.0/8 oif "vlan2" snat to 1.0.0.2-1.0.0.100 persistent"

After changing
vpp# nat addr-port-assignment-alg map-e psid 10 psid-offset 6 psid-len 6
the only difference that external address become 1.0.0.1 for all clients.

I of cource can map host to external address with:
vpp# nat44 add static mapping  local 10.0.1.2 external 1.0.0.10
But with 30 thousands clients it will very strange idea to map every host route 
manually.

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18694): https://lists.fd.io/g/vpp-dev/message/18694
Mute This Topic: https://lists.fd.io/mt/80449794/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [vpp-dev] Vpp is not routing packages when LACP is configured

2021-02-08 Thread Benoit Ganne (bganne) via lists.fd.io
Hi Marcos,

I'd suggest to use the packet tracer to see what is going-on. The basic flow 
should be:
~# vppctl trace add  50

~# vppctl show trace
With  depending upon the driver you use:
 - dpdk-input for DPDK
 - avf-input for AVF
 - rdma-input for RDMA (Mellanox)
 - others (af_xdp-input, virtio-input...) depending upon your config
If VPP receives traffic and drops it, it will certainly tell you where and why.

Also check for errors in "show errors" and "show log".

Best
ben

> -Original Message-
> From: vpp-dev@lists.fd.io  On Behalf Of Marcos -
> Mgiga
> Sent: vendredi 5 février 2021 20:33
> To: 'vpp-dev' 
> Subject: [vpp-dev] Vpp is not routing packages when LACP is configured
> 
> Hello VPP experts,
> 
> 
> 
> I have a peculiar case, When I use LACP links between VPP Server and two
> switches ( see image bellow) vpp is not forwarding any packages from
> router A to router B(and vice versa). If I remove LACP and adjust
> addressing and routing everything works fine.
> 
> 
> 
> What do you suggest for me to find what is going on? I would like to
> highlitght that connectivity between VPP and routers its ok, including
> When it uses LACP. I tried VPP v20.09-release and v20.05-release, and OS
> is Centos 7.8
> 
> 
> 
> 
> 
> 
> 
> Best Regards


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18693): https://lists.fd.io/g/vpp-dev/message/18693
Mute This Topic: https://lists.fd.io/mt/80414840/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-