FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo User

 
 
LinkBack Thread Tools
 
Old 02-17-2012, 10:40 PM
"Walter Dnes"
 
Default Beta test Gentoo with mdev instead of udev; version 4

This revision removes a couple of steps in the process, so there's
less stuff involved. If only software developers worked that way <G>.

* Busybox stable is now past the buggy version that didn't work with
mdev. There is no need to keyword version 1.19.2

* The virtual/dev-manager-0.ebuild has been modified as per my feature
request to support an mdev-based system. There is no longer any need
for a customized/hacked ebuild in an overlay

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


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) In the bootloader append line, include "init=/sbin/linuxrc" where
the file /sbin/linuxrc consists of *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. If you're using lilo remember
to re-run lilo to implement the changes.

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


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


6) ***THIS STEP IS OPTIONAL*** This is only to alay any suspicion that
udev is still in use.

* 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

--
Walter Dnes <waltdnes@waltdnes.org>
 
Old 02-18-2012, 04:51 AM
Pandu Poluan
 
Default Beta test Gentoo with mdev instead of udev; version 4

On Feb 18, 2012 6:46 AM, "Walter Dnes" <waltdnes@waltdnes.org> wrote:

>

> *This revision removes a couple of steps in the process, so there's

> less stuff involved. *If only software developers worked that way <G>.

>

> * Busybox stable is now past the buggy version that didn't work with

> mdev. *There is no need to keyword version 1.19.2

>

> * The virtual/dev-manager-0.ebuild has been modified as per my feature

> request to support an mdev-based system. *There is no longer any need

> for a customized/hacked ebuild in an overlay

>

> *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

>

>

> 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) In the bootloader append line, include "init=/sbin/linuxrc" where

> * the file /sbin/linuxrc consists of *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. *If you're using lilo remember

> * to re-run lilo to implement the changes.

>

> 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

>

>

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

>

>

> 6) ***THIS STEP IS OPTIONAL*** *This is only to alay any suspicion that

> * udev is still in use.

>

> * 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

>


Thanks for the update!


I've been mdev-ing my servers, and no problems whatsoever until now (touch wood!).


For those still on the sidelines re: mdev-for-udev, be aware that progress is happening rapidly with regards to what udev feature is 'vital' for modern systems.


Heck, mdev is already perfect for my needs: it can rename devices, fire up a script on hotplug/hotunplug events, load a firmware if told so by the kernel...


I suggest interested people should at least lurk in the busybox mailing list. The mdev-for-udev discussion us quite fresh, patches (not bloats) have been submitted... and we have our very own Walt Dnes in that list, proudly waving the Gentoo banner ;-)



Rgds,
 
Old 02-27-2012, 08:49 AM
Pandu Poluan
 
Default Beta test Gentoo with mdev instead of udev; version 4

On Sat, Feb 18, 2012 at 06:40, Walter Dnes <waltdnes@waltdnes.org> wrote:
>

---- >8 snip

>
> 3) In the bootloader append line, include "init=/sbin/linuxrc" where
> * the file /sbin/linuxrc consists of *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. *If you're using lilo remember
> * to re-run lilo to implement the changes.
>

I suggest splitting this step into two:

3a) Create /sbin/linuxrc containing at least ... chmod ...

3b) Append "init=/sbin/linuxrc" to bootloader line

Slightly less confusing :-)

Rgds,
--
FdS Pandu E Poluan
~ IT Optimizer ~

*• LOPSA Member #15248
*• Blog : http://pepoluan.tumblr.com
*• Linked-In : http://id.linkedin.com/in/pepoluan
 
Old 02-29-2012, 12:27 AM
"Walter Dnes"
 
Default Beta test Gentoo with mdev instead of udev; version 4

On Mon, Feb 27, 2012 at 04:49:40PM +0700, Pandu Poluan wrote

> I suggest splitting this step into two:
>
> 3a) Create /sbin/linuxrc containing at least ... chmod ...
>
> 3b) Append "init=/sbin/linuxrc" to bootloader line
>
> Slightly less confusing :-)

OK. I'll modify it as suggested. There is talk on the gentoo-dev
list that mod-utils will be replaced by virtual/mod-utils which will
default to kmod (required to build udev-181). Note that mod-utils and
kmod are mutually exclusive. That should be taken care of in the
ebuilds, but I'll monitor the situation. I may have to modify the setup
instructions for conversion to mdev... i.e. an additional step, removing
kmod and installing mod-utils.

--
Walter Dnes <waltdnes@waltdnes.org>
 

Thread Tools




All times are GMT. The time now is 11:05 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org