Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Muhammad Umer <umer2834@hotmail.com>
To: Simon Marchi <simark@simark.ca>,
	"gdb@sourceware.org" <gdb@sourceware.org>
Subject: Re: GDB locks RPM database
Date: Wed, 20 May 2020 01:11:40 +0000	[thread overview]
Message-ID: <SG2PR06MB295166D1C8FBC060EA550DF0CDB60@SG2PR06MB2951.apcprd06.prod.outlook.com> (raw)
In-Reply-To: <970dd8cd-d548-b19c-accd-07871b1d9ea1@simark.ca>

Thank you for the reply Simon.

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?
________________________________
From: Simon Marchi <simark@simark.ca>
Sent: Wednesday, May 20, 2020 5:28:47 AM
To: Muhammad Umer <umer2834@hotmail.com>; gdb@sourceware.org <gdb@sourceware.org>
Subject: Re: GDB locks RPM database

Changing the list to gdb@.

On 2020-05-19 7:47 p.m., Muhammad Umer via Gdb-prs wrote:
>
> I hope you guys are safe and healthy.
> Not sure if this is the right way, but I had a query about GDB, if this isn't the right forum, please point me in the right direction.
> On my RHEL 7.7 machine, I was using a script that would attach GDB to a running process and collect it's stack trace. After a while, I needed to install a package on the system. I tried installing a package, but the yum command didn't work, it would just get stuck. I tried installing a package through rpm command and it would get stuck as well. I could see some locks on the RPM database, in /var/lib/rpm. I found out using "lslocks" that my GDB processes had locked the RPM database. I'm not sure why GDB would do that? Is it by default and is the desired behavior? If it is, under what conditions would GDB acquire a lock on the rpm database?
> Thank you.
>

I've never heard of this.  Can this be a RHEL-specific patch?

I'm guessing that GDB on RHEL might have a feature to locate debug info packages by querying
the package manager, and that's where it would take a lock.

Simon


  reply	other threads:[~2020-05-20  1:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <SG2PR06MB29510548426E2177D7C7BAAFCDB90@SG2PR06MB2951.apcprd06.prod.outlook.com>
2020-05-20  0:28 ` Simon Marchi
2020-05-20  1:11   ` Muhammad Umer [this message]
2020-05-20  1:13     ` Sterling Augustine
2020-05-20  2:48       ` Simon Marchi
2020-05-20  5:04         ` Muhammad Umer
2020-05-20  9:39           ` Jan Kratochvil
2020-05-20 14:11             ` Muhammad Umer
2020-05-20 14:34               ` Jan Kratochvil
2020-05-21  0:17                 ` Muhammad Umer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=SG2PR06MB295166D1C8FBC060EA550DF0CDB60@SG2PR06MB2951.apcprd06.prod.outlook.com \
    --to=umer2834@hotmail.com \
    --cc=gdb@sourceware.org \
    --cc=simark@simark.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox