[pacman-dev] Seeking help to report and resolve a pacman bug with parallel downloads

atn19 atn19 at protonmail.com
Sat Jun 12 15:45:14 UTC 2021


Hi all,
Using an up-to-date system, I have an issue since I have been using pacman 6 parallel downloads feature. When retrieving a large number of quite small files with a quite good bandwidth, it interrupts the downloads, fails, and I get the following error message: "failed to commit transaction (download library error)".
As a computer science student, I would like to find the root cause of this issue. I guess this is due to some critical race, as the issue disappears when parallel downloads are disabled.
As a first try, I have been following some wiki indications, building pacman with debug symbols. However, I was unable to pinpoint the bug with gdb, the log is very short with only creation and exits of the created threads.
Then, I have been building pacman-static, hoping to avoid some shared libraries issues. This did not work either.
This is likely due to the fact that I am not very experienced with gdb, especially with the use of shared libraries and/or threads.

I guess many people on this mailing-list could fix this bug, the only reason I did not report it yet is because I do not have any precise log.
In order to report it in a more precise way, I would like to have some indications.
Moreover, this could turn out to be quite instructive for me, and perhaps for others as I would like to add some indications to the wiki and/or other places.
If you have online resources to recommend, please do.

1. How should I use gdb to get complete traces, including those of the created threads?
2. I am so far not using breakpoints, I would only like to have the complete call graph, including those of the created threads. Is this a reasonable approach when trying to address a not-yet-narrowed-down bug, especially with shared libraries? Do I need some other tools, modifying LD_PRELOAD, etc?
3. What is the recommended way of handling symbols from several symbols tables?
4. Is there already some sanitizer such as TSAN in use for pacman development? If not, is this something planned, or are they reasons against using such tools?
5. Last but not least, many tests used in the PKGBUILD check function unexpectedly fail when I build pacman locally. Is this normal? If not, I can attach the log in another email, even though I guess it should be quite reproducible.
Any piece of advice about how to do such things, what is your usual workflow with gdb (and perhaps other debuggers), more generally what is your workflow to find the cause of bugs, would be of great help.
Thank you very much for all of the pacman development.

Best regards,
atn19


More information about the pacman-dev mailing list