Skip to main content
Filter by
Sorted by
Tagged with
1164 votes
37 answers
554k views

This was a question raised by one of the Software Engineers in my organisation. I'm interested in the broadest definition.
Richard Dorman's user avatar
902 votes
2 answers
408k views

The man pages and programmer documentations for the socket options SO_REUSEADDR and SO_REUSEPORT are different for different operating systems and often highly confusing. Some operating systems don't ...
Mecki's user avatar
  • 135k
465 votes
19 answers
1.4m views

I'm running an Express.js application using Socket.io for a chat webapp and I get the following error randomly around 5 times during 24h. The node process is wrapped in forever and it restarts itself ...
361 votes
20 answers
729k views

I am trying to develop a system where there are different nodes that are run on different system or on different ports on the same system. Now all the nodes create a Socket with a target IP as the ...
sasidhar's user avatar
  • 7,802
321 votes
39 answers
1.1m views

I am getting the following error when I try to connect to mysql: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Is there a solution for this error? What might be ...
Atul's user avatar
  • 4,593
306 votes
5 answers
342k views

I'm getting started on socket programming, and I keep seeing references to something called AF_INET. Yet, I've never seen anything else used in its place. My lecturers are not that helpful and just ...
Smashery's user avatar
  • 60.1k
269 votes
9 answers
153k views

What is the difference between read() and recv(), and between send() and write() in socket programming in terms of performances, speed and other behaviors?
265 votes
9 answers
339k views

In C, I understood that if we close a socket, it means the socket will be destroyed and can be re-used later. How about shutdown? The description said it closes half of a duplex connection to that ...
user avatar
253 votes
22 answers
1.1m views

I am working with a commercial application which is throwing a SocketException with the message, An existing connection was forcibly closed by the remote host This happens with a socket connection ...
peter's user avatar
  • 13.6k
242 votes
5 answers
208k views

Assuming the following is defined in .../hosts: 127.0.0.1 localhost What, if any, are the actual differences between using 127.0.0.1 and localhost as the server name, especially when hitting ...
Bohemian's user avatar
  • 427k
230 votes
18 answers
236k views

I want to start a server which listen to a port. I can specify port explicitly and it works. But I would like to find a port in an automatic way. In this respect I have two questions. In which range ...
Roman's user avatar
  • 132k
217 votes
6 answers
202k views

This might be a very basic question but it confuses me. Can two different connected sockets share a port? I'm writing an application server that should be able to handle more than 100k concurrent ...
K J's user avatar
  • 4,763
192 votes
17 answers
1.3m views

I am getting the following error trying to read from a socket. I'm doing a readInt() on that InputStream, and I am getting this error. Perusing the documentation suggests that the client part of the ...
user avatar
178 votes
12 answers
154k views

Everyone seems to say named pipes are faster than sockets IPC. How much faster are they? I would prefer to use sockets because they can do two-way communication and are very flexible but will choose ...
user19745's user avatar
  • 3,659
178 votes
9 answers
17k views

I'm having issues getting the C sockets API to work properly in C++ on z/OS. Although I am including sys/socket.h, I still get compile time errors telling me that AF_INET is not defined. Am I missing ...
Jax's user avatar
  • 7,240
173 votes
14 answers
443k views

Given this stack trace snippet Caused by: java.net.SocketException: Software caused connection abort: socket write error  at java.net.SocketOutputStream.socketWrite0(Native Method) I ...
Eran Medan's user avatar
  • 45.9k
172 votes
3 answers
116k views

I know there's no single hard-and-fast answer, but is there a generic order-of-magnitude estimate approximation for the encryption overhead of SSL versus unencrypted socket communication? I'm talking ...
joel.neely's user avatar
  • 31.1k
170 votes
17 answers
441k views

In my Python socket program, I sometimes need to interrupt it with Ctrl-C. When I do this, it does close the connection using socket.close(). However, when I try to reopen it I have to wait what ...
skylerl's user avatar
  • 4,280
169 votes
3 answers
94k views

What's the difference between sockets (stream) and sockets (datagrams)? Why use one over the other?
RoR's user avatar
  • 16.7k
164 votes
6 answers
353k views

I have a vb.net application that opens a socket and listens on it. I need to communicate via this socket to that application using a javascript running on a browser. That is i need to send some data ...
swordfish's user avatar
  • 5,025
161 votes
14 answers
1.3m views

We are seeing frequent but intermittent java.net.SocketException: Connection reset errors in our logs. We are unsure as to where the Connection reset error is actually coming from, and how to go ...
Richard Ev's user avatar
  • 54.3k
149 votes
10 answers
186k views

How do I programmatically determine the availability of a port in a given machine using Java? i.e given a port number, determine whether it is already being used or not?.
user54075's user avatar
  • 1,491
147 votes
6 answers
100k views

What is the difference between socket programming and Http programming? can anyone help please?
Innovative Thinker's user avatar
146 votes
3 answers
70k views

Can we call send from one thread and recv from another on the same socket? Can we call multiple sends parallely from different threads on the same socket? I know that a good design should avoid this, ...
Jay's user avatar
  • 25k
142 votes
8 answers
144k views

What is a good way to communicate between two separate Python runtimes? Things tried: reading/writing on named pipes e.g. os.mkfifo (feels hacky) dbus services (worked on desktop, but too heavyweight ...
wim's user avatar
  • 368k

1
2 3 4 5
1329