Windows 10: Sockets Bind Error

Discus and support Sockets Bind Error in Windows 10 BSOD Crashes and Debugging to solve the problem; Hello there, I have a client and a server socket.When I execute server it's all fine but when I execute client to respond at the same port I get an... Discussion in 'Windows 10 BSOD Crashes and Debugging' started by Παναγιώτης Φακίτσας, Nov 19, 2020.

  1. Sockets Bind Error


    Hello there,


    I have a client and a server socket.When I execute server it's all fine but when I execute client to respond at the same port I get an error bind #10048


    let me show you the code until bind function from server file:


    #define DEFAULT_BUFLEN 512

    #define DEFAULT_PORT "9999"


    int __cdecl mainvoid

    {

    WSADATA wsaData;

    int iResult;



    SOCKET ListenSocket = INVALID_SOCKET;

    SOCKET ClientSocket = INVALID_SOCKET;



    struct addrinfo* result = NULL;

    struct addrinfo hints;



    int iSendResult;

    char recvbuf[DEFAULT_BUFLEN];

    int recvbuflen = DEFAULT_BUFLEN;



    // Initialize Winsock

    iResult = WSAStartupMAKEWORD2, 2, &wsaData;

    if iResult != 0 {

    printf"WSAStartup failed with error: %d\n", iResult;

    return 1;

    }



    ZeroMemory&hints, sizeofhints;

    hints.ai_family = AF_INET;

    hints.ai_socktype = SOCK_STREAM;

    hints.ai_protocol = IPPROTO_TCP;

    hints.ai_flags = AI_PASSIVE;



    // Resolve the server address and port

    iResult = getaddrinfoNULL, DEFAULT_PORT, &hints, &result;

    if iResult != 0 {

    printf"getaddrinfo failed with error: %d\n", iResult;

    WSACleanup;

    return 1;

    }



    // Create a SOCKET for connecting to server

    ListenSocket = socketresult->ai_family, result->ai_socktype, result->ai_protocol;

    if ListenSocket == INVALID_SOCKET {

    printf"socket failed with error: %ld\n", WSAGetLastError;

    freeaddrinforesult;

    WSACleanup;

    return 1;

    }



    // Setup the TCP listening socket

    iResult = bindListenSocket, result->ai_addr, intresult->ai_addrlen;

    if iResult == SOCKET_ERROR {

    printf"bind failed with error: %d\n", WSAGetLastError;

    freeaddrinforesult;

    closesocketListenSocket;

    WSACleanup;

    return 1;

    }


    could you please someone help me fixing this issue?

    :)
     
    Παναγιώτης Φακίτσας, Nov 19, 2020
    #1

  2. Error message "missing registry socket"

    Hi Harry,

    Thank you for bringing up your query on Microsoft Community.

    I realize this may be frustrating. Now that you have me with you, let me take care of this.

    Winsock or Windows Sockets is a technical specification that defines how Windows network software should access network services.

    Let us try the following steps and check if it helps.

    Step 1: Perform a Winsock Reset

    • Open the Windows Start Screen or Start Menu and type
      cmd in the search box.
    • Right-click Command Prompt or cmd in the search results and select
      Run as Administrator.
    • Type netsh winsock reset in the Command Prompt window and press
      Enter. Wait for Windows to finish resetting your Winsock configuration.
    • Reboot your computer.

    Step 2: I suggest you to follow the steps suggested by

    Suvarna Govinda
    (replied on February 16, 2016) and check if it helps.

    "Windows Sockets registry entries required for network connectivity are missing" Connectivity Issues in Windows 10

    "Windows Sockets registry entries required for network connectivity are missing" Connectivity Issues in Windows 10

    Hope it helps.

    Let us know the status, we are glad to assist you further
     
    Abdul_Malik, Nov 19, 2020
    #2
  3. Robo 3T error No unix socket support on windows

    I'm trying to connect my cloud database from mongodb atlas to robo 3t. I created a database and entered the connection string and it tells me it connected to my connection string but the next step fails and it says "Failed to load list of databases" when I clicked Show error details it gives me the error "Cannot connect to MongoDB at [...]:27017" and "Error: No unix socket support on windows."
     
    dizzyflames, Nov 19, 2020
    #3
  4. Sockets Bind Error

    Windows Socket entry missing

    Hi,

    Winsock or Windows Sockets is a technical specification that defines how Windows network software should access network services.

    I would suggest you to try the step below and check if it helps.

    Step 1: Reset Winsock


    • Press Windows + X, Choose Command prompt (admin).

    • Click yes on User Account Control prompt .

    • Type netsh Winsock reset in the prompt and press enter.
    This command will reset the Winsock, if you get any error message while resetting provide us the details.

    Step 2: Reset TCP/IP

    How to reset TCP/IP by using the NetShell utility

    https://support.microsoft.com/kb/299357?wa=wsignin1.0

    Note: This link also applies to Windows 10 Technical Preview.

    Resetting TCP/IP will reset the IP configuration settings and fix internet connection issues.

    Let us know the status of the issue to assist you further.

    Regards,

    Guru Kiran
     
    Guru Kiran G, Nov 19, 2020
    #4
