[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: SetError() #2: Host name look up failed.
Hello,
A URL is string containing several pieces of information. These
include the protocol (http or https), the server's domain name or IP
address, and a directory/path/filename. There are optional elements
for userid, password and port number, as well.
At one point in the process, it takes one of these components -- the
domain name -- and asks your DNS resolver to tell HTTPAPI what the
address of that server is. The DNS resolver is telling ?HTTPAPI that
the host cannot be found.
Let's say for example that your URL is:
[1]http://example.com/somedir/somefile.xml
What HTTPAPI needs to do is ask your DNS resolver what the address of
"example.com" is. It needs to do that so it can connect to the
example.com HTTP server and ask it for "/somedir/somefile.xml". The
trouble is, the resolver is teling it that example.com doesn't exist.
Obviously, in your case, the name isn't "example.com", it's something
else -- but you haven't told us what that name is.
You can verify that the error is in the operating system's resolver
(rather than in HTTPAPI) by typing this:
PING RMTSYS('example.com')
(except, replace 'example.com' with the proper domain name.) You
will get the message "Unknown host, example.com". Basically -- this
is telling you exactly the same thing that HTTPAPI is telling you (just
phrased slightly differently) that the DNS resolver is reporting that
this host does not exist.
The DNS resolver on IBM i is configured by typing CFGTCP and taking
option 12. On that screen, you'll see the same domain name
(columbus.co.za) and DNS servers (172.26.1.98, 172.26.49.60) that
HTTPAPI is reporting in the log. When you ask the operating system's
DNS resolver to look up a hostname (no matter which program does it)
the resolver will make a request to those IP addresses, and they are
the ones that, most likely aren't giving you the information you need.
I would give those addresses to your network folks, and show them that
the DNS lookups are failing (with PING or similar) and ask them why, if
everything is correct, they aren't providing addresses for the DNS
names. If they say something like "those are the wrong addresses",
then use CFGTCP option 12 to update the addresses.
Good luck
On 11/7/2012 11:54 PM, [2]vanderWalt.Devlyn@xxxxxxxxxxxxxx wrote:
Hi All
I am getting this error "SetError() #2: Host name look up failed." in
the httpapi_debug.txt log file. I assume it may be a problem with our
servers, but according to the server team, everything is fine. Please
can you help me debug this.
Regards
Devlyn
HTTPAPI Ver 1.24beta11 released 2010-09-09
OS/400 Ver V6R1M0
http_persist_open(): entered
http_long_ParseURL(): entered
DNS resolver retrans: 1
DNS resolver retry : 1
DNS resolver options: x'00000136'
DNS default domain: columbus.co.za
DNS server found: 172.26.1.98
DNS server found: 172.26.49.60
SetError() #2: Host name look up failed.
__________________________________________________________________
This e-mail is subject to the Columbus Stainless [Pty] Ltd Email Legal
Notices available at:
[1][3]http://www.columbus.co.za/EmailLegalNotice.htm.
__________________________________________________________________
This e-mail message has been scanned for Viruses and Content and
cleared by MailMarshal
__________________________________________________________________
References
1. [4]http://www.columbus.co.za/EmailLegalNotice.htm
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubscribe, please go to:
[5]http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
References
1. http://example.com/somedir/somefile.xml
2. mailto:vanderWalt.Devlyn@xxxxxxxxxxxxxx
3. http://www.columbus.co.za/EmailLegalNotice.htm
4. http://www.columbus.co.za/EmailLegalNotice.htm
5. http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------