From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org)
	by nuthatch.gentoo.org with esmtp (Exim 4.62)
	(envelope-from <gentoo-user+bounces-55466-garchives=archives.gentoo.org@gentoo.org>)
	id 1GpTNp-00080k-Dd
	for garchives@archives.gentoo.org; Wed, 29 Nov 2006 17:38:09 +0000
Received: from robin.gentoo.org (localhost [127.0.0.1])
	by robin.gentoo.org (8.13.8/8.13.8) with SMTP id kATHZovi026998;
	Wed, 29 Nov 2006 17:35:50 GMT
Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.187])
	by robin.gentoo.org (8.13.8/8.13.8) with ESMTP id kATHXSu8023226
	for <gentoo-user@lists.gentoo.org>; Wed, 29 Nov 2006 17:33:28 GMT
Received: by nf-out-0910.google.com with SMTP id c31so4575721nfb
        for <gentoo-user@lists.gentoo.org>; Wed, 29 Nov 2006 09:33:28 -0800 (PST)
DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws;
        s=beta; d=gmail.com;
        h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth;
        b=LYj/9mOOgEK0TTGzMvH61toYSi8VeMxbsdpYGY+a7LqVPNo7sRF59MsyDgyzNlQrO4MvlxioecWA7CCsRJaWe3mxEXoT4s+kWc6BKK6x7pvoomhCR9ofW8fjwGP6v2BhywdJfwHrFOCmljuZI0nZrb79eHZyYbKXNjVhgWQjxzk=
Received: by 10.82.141.4 with SMTP id o4mr635985bud.1164821607924;
        Wed, 29 Nov 2006 09:33:27 -0800 (PST)
Received: by 10.82.106.2 with HTTP; Wed, 29 Nov 2006 09:33:27 -0800 (PST)
Message-ID: <7573e9640611290933o16ea01e8sd7b53db30e14d7b6@mail.gmail.com>
Date: Wed, 29 Nov 2006 10:33:27 -0700
From: "Richard Fish" <bigfish@asmallpond.org>
Sender: richard.j.fish@gmail.com
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Re: udev upgrade and non-working eth0
In-Reply-To: <200611280749.49142.mrugeshkarnik@gmail.com>
Precedence: bulk
List-Post: <mailto:gentoo-user@lists.gentoo.org>
List-Help: <mailto:gentoo-user+help@gentoo.org>
List-Unsubscribe: <mailto:gentoo-user+unsubscribe@gentoo.org>
List-Subscribe: <mailto:gentoo-user+subscribe@gentoo.org>
List-Id: Gentoo Linux mail <gentoo-user.gentoo.org>
X-BeenThere: gentoo-user@gentoo.org
Reply-to: gentoo-user@lists.gentoo.org
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
References: <2b49f0c80611270558n792864dbtc209ed27423d5d6c@mail.gmail.com>
	 <200611280711.46325.mrugeshkarnik@gmail.com>
	 <7573e9640611271801y1c7280bfh75a3e73b3cd1339f@mail.gmail.com>
	 <200611280749.49142.mrugeshkarnik@gmail.com>
X-Google-Sender-Auth: 41ed42ae05e10d80
X-Archives-Salt: c29e0604-9804-48c1-ae7f-2e17c57a8871
X-Archives-Hash: ac993e363476d05a0003fe7938c71f64

On 11/27/06, Mrugesh Karnik <mrugeshkarnik@gmail.com> wrote:
> On Tuesday 28 November 2006 07:31, Richard Fish wrote:
> > > can see a 75-persistent-net-generator.rules file in there..
> >
> > Hmm, not sure how I got a 70-persistent-net.rules.  There is some
> > interaction between that and 75-persistent-net-generator.rules (and
> > the /lib/udev/write_net_rules script), but I'm a bit too tired to
> > figure it out ATM.  It looks like 70-... should be created by the
> > write_net_rules script...
>
>
> RULES_FILE='/etc/udev/rules.d/70-persistent-net.rules'
>
> That's the first line of write_net_rules.

Right.  I just wasn't able to figure out why you didn't already have
this file created, nor why my laptop had it but not my desktop.

So the story is that 75-persistent-net-generator.rules will call the
script when ethernet devices are added, and it is up to the
write_net_rules script to generate 70-persistent-net.rules.  The
problem is that when udev starts very early in the boot process, your
root filesystem may still be mounted read-only, preventing this file
from being created.

This worked on my laptop, because I added module aliases to prevent
udev from coldplugging the ipw3945 driver, since it requires a daemon
to be running in order to work and that required /var to be mounted.
The module is loaded later in the boot process, after all of the
filesystems are mounted read-write, and that allowed udev to create
the rules file for me, but only for that adapter.

The upshot of this is this: by far the easiest way to solve the
net-naming problem is to run

/lib/udev/write_net_rules all_interfaces

This will generate the rules for all interfaces, and then you can just
edit the file to change the names as you like.  So I guess I'll know
that for the next person that asks. :-P

-Richard
-- 
gentoo-user@gentoo.org mailing list