Re: Init : someone could comment this ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 10.01.08 15:21, James Antill (james.antill@xxxxxxxxxx) wrote:

> 
> On Thu, 2008-01-10 at 09:49 +0100, Tomas Mraz wrote:
> > On Thu, 2008-01-10 at 00:46 +0100, Lennart Poettering wrote:
> > > Although this is totally off-topic: I still think the proper fix is
> > > something like this:
> > > 
> > > http://0pointer.de/lennart/projects/nss-myhostname/
> > > http://0pointer.de/lennart/projects/nss-myhostname/README.txt
> > > 
> > > I wrote that a while back. Maybe someone wants to dust this off and
> > > get it into Fedora and activated by default?
> > > 
> > > This saved me a couple of times on embedded boxes, where each of the
> > > devices used a different hostname and I had to guarantee that the
> > > hostname stayed resolvable in all cases, with a ro root directory.
> > 
> > This seems like a nice idea - actually even better idea would be to be
> > able to pass some arguments to modules in nsswitch.conf and then simply
> > put:
> > 
> > hosts: files dns files(conf=/etc/hosts-fallback)
> 
>  My understanding was that the hostname thing is done so that bootup
> doesn't stop when you have no network ... and the above module doesn't
> help much there (you still have to timeout the DNS requests).

First, nothing hinders you to put this module first in your NSS
list. It's should be put right next to the "files" item in
nsswitch.conf, because it basically just replaces the special
/etc/hosts entry for the local host name.

Then, the reason I hacked this up was mostly to fix stuff like sudo
and apache, which do a lookup+reverse lookup on initialization, which
fails completely if DNS doesn't work (as in "*immediately* fail") and
the entry is not available in /etc/hosts. DNS lookups that time out
are a different problem.

>  And it still fails in the same way, when there is no network (Ie.
> daemon can bind to a specific IP that is the "wrong" one).

Hmm?

Are you suggesting that there are daemons that bind on addresses by
resolving host names? Who's doing something like that? Either daemons
should bind on 0.0.0.0 or bind to manually configured IP
adresses. Everything else is broken anyway.

Lennart

-- 
Lennart Poettering                        Red Hat, Inc.
lennart [at] poettering [dot] net         ICQ# 11060553
http://0pointer.net/lennart/           GnuPG 0x1A015CC4

-- 
fedora-devel-list mailing list
fedora-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-devel-list

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux