IIS
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationIIS

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old June 7th, 2006, 12:47 PM
rage007 rage007 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 7 rage007 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 54 m 49 sec
Reputation Power: 0
Exclamation DNS lookup from PHP failing (gethostbyaddr and built in)

Hi, this is a weird situation I am facing. I am running a php script under IIS 5, configed with ASAPI. Specifically I'm using ldap_connect to connect to a fqdn on my local network. The server entry I'm trying to connect to rotates 3 physical addresses for the given server fqdn.

The problem is that php is randomly unable to pull an IP, thus causing the script to fail. My DNS servers are massive and redunant, so I am sure they are not going down. I can run this same code on the same host under Apache with no problems whatsoever. A rundown:

Server: IIS 5, php 5.0.4 (ASAPI), Windows 2000 Sp4
Code:
First try -
PHP Code:
 $c ldap_connect('ldap.mydomain.com'); //Fails frequently 


Second Try -
PHP Code:
 $servers gethostbynamel("ldap.mydomain.com");
 foreach(
$servers as $server){
    
$c ldap_connect($server);
 } 
//Still fails fairly frequently, gethostbyname returns blank 


Things I know:
-The reverse DNS IP entries for ldap.mydomain.com does not match the forward entry. But shouldn't since its rotating entries right?
-Code works flawlessly on Apache with same php install
-DNS Servers are up and running fine (ie, I can nslookup when this error occurs)

Any ideas on what specifically could be causing PHP to choke under these conditions? I will probably cross post this to the PHP forum too, but I figured anyone with IIS expertise may know faster.

Thanks in advanced for your help!

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationIIS > DNS lookup from PHP failing (gethostbyaddr and built in)


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway