From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org)
	by finch.gentoo.org with esmtp (Exim 4.60)
	(envelope-from <gentoo-user+bounces-136149-garchives=archives.gentoo.org@lists.gentoo.org>)
	id 1S71XJ-0007m2-0I
	for garchives@archives.gentoo.org; Mon, 12 Mar 2012 09:27:25 +0000
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id C474FE0BD5;
	Mon, 12 Mar 2012 09:27:06 +0000 (UTC)
Received: from mail.muc.de (colin.muc.de [193.149.48.1])
	by pigeon.gentoo.org (Postfix) with ESMTP id 432E2E0BB6
	for <gentoo-user@lists.gentoo.org>; Mon, 12 Mar 2012 09:25:29 +0000 (UTC)
Received: (qmail 40231 invoked by uid 3782); 12 Mar 2012 09:25:28 -0000
Received: from acm.muc.de (pD951A9A0.dip.t-dialin.net [217.81.169.160]) by
	colin.muc.de (tmda-ofmipd) with ESMTP;
	Mon, 12 Mar 2012 10:25:27 +0100
Received: (qmail 3240 invoked by uid 1000); 12 Mar 2012 09:24:32 -0000
Date: Mon, 12 Mar 2012 09:24:32 +0000
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Beta test Gentoo with mdev instead of udev;
	version 5 - failure :-(
Message-ID: <20120312092432.GA2959@acm.acm>
References: <20111115062115.GA3262@waltdnes.org>
	<20111121104724.GC7461@waltdnes.org>
	<20111201194544.GD4455@waltdnes.org>
	<20120217234045.GA25390@waltdnes.org>
	<20120311090912.GA23850@waltdnes.org>
Precedence: bulk
List-Post: <mailto:gentoo-user@lists.gentoo.org>
List-Help: <mailto:gentoo-user+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-user+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-user+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-user.gentoo.org>
X-BeenThere: gentoo-user@lists.gentoo.org
Reply-to: gentoo-user@lists.gentoo.org
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <20120311090912.GA23850@waltdnes.org>
User-Agent: Mutt/1.5.21 (2010-09-15)
X-Delivery-Agent: TMDA/1.1.12 (Macallan)
From: Alan Mackenzie <acm@muc.de>
X-Primary-Address: acm@muc.de
X-Archives-Salt: 1482526f-fe0c-4c26-8fc0-08d09789b85b
X-Archives-Hash: a4b900cfe2e74a2e0190569c0d940995

On Sun, Mar 11, 2012 at 05:09:12AM -0400, Walter Dnes wrote:
>   This revision makes 2 changes...

> A) The removal of udev is now standard instead of optional.  udev-181
> and higher will be pulling in kmod, and anything else that kmod depends
> on.  Removing udev will avoid unnecessary cruft on your machine.

> B) Splitting up step 3) into 3a) and 3b) for greater clarity as
> requested in user feedback.

>   The usual warnings apply...
> * this is a beta
> * use a spare test machine
> * if you don't follow the instructions correctly, the result might be
>   an unbootable linux
> * even if you do follow instructions, the result might be an unbootable
>   linux

Yep, I got the (effectively) unbootable machine: My LVM partitions didn't
get mounted.  My precaution against it was: (i) Copy my entire (working)
root partition to a new partition.  (ii) Edit the first line of the new
/etc/fstab.  (iii) Add a new entry to /etc/lilo.conf.  It's handy having
a small root partition.  :-)

> 1) Set up your kernel to support and automount a devtmpfs filesystem at
>    /dev

> * If you prefer to edit .config directly, set
>   CONFIG_DEVTMPFS=y and CONFIG_DEVTMPFS_MOUNT=y

> * If you prefer "make menuconfig", the route is as shown below.  Note
>   that the "Autount devtmpfs..." option won't appear until you enable
>   "Maintain a devtmpf..." option.

> make menuconfig
>   Device Drivers  --->
>     Generic Driver Options  --->
>       [*] Maintain a devtmpfs filesystem to mount at /dev
>       [*]   Automount devtmpfs at /dev, after the kernel mounted the rootfs

>   Once you've made the changes, rebuild the kernel.


> 2) Set up for emerging busybox.  busybox requires the "mdev" flag in
> this situation.  The "static" flag is probably also a good idea.  In
> file /etc/portage/package.use add the line

> sys-apps/busybox static mdev

>    Now, "emerge busybox"


> 3 a) Create /sbin/linuxrc containing at least

> #!/bin/busybox ash
> mount -t proc proc /proc
> mount -t sysfs sysfs /sys
> exec /sbin/init

>   This should be enough for most users.  If you have an unusual setup,
> you may need additional stuff in there.  Remember to
> "chmod 744 /sbin/linuxrc" to make it executable.

I may have an unusual setup, but I don't think so.  I've got my root
partition as ext2 on /dev/sda5, and everything else under LVM.
Otherwise, pretty standard.

>  In the bootloader "append" line, include "init=/sbin/linuxrc".  If
> you're using lilo remember to re-run lilo to implement the changes.  If
> you're using another bootloader, make the equivalant initialization.

How do I know whether my /sbin/linuxrc actually ran?  Maybe, I mean how
can I be sure my "append = "init=/sbin/linuxrc"" actually worked?

> 4) Remove udev from the services list, and replace it with mdev.  Type
>    the following 2 commands at the command line
> rc-update del udev sysinit
> rc-update add mdev sysinit

Done

> 5) reboot to your new kernel.  You're now running without using udev.

Here's where I got problems.  None of my LVM partitions got mounted.
Here're a few lines of my bootup messages, just before the problem:

* Setting up mdev as hotplug agent ...
* Populating /dev with existing devices with mdev -s ...
* Mounting /dev/pts ...
* Mounting /dev/shm ...

Enter runlevel: 3
* Setting up system clock using the hardware clock [UTC]
* Setting up the Logical Volume Manager
* Checking local filesystems
/dev/sda5: clean, 6052/655360 files, 180423/2621440 blocks
fsck.ext3: No such file or directory while trying to open /dev/vg/usr
.....
<and so on, for all my other partitions>

> 6) Remove udev as per the following instructions...

> * execute the following command at the commandline
> emerge --unmerge sys-fs/udev

> * In file /atc/portage/package.mask, append the line
> sys-fs/udev
>   Create the file if it doesn't already exist.  You now have a totally
> udev-free machine

Help would be appreciated.

> -- 
> Walter Dnes <waltdnes@waltdnes.org>

-- 
Alan Mackenzie (Nuremberg, Germany).