Questions tagged [sockets]
A communication end-point for networking, for CPUs please use [processor-socket]
273
questions
1
vote
2
answers
157
views
Windows: how to find what process is listening on a Unix file socket?
I have a cross-platform Golang application which listens on a Unix file socket as follows:
listener, err := net.Listen("unix", socketFilePath)
if err != nil {
return err
}...
2
votes
1
answer
150
views
Routing table behaviour coupled with bound sockets - unexpected behaviour
Problem
I am experiencing some rather odd behavior where a seemingly unrelated default gateway route is having unexpected side-effects. I managed to replicate this issue with a minimal example. The ...
1
vote
1
answer
180
views
Cannot run recent versions of Node.js in Vagrant box anymore
I like to do my dev work in Vagrant virtual machines to keep a clean environment.
Having recently updated Node.js to v18.18.0, I suddenly cannot run npm commands inside the guest any longer:
npm start:...
0
votes
0
answers
53
views
What is the best way to redirect PulseAudio sink data to another(python) process
My goal is to get real time audio data from some application and mic to another process(python) for processing(DSP, live transcription ect.).
I was able to create a PulseAudio sink, using PulseAudio ...
0
votes
0
answers
78
views
SSH remote forwarding fails for root user
I'm using remote forwarding for Sublime (rmate) using the following configuration in my (local) .ssh/config file:
Host host
User user
Hostname hostname
RemoteForward /home/user/.rmate.socket localhost:...
2
votes
2
answers
932
views
What is the proper way to use QEMU's socket feature?
I can't seem to find much documentation anywhere on using the -serial unix:/path/to/some/file argument to qemu-system-XXXX, so I'm hoping someone here can shed some light on this. Specifically, I'm ...
0
votes
1
answer
129
views
Tmux shenanigans: Sharing a local session to a remote server for another user to view
I've got an SSH server running on a Raspberry Pi so that my friend and I can peer-program (or really just muck around) on, but frankly, it's too old and underpowered to do anything useful on besides ...
0
votes
1
answer
139
views
Why UNIX socket files end with and equal sign in ls?
When I list (ls) files in directory, I see the equal sign = after some files. All these files in my case are UNIX domain socket files:
user@Debian11:~/src/unix_sock$ l
a.out* cli_stream* ...
7
votes
2
answers
1k
views
Is it possible to interchange these two sockets since the cables in the wall look the same?
My Ethernet socket isn't working and I'm convinced it has to do with either the socket itself or the cable behind the wall. This picture of my wall sockets (the left the Ethernet socket, the right a ...
0
votes
0
answers
74
views
Issue with network cable
We recently had a garden studio installed in our back garden and I asked them to lay a network cable (steel armoured) from the front of the house, where the main router is located, to the garden ...
0
votes
0
answers
66
views
Firewall rule for divert socket on Ubuntu
I have been trying to follow this to make a divert socket. Unfortunately, the How-To has a dead link to patched code, so I can't inspect what changes were made. I did see divert in the Ubuntu man ...
1
vote
0
answers
118
views
Is there a way to close down a port used by a service during shutdown or boot?
I have some service listen.service which makes the machine act as a TCP server which other clients can connect to. The problem is once the service starts up, it doesn't actually do anything for about ...
0
votes
0
answers
602
views
Torrenting now fails in Windows 10
qbitTorrent stopped working in Windows 10, so I uninstalled it, and replaced it with Deluge.
64-bit Deluge fails with
"Unhandled exception in script
Failed to execute script 'deluge-script' due ...
0
votes
1
answer
197
views
What is the relationship between interfaces and ports between a host PC and Docker container?
Premise:
I'm trying to pull together recent learning about network interfaces and ports and try to tie that new learning with Docker.
A quick summary of the things I learned relevant to this question:
...
1
vote
1
answer
375
views
UDP packets with data length <12 bytes not arriving
I have one specific Ubuntu VM on my network that won't send UDP packets with a data length below 12 bytes. E.g:
"HelloWorld123" gets sent.
"HelloWorld" does not get sent.
I tried ...
0
votes
1
answer
181
views
How is an IP address assigned to a process in TCP?
When TCP connection is established between two sockets, suppose that there are multiple NICs in the computer, so which IP address will the socket bind [ or - which IP address will be passes into bind()...
0
votes
1
answer
107
views
Why does a process have multiple IP address in VM Ware or Hyper-v
When a process in a VM (with multiple NICs) communicates with some other process on some other virtual machine (or maybe on the internet), it does it via a different IP address, at different times.
...
0
votes
0
answers
119
views
Linux socket is not using the src-ip from the bind address
I have a single Linux machine with 3 interfaces, eth0, host1, and loopback. And I have an application that sends out packets at the loopback and routed out to host1. To achieve this, my application ...
10
votes
2
answers
2k
views
What is non-networked Unix domain socket?
I am reading Unsecured docker daemons revealed
It says
Docker daemon creates a non-networked Unix domain socket at /var/run/docker.sock
What does non-networked Unix domain socket denote?
0
votes
0
answers
85
views
Inconsistent response time with socket communications
I have a test setup with two custom-made devices of the same type, Ethernet switch and industrial PC.
The switch is Moxa EDS 405 and the PC is a relatively low spec machine with Atom 1.46 GHz CPU, 4 ...
0
votes
1
answer
173
views
Why does Windows resolve all IPs of all NICs with the hostname?
I´m having diferents problems with TCP/IP aplications that works through HOSTNAME. The Server where this aplications are installed(WIN Server 2012) have 4 NICs and Windows,resolve his own hostname ...
0
votes
1
answer
639
views
Meaning of IPTABLE duplicate values
I'm new to IPTABLES and when I execute the following command
/sbin/iptables --list -n | grep 16381
I could see multiple entries as shown below :
ACCEPT tcp -- a.b.c.d 0.0.0.0/0 ...
2
votes
2
answers
641
views
"Unable to connect to the MKS: Too many socket connect attempts" when trying to launch a virtual machine in VMware Workstation Pro 14.1.1
I am trying to launch a virtual machine in VMware Workstation Pro 14.1.1. Host: Windows 7 SP1 x64 Ultimate. Guest: Microsoft Windows 10. I get the error message "Unable to connect to the MKS: ...
0
votes
1
answer
172
views
Systemctl Socket Talking to the Wrong Process
I'm trying to run a Minecraft server on VM running Debian 10. I've set up the server to run as a service and am attempting to use a socket listening to a FIFO based on this question that last saw ...
0
votes
1
answer
371
views
How can I identity which process is sending data to a certain host on Linux?
As per title, I want to figure out the process responsible for certain traffic. I can see the traffic in wireshark, but I don't know which process it is.
Is there any straightforward way to do it? I'm ...
1
vote
1
answer
1k
views
How raw sockets work?
Recently I developed a packet sniffer in python using socket module. In order to do that, I created a socket of type raw. Then I started receiving and parsing packets.
My assumption was, by default, ...
-2
votes
1
answer
161
views
How to investigate why a computer stops a TCP connection?
I've just written this question on another StackExchange site, but I was advised to ask the same question here.
I would like to broaden the question: how can I know why a host closes a TCP socket ...
2
votes
0
answers
1k
views
Can apache httpd listen on a unix socket?
I would like httpd (Apache 2.4.x) to serve HTTP requests
over a UNIX domain socket. The Listen directive
doesn’t seem to allow for specifying sockets. Is there perhaps
another (undocumented?, module?) ...
0
votes
1
answer
553
views
Address of a Transport layer?
In TCP/IP protocol stack following protocol level addresses exists:
Data Link layer - MAC address
Network layer - IP address
Transport layer - ?
Application layer - Socket address which is ...
1
vote
0
answers
32
views
TCP server device for USB access readers
I have a BarCode reader that spits out data over a Virtual COM port (RS232 Serial) through a USB cable. I have a server running and managing a facility, and I need to read data coming off the BarCode ...
0
votes
3
answers
434
views
Connect a socket to another PC in same NAT
Hey I've got two machines on the same network. They get their IP info back from an external webserver. Same IP due to NAT but different ports locally. Hmm that's weird.. they can't socket up or even ...
2
votes
0
answers
1k
views
WebSocket connections originating from local network all use same client-side port (instead of ephemeral) when connecting to local webserver - Why?
I set up a webserver on a virtual machine on my home desktop. I have my router forward several ports (80, 443, etc) to my desktop, when then forwards them via NAT to the virtual machine (see diagram ...
1
vote
0
answers
294
views
Bash: read from socket file descriptor returns always the same data instead of blocking
I have a postgres started like this:
exec 3< <(su -l postgres -c "/usr/local/pgsql/bin/postmaster -p '$port' -d 3 -D '$backupDir' 2>&1 & echo \$!")
This redirects all logs ...
0
votes
1
answer
3k
views
Increase buffer size for a specific socket on Linux
I am using CentOS7 and I have to increase the send buffer size (SO_SNDBUF) on a socket listening on a specific port. The application that has the port opened does not natively support this.
Few things ...
2
votes
1
answer
2k
views
Exit foreground script Powershell: script hangs and Ctrl+C doesn't work
I have a powershell script running as follows:
> $client = New-Object System.Net.Sockets.TCPClient('x.x.x.x',443);$stream = $client.GetStream();[byte[]]$bytes = 0..65535|%{0};while(($i = $stream....
0
votes
0
answers
212
views
How to create unix socket
I am installing HAProxy from source. My example conf file tries to configure a socket
stats socket /var/lib/haproxy/stats level admin
How can I create such a socket? I'm on CentOS 7.
1
vote
0
answers
763
views
systemd StandardOutput redirection does not work with a systemd socket
I have a systemd service like this (my-server.service):
[Unit]
Description=My Server
After=syslog.target network-online.target my-server.socket
[Service]
Type=simple
ExecStart=/usr/bin/java myserver....
1
vote
0
answers
43
views
understand ss -to4 output for a jdbc connection
My application connects to a database over JDBC, and performs a lot of sequential inserts. There is only 1 JDBC connection opened by the application. As the performance is not as expected, I started ...
0
votes
0
answers
170
views
Why can't I access HTTP server running on my machine from outside the local network?
I'm running a HTTP server on my Ubuntu 20.04 on port 8000 using python3.
I already did the port-fowarding on my router (and also tested by hosting a Minecraft server and asking a friend to join) but I ...
0
votes
1
answer
460
views
Can I use a smart socket with an input voltage of AC 120V and plug it into a 220V outlet?
Using a Smart Socket
Model SP10
Made by Teckin
It's meant for use in the USA with 120V power outlets but it is being used in the Phillipines with 220V power outlets.
0
votes
1
answer
422
views
Python sockets protocols have the same value
So i am reading this book and in chapter about packet sniffing i uses this
s = socket.socket(AF_PACKET, SOCK_RAW, sock.htons(0x0800))
I looked up to which protocol has the value 8 since htons(0x0800)
...
3
votes
1
answer
2k
views
Using socat for SOCKET-SENDTO
I'm trying to use socat to send a raw packet to an ethernet interface, but I get "No such device or address". How should I be using socat?
Usage:
$ echo hi | sudo socat - SOCKET-SENDTO:17:3:0:...
0
votes
1
answer
1k
views
how to solve “No if updown configuration found” for CAN bus interface Linux 18.4.4LTS
I am trying to get SocketCAN interface working. I've added the slcan0 adapter and trying to run candump slcan0 at a bit rate I am sure the CAN devices is running at. I dont see any data being printed ...
0
votes
1
answer
32
views
How does a cloud NAS manage to be accessed from the outside of a LAN through an app?
I have a cloud NAS within my home network and I can't figure out how it manages to be accessed from the outside through an app. How does the app always know at what address requests should be sent, ...
4
votes
1
answer
4k
views
How can I know what is preventing my socket to bind to localhost:50060-50959
I am using this Python code to listen to a port on my Windows 10 system:
import socket
for port in (50059, 50060, 50959, 50960):
try:
print(socket.socket(socket.AF_INET, socket.SOCK_STREAM)....
1
vote
2
answers
272
views
Why can I access nginx but not a C server socket in my server at home?
I have a Debian server machine at home with NGINX. Right now it is only serving the default index.html that installs along with nginx. I got myself a hostname in Dynu and got TLS certificates with Let'...
2
votes
1
answer
480
views
pfctl divert-socket in mac os?
I'm messing with divert sockets in OSX, and in order to capture any socket, I first need to set up a firewall redirection (divertion if you will):
ipfw add divert 3282 tcp from any to any
Something ...
1
vote
3
answers
449
views
Client to Client Communication bypass Firewall?
I have got a Raspberry Pi which is communicating via sockets with my PC. If I’m running this setup at home everything is working fine. But in my university I cant even ping the Raspberry Pi
Would it ...
1
vote
1
answer
694
views
What is the equivalent of "/tmp/.X11-unix/X0" on Windows when using things like Xming?
I want to know what exactly does the display name like :0.0 mean on Windows. Where does Xming place its listener socket for others to find? When I set the "Display location" in PuTTY, where does it go ...
0
votes
1
answer
99
views
Unknown IceCast fails
I have a node.js script, which works in daemon mode. The script reads IceCast ogg stream itself (on the fly) and sends audio tags to website. But sometimes (exactly once per 2 days) the script fails ...