Thema:

Sockets Bind Error

Loading...
  1. Sockets Bind Error - Similar Threads - Sockets Bind Error

  2. Bind outgoing socket connection to specific interface doesn't always work on Windows 11

    in Windows 10 Gaming
    Bind outgoing socket connection to specific interface doesn't always work on Windows 11: For a VPN app on a Windows 11 machine I have my regular wifi interface 192.168.3.7 and a Wintun Tunnel interface configured to have IP 192.168.3.6. The routing tables are set up so that all traffic should go to the Wintun Tunnel by default. However the app still needs to be...
  3. Bind outgoing socket connection to specific interface doesn't always work on Windows 11

    in Windows 10 Software and Apps
    Bind outgoing socket connection to specific interface doesn't always work on Windows 11: For a VPN app on a Windows 11 machine I have my regular wifi interface 192.168.3.7 and a Wintun Tunnel interface configured to have IP 192.168.3.6. The routing tables are set up so that all traffic should go to the Wintun Tunnel by default. However the app still needs to be...
  4. BitLocker error - PCR7 binding is not supported

    in Windows 10 Network and Sharing
    BitLocker error - PCR7 binding is not supported: Hello, I have an issue with BitLocker not working and advising "PCR7 binding is not supported"I've undertaken extensive research on the internet to resolve the issue and drawing a blank.This laptop was previously using BitLocker without issue prior to me wiping the system and...
  5. BitLocker error - PCR7 binding is not supported

    in Windows 10 Gaming
    BitLocker error - PCR7 binding is not supported: Hello, I have an issue with BitLocker not working and advising "PCR7 binding is not supported"I've undertaken extensive research on the internet to resolve the issue and drawing a blank.This laptop was previously using BitLocker without issue prior to me wiping the system and...
  6. BitLocker error - PCR7 binding is not supported

    in Windows 10 Software and Apps
    BitLocker error - PCR7 binding is not supported: Hello, I have an issue with BitLocker not working and advising "PCR7 binding is not supported"I've undertaken extensive research on the internet to resolve the issue and drawing a blank.This laptop was previously using BitLocker without issue prior to me wiping the system and...
  7. After 65532 TCP/IP Socket Connections in Windows 10, getting Socket Error 10055 - No Buffer...

    in AntiVirus, Firewalls and System Security
    After 65532 TCP/IP Socket Connections in Windows 10, getting Socket Error 10055 - No Buffer...: After 65532 TCP/IP Socket Connections in Windows 10, select returning -1. WSAGetLastError is returning Error 10055 - No Buffer Space Available. Can Windows support more than 65532 TCP/IP Socket Connection or not ? I have modified the registry: [HKEY_LOCAL_MACHINE...
  8. Is this a phone socket or ethernet socket ?

    in Windows 10 Network and Sharing
    Is this a phone socket or ethernet socket ?: Hi. My brother in law has asked me if I can install broadband in his shed, he has shown me photos of the wired sockets he has but he is unsure what they are and I can't tell for sure from that pic. Could you tell me if that socket in the photo is for a ethernet plug or a...
  9. Sockets error ????

    in Windows 10 Network and Sharing
    Sockets error ????: Hi there Why does Windows Networking have to be so Horrible -- I've run loads of Linux machines with NO network problems at all -- but Windows networking always causes hassle -- sometimes even on machines that have worked suddenly stop working for no reason I can find....
  10. Web Socket Error

    in Windows 10 Network and Sharing
    Web Socket Error: Can someone please explain to me what this means and what causes it: SCRIPT12030: SCRIPT12030: WebSocket Error: Network Error 12030, The connection with the server was terminated abnormally TIA, Richard 99050