Thanks Damjan. Yes, you are right. There is a lock on each session.
I encountered another issue on multithread mode:
(1).For one main thread and four worker threads, configuring 32K PPPoE sessions
works well.
Below is the ps output:
root@nsh-proxy:~# ps aux | grep vpp
root 55034 0.0 0.1 149560 101840 pts/8 Ss 18:01 0:00
/usr/bin/gdb --fullname
/root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp
root 55036 481 1.2 4171288 835296 pts/8 Sl+ 18:01 138:43
/root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp -c
/etc/vpp/startup.conf
(2). For one main thread and eight worker threads, configuring 32K PPPoE
sessions caused VPP crash!
In debug mode, indicates that OS ran out of memory. But my server still
had 50G free memory.
Below is the ps output:
root@nsh-proxy:~# ps aux | grep vpp
root 76018 0.1 0.1 158880 109496 pts/8 Ss+ 20:10 0:01
/usr/bin/gdb --fullname
/root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp
root 76038 757 1.6 3549408 1101620 pts/8 tl 20:10 160:48
/root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp -c
/etc/vpp/startup.conf
Could you give some clues on why this happens? Thanks in advance.
Below is the back trace when VPP crash:
root@nsh-proxy:~# ps aux | grep vpp
root 76018 0.1 0.1 158880 109496 pts/8 Ss+ 20:10 0:01 /usr/bin/gdb
--fullname /root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp
root 76038 757 1.6 3549408 1101620 pts/8 tl 20:10 160:48
/root/vpp/build-root/install-vpp_debug-native/vpp/bin/vpp -c
/etc/vpp/startup.conf
Thread 4 "vpp_wk_1" received signal SIGABRT, Aborted.
[Switching to Thread 0x7fff6ba41700 (LWP 76041)]
0x00007ffff6200428 in __GI_raise (sig=sig@entry=6) at
../sysdeps/unix/sysv/linux/raise.c:54
54 ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0 0x00007ffff6200428 in __GI_raise (sig=sig@entry=6) at
../sysdeps/unix/sysv/linux/raise.c:54
#1 0x00007ffff620202a in __GI_abort () at abort.c:89
#2 0x0000000000407e22 in os_panic () at
/root/vpp/build-data/../src/vpp/vnet/main.c:268
#3 0x00007ffff6a91b33 in os_out_of_memory () at
/root/vpp/build-data/../src/vppinfra/unix-misc.c:221
#4 0x00007ffff7934bd8 in clib_mem_alloc_aligned_at_offset (size=13891360,
align=1, align_offset=0, os_out_of_memory_on_failure=1) at
/root/vpp/build-data/../src/vppinfra/mem.h:105
#5 0x00007ffff7934c78 in clib_mem_alloc_aligned (size=13891360, align=1) at
/root/vpp/build-data/../src/vppinfra/mem.h:122
#6 0x00007ffff793b46b in vlib_worker_thread_node_refork () at
/root/vpp/build-data/../src/vlib/threads.c:1119
#7 0x00007ffff78f56b0 in vlib_worker_thread_barrier_check () at
/root/vpp/build-data/../src/vlib/threads.h:411
#8 0x00007ffff78fb32c in vlib_main_or_worker_loop (vm=0x7fffb6427050,
is_main=0) at /root/vpp/build-data/../src/vlib/main.c:1503
#9 0x00007ffff78fbf3a in vlib_worker_loop (vm=0x7fffb6427050) at
/root/vpp/build-data/../src/vlib/main.c:1647
#10 0x00007ffff793d4bf in vlib_worker_thread_fn (arg=0x7fffb5c4b0c0) at
/root/vpp/build-data/../src/vlib/threads.c:1733
#11 0x00007ffff6a096f4 in clib_calljmp () at
/root/vpp/build-data/../src/vppinfra/longjmp.S:110
#12 0x00007fff6ba40d60 in ?? ()
#13 0x00007ffff7938693 in vlib_worker_thread_bootstrap_fn (arg=0x7fffb5c4b0c0)
at /root/vpp/build-data/../src/vlib/threads.c:680
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
Thanks a lot,
Hongjun
From: Damjan Marion [mailto:[email protected]]
Sent: Tuesday, October 17, 2017 9:28 PM
To: Ni, Hongjun <[email protected]>
Cc: vpp-dev <[email protected]>
Subject: Re: [vpp-dev] Query on configuration on multithread mode
My wild guess here is that you are doing barrier sync on each session.With more
workers sync takes longer….
On 17 Oct 2017, at 08:56, Ni, Hongjun
<[email protected]<mailto:[email protected]>> wrote:
Hi vpp-dev,
We are doing performance test in multithread mode, and have a doubt:
(1). For one main thread and one worker thread, then configuring 16K PPPoE
sessions took about100 seconds.
(2). For one main thread and eight worker thread, then configuring 16K PPPoE
sessions took about260 seconds.
Why is there such a difference of consumed time?
The second question is:
In multi-thread mode, are all created tables in VLIB_INIT_FUNCTION (pppoe_init)
shared by all worker threads,
Or each worker thread has its own copy of each table?
Thanks a lot,
Hongjun
_______________________________________________
vpp-dev mailing list
[email protected]<mailto:[email protected]>
https://lists.fd.io/mailman/listinfo/vpp-dev
_______________________________________________
vpp-dev mailing list
[email protected]
https://lists.fd.io/mailman/listinfo/vpp-dev