tests: Make test_per_application_leaks more robust master
authorKienan Stewart <kstewart@efficios.com>
Wed, 22 May 2024 14:45:08 +0000 (10:45 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 24 May 2024 15:29:29 +0000 (11:29 -0400)
commitfbedc3dceae917e81ae37d378bec0b6bf1304901
treed14cf4e76a4c743f06cef592a7f91f36b788b864
parentdcffe9462d11f9de5b441b801da5b2b7ae42c79a
tests: Make test_per_application_leaks more robust

Observed issue
==============

On some systems (e.g. sles15sp4, RHEL 7), test_per_application_leaks
would fail spuriously.

Cause
=====

When walking the the FDs in `/proc/XX/fds`, the symbolic links exist but
link to unlinked files. E.g.

```
lrwx------ 1 root root 64 May 22 14:49 /proc/83578/fd/58 -> '/dev/shm/shm-ust-consumer-83578 (deleted)'
```

Solution
========

The test has been modified to loop, waiting for the post-destroy shm
count to drop back to the post-start count. In the case of a failure,
the test will hang forever but doesn't fail spuriously.

Known drawbacks
===============

None.

Change-Id: Id3c8a9f6db83fe888e79b8f06cb8308b4d90da87
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
tests/regression/tools/live/test_per_application_leaks.py
This page took 0.025117 seconds and 4 git commands to generate.