sonic-net / sonic-sairedis

SAI object interface to Redis database, as used in the SONiC project
Other
57 stars 272 forks source link

after apply_view, use malloc_trim to release memory to system #1400

Open inspurSDN opened 4 months ago

inspurSDN commented 4 months ago

why I did: after warm-reboot with all vlan members, syncd use memory up to 1.8g, and can not reduce to its normal state. what I did: this come from the glibc behavior, in the main heap, it almost not release memory to system, in apply view, huge memory used for compare logic, and do not use it again. so I add malloc_trim to release it.

kcudnik commented 4 months ago

How many clan members are in your case ? How did you counted that memory ?