linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: prevent deadlocks on an corrupt udev database
Date: Wed, 13 Oct 2004 22:29:28 +0000	[thread overview]
Message-ID: <20041013222928.GA5941@kroah.com> (raw)
In-Reply-To: <20041013220913.GA12896@vrfy.org>

On Thu, Oct 14, 2004 at 12:09:13AM +0200, Kay Sievers wrote:
> Here is the patch, that should prevent all of the known deadlocks with
> corrupt tdb databases we discovered.
> Thanks to Frank Steiner <fsteiner-mail@bio.ifi.lmu.de>, who tested all this
> endlessly with a NFS mounted /dev. The conclusion is, that udev will not work
> on filesystems without proper record locking, but we should prevent the
> endless loops anyway. This patch implements:
> 
> o recovery from a corrupted udev database. udev will continue
>   without database support now, instead of doing nothing. So the node should
>   be generated in any case, remove will obviously not work for custom names.
> 
> o added iteration limits to the tdb-code at the places we discovered endless
>   loops. In the case tdb tries to find more than 100.000 entries with the
>   same hash, we better give up :)
> 
> o prevent a {all_partitions} loop caused by corrupt db data
> 
> o log all tdb errors to syslog
> 
> o switch sleep() to usleep() cause we want to use alarm()

Applied, thanks.

Oh, I fixed the build error and warning when using klibc with this patch
too :)

thanks,

greg k-h


-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Linux-hotplug-devel mailing list  http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

      reply	other threads:[~2004-10-13 22:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-10-13 22:09 prevent deadlocks on an corrupt udev database Kay Sievers
2004-10-13 22:29 ` Greg KH [this message]

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=20041013222928.GA5941@kroah.com \
    --to=greg@kroah.com \
    --cc=linux-hotplug@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).