Before we crank up the vppinfra memory leakfinder, etc. etc.: cat /proc/`pidof 
vpp`/maps and have a hard stare at the output.

Configure one step at a time, looking for significant changes in the address 
space layout.

HTH… Dave

From: vpp-dev-boun...@lists.fd.io [mailto:vpp-dev-boun...@lists.fd.io] On 
Behalf Of Luke, Chris
Sent: Tuesday, December 5, 2017 9:58 PM
To: 薛欣颖 <xy...@fiberhome.com>; vpp-dev <vpp-dev@lists.fd.io>
Subject: Re: [vpp-dev] memory issues

I agree 5g is large, but I do not think this is the FIB. The default heap maxes 
out much sooner than that. Something else is going on.

For DPDK, “show dpdk buffer” and otherwise “show physmem”.

Chris.

From: 薛欣颖 <xy...@fiberhome.com<mailto:xy...@fiberhome.com>>
Date: Tuesday, December 5, 2017 at 20:06
To: Chris Luke 
<chris_l...@cable.comcast.com<mailto:chris_l...@cable.comcast.com>>, vpp-dev 
<vpp-dev@lists.fd.io<mailto:vpp-dev@lists.fd.io>>
Subject: Re: Re: [vpp-dev] memory issues


Hi Chris,

I see what you mean. I have two other questions:
1. 200k static routing use 5g memory is also  large , how can I configure it 
use less physical memory?
2. How can I check the packet buffer memory?

BTW, do you have the test similar with 'the memory size 200k static routing 
use'?

Thanks,
Xyxue
________________________________

From: Luke, Chris<mailto:chris_l...@comcast.com>
Date: 2017-12-05 21:43
To: 薛欣颖<mailto:xy...@fiberhome.com>; vpp-dev<mailto:vpp-dev@lists.fd.io>
Subject: Re: [vpp-dev] memory issues
You’re misreading top. “Virt” only means the virtual memory footprint of the 
process. This includes unused heap, shared libraries, anonymous mmap() regions 
etc. “RSS” is the resident-in-memory size. It’s actually using 5G.

“show memory” also only shows the heap usage, it does not include packet buffer 
memory.

Chris.

From: <vpp-dev-boun...@lists.fd.io<mailto:vpp-dev-boun...@lists.fd.io>> on 
behalf of 薛欣颖 <xy...@fiberhome.com<mailto:xy...@fiberhome.com>>
Date: Tuesday, December 5, 2017 at 00:51
To: vpp-dev <vpp-dev@lists.fd.io<mailto:vpp-dev@lists.fd.io>>
Subject: [vpp-dev] memory issues


Hi guys,

I am using vpp v18.01-rc0~241-g4c9f2a8.
I configured 200K static routing. When I 'show memory' in VPP, '150+k used'. 
But in my machine ,used almost 15g. After del the static routing ,almost using 
16g memory.
More info is shown below:

VPP# show memory
Thread 0 vpp_main
heap 0x7fffb58e9000, 1076983 objects, 110755k of 151671k used, 15386k free, 
13352k reclaimed, 16829k overhead, 1048572k capacity
User heap index=0:
heap 0x7fffb58e9000, 1076984 objects, 110755k of 151671k used, 15386k free, 
13352k reclaimed, 16829k overhead, 1048572k capacity
User heap index=1:
heap 0x7ffff7ed4000, 2 objects, 128k of 130k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=2:
heap 0x7fffb1e28000, 2 objects, 512k of 514k used, 92 free, 0 reclaimed, 1k 
overhead, 8188k capacity
User heap index=3:
heap 0x7fffb1628000, 2 objects, 512k of 514k used, 92 free, 0 reclaimed, 1k 
overhead, 8188k capacity
User heap index=4:
heap 0x7fffaf628000, 2 objects, 512k of 514k used, 92 free, 0 reclaimed, 1k 
overhead, 32764k capacity
User heap index=5:
heap 0x7fffaf528000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=6:
heap 0x7fffaf428000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=7:
heap 0x7fffaf328000, 2 objects, 120k of 122k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=8:
heap 0x7fffaf228000, 2 objects, 120k of 122k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=9:
heap 0x7fffa7228000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 131068k capacity
User heap index=10:
heap 0x7fff9f228000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 131068k capacity
User heap index=11:
heap 0x7fff9b228000, 2 objects, 16k of 18k used, 92 free, 0 reclaimed, 1k 
overhead, 65532k capacity
User heap index=12:
heap 0x7fff9b028000, 2 objects, 256k of 258k used, 92 free, 0 reclaimed, 1k 
overhead, 2044k capacity
User heap index=13:
heap 0x7fff9ae28000, 2 objects, 240k of 242k used, 92 free, 0 reclaimed, 1k 
overhead, 2044k capacity
User heap index=14:
heap 0x7fff9ad28000, 5 objects, 8k of 10k used, 168 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=15:
heap 0x7fff9ac28000, 5 objects, 8k of 10k used, 168 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=16:
heap 0x7fff9ab28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=17:
heap 0x7fff9a128000, 2 objects, 1k of 3k used, 88 free, 0 reclaimed, 1k 
overhead, 10236k capacity
User heap index=18:
heap 0x7fff9a028000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=19:
heap 0x7fff99f28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=20:
heap 0x7fff99e28000, 2 objects, 2k of 4k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=21:
heap 0x7fff99d28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=22:
heap 0x7fff99c28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=23:
heap 0x7fff99b28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=24:
heap 0x7fff99a28000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=25:
heap 0x7fff99928000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 1020k capacity
User heap index=26:
heap 0x7fff97928000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 32764k capacity
User heap index=27:
heap 0x7fff95928000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 32764k capacity
User heap index=28:
heap 0x7fff94928000, 2 objects, 1k of 3k used, 92 free, 0 reclaimed, 1k 
overhead, 16380k capacity
User heap index=29:
heap 0x7fff92928000, 2 objects, 128k of 130k used, 92 free, 0 reclaimed, 1k 
overhead, 32764k capacity
User heap index=30:
heap 0x7fff90928000, 2 objects, 128k of 130k used, 92 free, 0 reclaimed, 1k 
overhead, 32764k capacity
User heap index=31:
heap 0x7fff8f928000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 16380k capacity
User heap index=32:
heap 0x7fff8e928000, 2 objects, 8k of 10k used, 92 free, 0 reclaimed, 1k 
overhead, 16380k capacity
User heap index=33:
heap 0x7fff83401000, 4 objects, 32k of 34k used, 120 free, 0 reclaimed, 1k 
overhead, 32764k capacity

User heap total: 1077059 objects, 113610k of 154594k used, 15389k free, 13352k 
reclaimed, 16893k overhead

After add routing:
top - 16:18:33 up  7:22,  3 users,  load average: 1.08, 0.78, 0.55
Tasks: 210 total,   2 running, 208 sleeping,   0 stopped,   0 zombie
%Cpu(s):  1.7 us,  1.8 sy,  0.0 ni, 96.3 id,  0.0 wa,  0.0 hi,  0.2 si,  0.0 st
KiB Mem:   6102468 total,  5936684 used,   165784 free,     3772 buffers
KiB Swap: 10482684 total,  9166080 used,  1316604 free.    45396 cached Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
14696 root      20   0 15.195g 5.279g  22712 S   3.3 90.7   8:24.99 vpp

After delete  routing:
top - 19:52:57 up 10:56,  3 users,  load average: 0.01, 0.04, 0.07
Tasks: 209 total,   1 running, 208 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.0 us,  0.2 sy,  0.0 ni, 99.8 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem:   6102468 total,  5950360 used,   152108 free,     9512 buffers
KiB Swap: 10482684 total, 10469928 used,    12756 free.    29488 cached Mem

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND
14696 root      20   0 16.468g 5.303g  19192 S   2.3 91.1  23:56.25 vpp

What should I do to release these memory?


Thanks,
Xyxue



________________________________
_______________________________________________
vpp-dev mailing list
vpp-dev@lists.fd.io
https://lists.fd.io/mailman/listinfo/vpp-dev

Reply via email to