Switching to randomly generated hostnames

Martin Langhoff martin.langhoff at gmail.com
Wed May 2 12:05:50 EDT 2012


On Wed, May 2, 2012 at 11:05 AM, Daniel Drake <dsd at laptop.org> wrote:
>> 1 - the code to setup /etc/sysconfig/network is in the wrong place --
>> it should trigger boot that /etc/sysconfig/network is missing
>
> Yes, we can improve the code that handles this case.

That'll be great :-)

>> 2 - yes, libertas init is slow, I've implemented a draft patch that
>> waits for it to complete with something smarter than "sleep" -- with
>> this patch, it seems to succeed 100% of the time for me. Not of the
>> wlan is DOA, but in that case fixing #1 addresses the problem.
>
> As noted in the ticket, this is fixed in 3.3. It can also be fixed by
> backporting a number of patches to 3.0 (but I figured waiting for 3.3
> would be better than putting the time into the backport).

You're right. I read that, and then... forgot it during my debugging.

> The udevsettle behaviour and timing will also change quite a bit with

You can still shorten the settle behaviour significantly with udev
trigger if you know what device you are looking for (and you do ;-) ).

Anyway, it looks like you'll chop the "read from eth0" off so udev
settle goes too.

> For a preview of how things will look, you can test on XO-1 or XO-1.5.

In Taipei right now, only have 1.75 with me, FWIW ;-)

> Yes, we need a "general" solution to wait for the USBVGA corner cases
> at least. Using the state of /sys after probe and and then waiting for
> a file to appear seems like a good solution to me.

Yep. In genral, a modprobe/udevtrigger/waitforpath approach seems to work.

I am a bit annoyed that systemd/udev doesn't provide some useful
facilities for this. We are early users, and as such we hit all the
early issues. Not sure how to put it to upstream.

> With this in mind do people have strong preferences on how to generate
> this? After reading the responses my new proposal would be to try and
> use the last 3 bytes of the MAC address read from mfg data, and if
> that doesnt exist, fall back on 3 random hex bytes.

+1 from this side... + moving it our of the versioned configure_root
code block :-)

cheers,



m
-- 
 martin.langhoff at gmail.com
 martin at laptop.org -- Software Architect - OLPC
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff



More information about the Devel mailing list