Sending data to 127.*, unreachable host RRS feed

  • Question

  • Hello folks,

    I'm trying to send to the loopback address space in a .NET 3.5 application running on Windows XP. The code does a simple:

    receiver = new IPEndPoint(IPAddress.Parse(""), 8000);
    .SendTo(data, len, SocketFlags.None, receiver);

    When I run the code I get an unreachable host socket exception. That seems strange to me because the loopback interface is always around, and it shouldn't generate any unreachable host exceptions.

    Windows 7 executes the code just fine, making the problem that much stranger.

    So -- if anyone has any tips on getting this working in XP, I'd appreciate it.


    Some info:

    • Something is listening on, my netstat shows:
    • UDP : 5824

    • I am running XP SP3, and there is no firewall on my test machine

    I'm noticing on XP when I ping, the replies come back:

    Reply from

    On Windows 7 the reply comes back from the address I pinged:

    Reply from

    I'm thinking this could be the issue and as such it's not really a programming problem, it's more of a problem with XP itself...

    -- Dan

    Monday, April 11, 2011 6:05 PM