[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Question about kio redesign
From:       Antonio Larrosa <antlarr () arrakis ! es>
Date:       1999-12-20 19:45:54
[Download RAW message or body]

Stephan Kulow wrote:
> 
> Antonio Larrosa wrote:
> >
> > Hi,
> >
> > I'm thinking that there could be a problem with the new design someone
> > (coolo?) proposed for kio.
> > If I'm not wrong (and to put it simple), there's a daemon and it forks for
> > each kio command, isn't it ?
> > If so, there could be a problem with dial-up connections.
> > It seems that the resolv.conf file is only loaded by libresolv on startup
> > of the application (in this case, when the daemon is run, or perhaps when
> > the first kio_http child is forked, I don't know, but it doesn't matter).
> >
> > The problem is that kppp (and similar apps) change the contents of that file,
> > so it should re-read it after the change, but this cannot happen unless you
> > restart the application.
> >
> > Well, I should say that I don't know much about all this except for
> > what comes in the wwwoffle FAQ (question 3.2), so I may be completely
> > wrong with this.
> 
> This means you have to restart netscape when you go online? Never
> noticed,
> it just worked.
> 

:-) It seems netscape uses a non-standard name lookup.
I better post the thing that worried me, and let others decide if
it's important or it doesn't have anything to do with the kioslaves.
I was worried specially about the "will affect any (most) programs"
part. 

---8<---8<---

Q 3.2 Why can't WWWOFFLE find a host when the browser without it can?

There are two possible reasons for this.

1) A Non-authoritative DNS server.
2) A change in the DNS server configuration since wwwoffle was started.

When WWWOFFLE looks up a hostname it uses the standard UNIX library (libc)
function call gethostbyname().  This will only return the host information if
the name that it receives from the domain name server (DNS) is authoritative.  A
non-authoritative answer is not returned, but an error status is set.

Large browser projects (Netscape in particular) will use a non-authoritative
answer if one is available.  This means that it can access sites that are not
available to WWWOFFLE.  The source code for doing this is not obvious and
requires quite low level functions in the name resolver library (libresolv).

This problem only happens when the name server that you are using has poor
connectivity to other name servers or some other name resolving problem.  If
possible the solution is to use a different name server, or complain to the
manager of the one that you do use.

[If anybody has source code for non-authoritative name lookups please tell me.]

The other possible reason is that the DNS server that was configured when
WWWOFFLE was started is no longer valid.  This would happen for example if the
file /etc/resolv.conf was changed after wwwoffled was run.  This is not a
WWWOFFLE only problem, but will affect any (most) programs that use name
lookups.

The reason is that the name lookup part of the standard UNIX library (libc) is
initialised when the program is first started.  When the name lookup is
performed later it will still use the same configuration that was in place when
the program was first started.

This may happen without you being aware of it since some of the user friendly
PPP setup programs will change the /etc/resolv.conf file depending on which ISP
you are connecting to.

---8<---8<---

Greetings,

--
Antonio Larrosa Jimenez
Student of Mathematics
antlarr@arrakis.es        larrosa@kde.org
http://www.arrakis.es/~rlarrosa
KDE - The development framework of the future, today.

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic