473,395 Members | 1,730 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Very peculiar problem with GetHostByAddress on W98

I don't suppose anyone will be able to help with this, it's most odd. I use
IPHostEntry hostInfo = GetHostByAddress(ipAddress)
to resolve an IP address to a name (in this case it is actually the local
computer, if that's relevant). The call is made on several occasions as the
program runs, the first two times it works fine, then, for no reason, instead
of the name it returns the IP address in hostInfo.HostName. This program has
been working fine for months, and suddenly started doing this, but only on
W98. Al wild guesses as to the cause would be gratefully received
--
Dave
Jun 22 '06 #1
2 1364
Dave wrote:
I don't suppose anyone will be able to help with this, it's most odd. I
use IPHostEntry hostInfo = GetHostByAddress(ipAddress)
to resolve an IP address to a name (in this case it is actually the local
computer, if that's relevant). The call is made on several occasions as
the program runs, the first two times it works fine, then, for no reason,
instead of the name it returns the IP address in hostInfo.HostName. This
program has been working fine for months, and suddenly started doing this,
but only on W98. Al wild guesses as to the cause would be gratefully
received


Hi Dave,

Do you have a DNS server on your network? Do you use DHCP?

<WildSpeculation>
Perhaps your DHCP server has stopped assigning the address of your DNS
server to your interface card.
</WildSpeculation>

;-)
-- Tom Spink
Jun 22 '06 #2
No I don't have a DNS server, although I do have DHCP as supplied by a
Netgear router. Also, the problem mysteriously disappeared again this
morning, and then came back on one of my two 98 PCs, and has now disappeared
again. The software is the same in all cases. I can only assume it's some odd
bug in W98, but we need to find a cure or a work around. Any suggestions
welcome.
--
Dave
"Tom Spink" wrote:
Dave wrote:
I don't suppose anyone will be able to help with this, it's most odd. I
use IPHostEntry hostInfo = GetHostByAddress(ipAddress)
to resolve an IP address to a name (in this case it is actually the local
computer, if that's relevant). The call is made on several occasions as
the program runs, the first two times it works fine, then, for no reason,
instead of the name it returns the IP address in hostInfo.HostName. This
program has been working fine for months, and suddenly started doing this,
but only on W98. Al wild guesses as to the cause would be gratefully
received


Hi Dave,

Do you have a DNS server on your network? Do you use DHCP?

<WildSpeculation>
Perhaps your DHCP server has stopped assigning the address of your DNS
server to your interface card.
</WildSpeculation>

;-)
-- Tom Spink

Jun 22 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: ruggierorizzi | last post by:
Hi everyone, i would like to know if there is a difference between gethostbyaddress method and $_SERVER. furthermore i hve a little problem using ip address resolution. Some ip address...
1
by: Rushikesh Joshi | last post by:
Hi Friends I am having some query. On a server two site hosted 1) magnamags.com 2) stardustindia.com Now when I am resolving the IP address for this both sites. I am getting...
1
by: huzz | last post by:
I wrote a method which takes an ip address and returns hostname as shown below. It works fine.. only problem i have is when the passed ip address is not found in the database the method throws this...
3
by: RZ | last post by:
Hi Folks, I wrote an app to scan our Packet Filter logs for certain IPs. It uses GetHostByAddress(). I used multi-threading to get around the 2 second hang. The remaining problem is that...
2
by: Droopy | last post by:
Hi, I try to implement a reusable socket class to send and receive data. It seems to work but I have 2 problems : 1) I rely on Socket.Available to detect that the connection is closed (no...
5
by: Sven | last post by:
Hi! I have a problem with System.Net.Dns.GetHostByAddress(ls_Request.UserHostAddress()).HostName Usually the call GetHostByAddress returns the correct hostname of the client, but sometimes...
1
by: Jed | last post by:
I have a class for logging information about user activity on a web site, but it suddenly became really slow. I was wondering what factors may have caused the slow down. Initially, I used the...
3
by: Jerome Lavalley, MCSE | last post by:
I have an application that does a reverse lookup using System.net.dns.gethostbyaddress, however I am encountering some problems. If the application resolves the address of another machine it...
1
by: Asfar Sadewa | last post by:
Hello all, I have a web application written in C# that needs to track the machine name, ip, and the user name of the accessor. the application is hosted on a web server using SSL. i got the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.