From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Wed, 13 Oct 2004 22:29:28 +0000 Subject: Re: prevent deadlocks on an corrupt udev database Message-Id: <20041013222928.GA5941@kroah.com> List-Id: References: <20041013220913.GA12896@vrfy.org> In-Reply-To: <20041013220913.GA12896@vrfy.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.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 , 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