Re: one script can resolve hostnames, but another one can't
- From: Bennett Haselton <bennett@xxxxxxxxxxxxx>
- Date: Mon, 13 Apr 2009 16:38:01 -0700 (PDT)
On Apr 13, 2:16 pm, Unruh <unruh-s...@xxxxxxxxxxxxxx> wrote:
Bennett Haselton <benn...@xxxxxxxxxxxxx> writes:
I run several dedicated CentOS servers that have two different web
proxy scripts on them called PHProxy and Glype (scripts where you see
a form where you can type in the web page that you want it to fetch,
and the site fetches the page for you and displays its contents). On
most servers, both PHProxy and Glype are able to resolve hostnames
with no problem.
However, on one server (https://www.turtleflag.com/), I'm seeing odd
behavior: If I typehttp://www.yahoo.com/into the PHProxy form, it
fetches it with no problem:
https://www.turtleflag.com/hsjbzay.php?q=aHR0cDovL3d3dy55YWhvby5jb20v....
However, if I typehttp://www.yahoo.com/into the Glype form and
submit, it gives me the error:
"The requested resource could not be loaded. libcurl returned the
error:
name lookup timed out. [Reloadhttp://www.yahoo.com/]"
How could the two different scripts be using different OS calls to
resolve a hostname, such that one is succeeding and the other one
isn't?
Easily. there are at least two different system calls to look up addresses.
getaddrinfo and gethostbyname and its ilk.
They use entirely different procedures for looking up addresses.
What can I do on the command line to try resolving the hostname using
one method, and then to try resolving the hostname by the other
method, to see if they dive different results?
And incidentally, why would they use "entirely different procedures"
for resolving hostnames -- why wouldn't both of them just send their
query to the resolvers listed in /etc/resolv.conf and then return the
result?
Bennett
.
- Follow-Ups:
- Re: one script can resolve hostnames, but another one can't
- From: Unruh
- Re: one script can resolve hostnames, but another one can't
- From: The Natural Philosopher
- Re: one script can resolve hostnames, but another one can't
- References:
- one script can resolve hostnames, but another one can't
- From: Bennett Haselton
- Re: one script can resolve hostnames, but another one can't
- From: Unruh
- one script can resolve hostnames, but another one can't
- Prev by Date: Re: Looking for Linux-friendly network cameras
- Next by Date: Re: one script can resolve hostnames, but another one can't
- Previous by thread: Re: one script can resolve hostnames, but another one can't
- Next by thread: Re: one script can resolve hostnames, but another one can't
- Index(es):
Relevant Pages
|