linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrey Borzenkov <arvidjaar@mail.ru>
To: Rusty Russell <rusty@rustcorp.com.au>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] 2.6: races between modprobe and depmod in rc.sysinit
Date: Sat, 2 Aug 2003 01:22:55 +0400	[thread overview]
Message-ID: <200308020122.55169.arvidjaar@mail.ru> (raw)
In-Reply-To: <20030801064916.46F842C2B9@lists.samba.org>

[-- Attachment #1: Type: text/plain, Size: 1346 bytes --]

On Friday 01 August 2003 10:34, Rusty Russell wrote:
> In message <200307312145.01711.arvidjaar@mail.ru> you write:
> > the only reason I can imagine is that it hits depmod -A that runs in
> > rc.sysinit and does
> >
> > truncate /lib/modules/`uname -r`/modules.*
> > scan modules
> > write files
> >
> > So, quesitons
> >
> > - would anybody (Rusty?) object if I change depmod to do
> >   build temp name
> >   move temp name into original
>
> No, that's definitely my preferred method anyway: please send patch.
> Although I double this causes your problem here.
>

this does :) I have seen even more incredible races during boot recently. It 
affects other modules as well, like input loaded by hotplug triggered by USB 
load. depmod on current 2.6 takes some not negligible time.

anyway here is patch against 0.9.13-pre that makes depmod output in temp file 
and rename it after. It fixed the problem for sure for me (like commenting 
out depmod in rc.sysinit did but most people seem to object to it).

> > - Chmouel, Fred - is depmod on every boot really neccessary? When people
> > install modules they are expected to run it actually ...
>
> People get it wrong, and you still want them to boot.  Increasingly we
> can live without depmod though: I might fix this in a near-future
> version to live without it.
>

would be nice.

-andrey

[-- Attachment #2: module-init-tools-0.9.13-tempfile.patch.bz2 --]
[-- Type: application/x-bzip2, Size: 1681 bytes --]

  reply	other threads:[~2003-08-01 21:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-31 17:45 2.6: races between modprobe and depmod in rc.sysinit Andrey Borzenkov
2003-08-01  6:34 ` Rusty Russell
2003-08-01 21:22   ` Andrey Borzenkov [this message]
2003-08-02  0:29     ` [PATCH] " Rusty Russell
2003-08-08 21:19       ` Andrey Borzenkov

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=200308020122.55169.arvidjaar@mail.ru \
    --to=arvidjaar@mail.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rusty@rustcorp.com.au \
    /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).