Top "Sockets" questions

An endpoint of a bi-directional inter-process communication flow.

Python [Errno 98] Address already in use

In my Python socket program, I sometimes need to interrupt it with Ctrl-C. When I do this, it does close …

python sockets connection errno
socket.shutdown vs socket.close

I recently saw a bit of code that looked like this (with sock being a socket object of course): sock.…

python sockets asynchronous
Get IP address of an interface on Linux

How can I get the IPv4 address of an interface on Linux from C code? For example, I'd like to …

c linux sockets
How to find the socket buffer size of linux

What's the default socket buffer size of linux? Is there any command to see it?

linux sockets buffer
How to tell if a connection is dead in python

I want my python application to be able to tell when the socket on the other side has been dropped. …

python sockets
Does a TCP socket connection have a "keep alive"?

I have heard of HTTP keep-alive but for now I want to open a socket connection with a remote server. …

java sockets http tcp keep-alive
What does Python's socket.recv() return for non-blocking sockets if no data is received until a timeout occurs?

Basically, I've read in several places that socket.recv() will return whatever it can read, or an empty string signalling …

python sockets nonblocking recv
I/O error(socket error): [Errno 111] Connection refused

I have a program that uses urllib to periodically fetch a url, and I see intermittent errors like : I/O …

python sockets urllib
Linux: is there a read or recv from socket with timeout?

How can I try to read data from socket with timeout? I know, select, pselect, poll, has a timeout field, …

c linux sockets tcp
Turn a simple socket into an SSL socket

I wrote simple C programs, which are using sockets ('client' and 'server'). (UNIX/Linux usage) The server side simply creates …

c linux sockets unix ssl