Re: seperate environments for different kernels

From: Rob (rpc_at_cafe4111.org)
Date: 05/30/04

  • Next message: Zoltan Boszormenyi: "bk-drm patch missing from 2.6.6-mm2 and later?"
    To: linux-kernel@vger.kernel.org
    Date:	Sun, 30 May 2004 01:12:44 -0500
    
    

    On Saturday 29 May 2004 09:13 pm, Younggyun Koh wrote:
    > Hi,
    >
    > i want to run linux 2.6.6 kernel, which needs upgrade of some system tools
    > such as module-init-tools and nfs-utils. but other guys using the same
    > machine with 2.4 kernel don't want me to upgrade them.
    >

    sorry, typo bug: that statement is actually
    [ `uname -r` == "2.x.x-this-script's-desired-version" ] || exit

    and since mod-init-tools are in /, you may need to actually replace them all
    with wrapper scripts which call up the right one, passing all command-line
    arguments to the real one... you install the 2.4 utils, move them all (i.e.,
    to *-2.4) then the same for 2.6, and make a script with the original name
    that calls the 2.6 binary when uname -r returns a 2.6 kernel, likewise with
    2.4, etc.

    even easier: you may be able to get away with this hack:

    mount --bind /some-dir/2.6-bin /bin
    mount --bind /some-dir/2.6-lib /lib
    mount --bind /some-dir/2.6-sbin /sbin
    mount --bind /some-dir/2.6-etc /etc
    and so on.

    do this in a script that starts with that statement above, so that only when
    *your* kernel runs, it maps over the 2.4 kit without touching it.

    -- 
    Rob Couto [rpc@cafe4111.org]
    computer safety tip: use only a non-conducting, static-free hammer.
    --
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at  http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at  http://www.tux.org/lkml/
    

  • Next message: Zoltan Boszormenyi: "bk-drm patch missing from 2.6.6-mm2 and later?"

    Relevant Pages

    • Re: [Patch] Support UTF-8 scripts
      ... exec is fast. ... > it is likely not for script files. ... This is distribution problem, not kernel problem. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: Problem spawning init from script
      ... On Fr, 2004-04-30 at 23:14, Denis Vlasenko wrote: ... Kernel does not like that. ... > Post your script. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: Probable module bug in linux-2.6.5-1.358
      ... On Thu, 2004-10-07 at 00:08, Richard B. Johnson wrote: ... > The attached script shows that an attempt to open a device ... > after its module was removed, will seg-fault the kernel. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: 1352 NUL bytes at the end of a page? (was Re: Assertion `s && s->tree failed: The sag
      ... > bad calling conventions and really nasty bugs). ... I ran the bk exerciser script for over an hour with 2.6.6-current ... noticed failture as a bk bug to LM on 4/15/04 if that helps with kernel versions. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: [PATCH] out-of-tree builds
      ... > Although I like the feature to build a kernel in a different directory a lot, ... > The following patch adds a configure script to the kernel. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)