Re: GDB locks RPM database

Muhammad Umer via Gdb <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <SG2PR06MB29515EB55D73E53C4D428024CDB60@SG2PR06MB2951.apcprd06.prod.outlook.com>
Thank you Simon! This helps a lot.

Hopefully RedHat/Fedora folks can offer more insight.
________________________________
From: Simon Marchi <[email protected]>
Sent: Wednesday, May 20, 2020 7:48:44 AM
To: Sterling Augustine <[email protected]>; Muhammad Umer <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: GDB locks RPM database

On 2020-05-19 9:13 p.m., Sterling Augustine via Gdb wrote:
> On Tue, May 19, 2020 at 6:11 PM Muhammad Umer via Gdb <[email protected]>
> wrote:
>
>> But why take a lock? If the purpose is to get info about debug packages,
>> why not just query the package database using rpm command and get the
>> required information? Why is taking a lock necessary?
>>
>
>  Simon didn't implement the functionality, so you would have to ask redhat,
> or whomever it was that wrote the code. This is not a part of a normal gdb
> installation.

Indeed.  I peeked at the Fedora local patches, and this one seems to implement
that feature, using librpm

  https://src.fedoraproject.org/rpms/gdb/blob/master/f/gdb-6.6-buildid-locate-rpm.patch

So it's plausible that librpm takes a lock, and that lock wasn't cleaned up
(perhaps because of crash), but I can't know for sure.  Hopefully someone from
Red Hat / Fedora can help more.

Simon
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.