jerasure backend leaks memory on exit

Bug #1666674 reported by Kota Tsuyuzaki
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
liberasurecode
Fix Released
Undecided
Unassigned

Bug Description

Both jerasure_rs_vand and jerasure_rs_cauchy can leak the allocated memory at the exit as valgrind memory check can report it.

The allocated memory is at static area and it should happen only once (for a single thread case) because the area will be allocated only it's not yet so that I don't think it's problematic on the running processes like OpenStack Swift services. Therefore we can triage this bug only in liberasurecode (or perhaps +jerasure or +pyeclib?) world.

As described above, jerasure often touches memory allocated to the static area so we have to free it once we leave the process even if we don't allocate it intentionally.

On the perspective that the memory is at static area, we may have to consider the multithreading case (racing to allocate the memory) on either jerasure or liberasurecode (, or user client?).

Revision history for this message
Kota Tsuyuzaki (tsuyuzaki-kota) wrote :
description: updated
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to liberasurecode (master)

Reviewed: https://review.openstack.org/434696
Committed: https://git.openstack.org/cgit/openstack/liberasurecode/commit/?id=4ab1336cabe0c1f5d7fc18c21b78f5d21aca5b60
Submitter: Jenkins
Branch: master

commit 4ab1336cabe0c1f5d7fc18c21b78f5d21aca5b60
Author: Daniel Axtens <email address hidden>
Date: Thu Feb 16 17:16:28 2017 +1100

    jerasure: plug memory leaks

    Jerasure inits some global variables on init.
    We need to free them, or we'll leak memory.

    Partial-Bug: #1666674

    Change-Id: Ie7073738428a71910016e910a66dbd92ca98eb92
    Signed-off-by: Daniel Axtens <email address hidden>

Tim Burke (1-tim-z)
Changed in liberasurecode:
status: New → Fix Committed
Changed in liberasurecode:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.