Questions tagged [socket]

A socket is an abstract network construct with a sending and receiving side. In most modern operating systems (OS) there are device representations, and programming tools to address sockets.

Filter by
Sorted by
Tagged with
0 votes
1 answer
36 views

php-fpm creats only one socket file

I have multiple virtual hosts with unique domain names, users, and root directories for each on Nginx and php8.1-fpm. In the /etc/php/8.1/fpm/pool.d/domain.com.conf contains user = domainuser group = ...
FlourishDNA's user avatar
0 votes
1 answer
76 views

Python gethostbyaddr being slow

I'm facing an issue today I can't explain and I'm hoping someone will be able to put me in the right direction. I have a fleet of EC2 servers running a python script. When a user connects to my ...
Cyril N.'s user avatar
  • 626
0 votes
0 answers
36 views

Can not ExecStart service python script as root on Linux

OS: Ubuntu 20.04.6 LTS I created a service that executes python script checker.py. The problem is this service does not execute python script with root privileges, although sirjay user has root ...
sirjay's user avatar
  • 97
0 votes
0 answers
189 views

Portainer can't access docker socket without chmod 666 workaround

Environment: Alpine Linux (3.18) I've got a portainer docker container that can't access the docker socket. I've added my user to the docker group. I make the container with the following command: ...
m4p85r's user avatar
  • 315
0 votes
0 answers
51 views

AppArmor rule to allow QEMU to create a char device socket in a directory

Given the following command line for QEMU (from this page): qemu-system-x86_64 -machine accel=kvm -cpu host \ -m $mem -object memory-backend-file,id=mem,size=$mem,mem-path=/dev/hugepages,share=on \...
Ken Y-N's user avatar
  • 113
0 votes
0 answers
43 views

PHP Error waiting on socket

I'm getting problems with ssh2 and fread php function that started on a few days. On the apache error log show: ssh2_connect(): Error starting up SSH connection(-9): Error waiting on socket fread(): ...
user1505698's user avatar
0 votes
2 answers
639 views

Fork connections out from a single socat connection

I have an old legacy application I’m trying to get to work with our semi-modern network. This application sends log messages as HTTP requests (one log per request) but does so over a single TCP ...
borog1852's user avatar
-1 votes
1 answer
1k views

ping 100% packet loss - can't ping to server

when I try to ping my newly created server it shows: vasanth@vasanth-client:~$ ping -c 4 server.ip.name PING server.ip.name (server.ip.address ) 56(84) bytes of data. --- server.ip.name ping ...
Vasanth Vel's user avatar
1 vote
0 answers
578 views

clamav-daemon doesn't create /var/run/clamd.ctl

I installed clamav-daemon on Debian 11 and when I try to start it, it doesn't create the LocalSocket /var/run/clamd.ctl. LocalSocket in my /etc/clamav/clamd.conf: LocalSocket /var/run/clamav/clamd....
afriend's user avatar
  • 111
0 votes
1 answer
90 views

How to track file lifetime using lsof?

I have read article https://tailscale.com/blog/case-of-spiky-file-descriptors/ where author investigates anomalies with the amount of open file descriptors. He said that made snapshot of open files ...
1 vote
1 answer
670 views

Start Apache on-demand using systemd socket activation

I have a local website on Debian 11 which is rarely used so I thought I might want to start Apache using systemd socket activation when visiting the site and then shut down after few minutes of ...
Matteo's user avatar
  • 111
0 votes
1 answer
116 views

How do I setup a SSL certificate for an express.js server behind a load balancer?

I'm restructuring my server structure by splitting them up instead of running everything from one server. I looked here but that just specifies what I were already doing in the original setup with ...
ii iml0sto1's user avatar
1 vote
0 answers
618 views

Client Listening on 0.0.0.0 when custom network interface doesn't exist?

I'm facing an issue in our environment where I'm starting a ServerSocket (Java), and configuring it to listen on 0.0.0.0. Then I'm creating a network interface, and my client is attempting to connect ...
Aditya Chandel's user avatar
0 votes
2 answers
2k views

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

EDIT: The following describes my original question, but as long as I haven't resolved the issue yet, I thought maybe I should change settings inside the created mysql POD instead of mysql config files ...
best_of_man's user avatar
1 vote
1 answer
1k views

Which machine is actually closing the TCP socket and why?

I'm working on a C# application, handling TCP sockets. I have a server application (Hercules) on the remote machine, trying to keep a socket open. I have my application on my machine, subscribing to ...
Dominique's user avatar
  • 123
1 vote
0 answers
76 views

Reached pm.max_children, High sockets allocated, No CPU usage

The issue I have a server that reaches pm.max_children (200) without spike in CPU usage. No network traffic (MB out / MB in) but extremely high number of socket allocated that do not get closed. CPU: ...
Aidvi's user avatar
  • 46
3 votes
0 answers
196 views

How to tell whether a linux tcp socket had recent activity?

Most of the time, when changing or upgrading a network service, I would do this during maintenance hours but some services are rarely used so it is tempting to just check whether it is currently in ...
Gamification's user avatar
1 vote
0 answers
202 views

How to open communication PYTHON socket with a SERVER SOCKET on AWS EC2 to a CLIENT SOCKET on my local pc?

Sorry my english is not good I want to established connexion from my client socket on my local pc to a host server socket on AWS EC2 instance. I'm trying to follow suggestions from here and code from ...
Citoyen x14's user avatar
1 vote
0 answers
47 views

How are Linux ACLs different for files versus sockets

With umask 0022, using default ACL entries default:user::rwx, default:group::rwx, default:mask::rwx and default:other::rwx for a directory, files created with touch (e.g.) have a mask of rw, and ...
Larry's user avatar
  • 11
1 vote
0 answers
219 views

How to create multiple pools on LEMP Stack, PHP 8.1?

I need to optimize my web app performance, with that in mind I created two PHP-FPM pools for frontend and backend and their respective users. Both pools are listening to different sockets on /etc/php/...
AtomX's user avatar
  • 125
1 vote
1 answer
894 views

Does information piped through a Unix socket touch disk?

I'm trying to understand how fast different IPC mechanisms are, and I know it's possible to create a Unix Socket as a "file" in a directory on a filesystem, but what I don't understand is ...
Christopher Shroba's user avatar
1 vote
0 answers
69 views

Sockets: divergence in behaviors between linux and windows when binding to INADDR_ANY *and* another address with the same port

Say one attempts to bind two sockets respectively on the two addresses "0.0.0.0:12345" and "127.0.0.1:12345". Depending on the platforms I tested this on, the behavior changes. On ...
Fabio A.'s user avatar
  • 111
0 votes
1 answer
719 views

kubernetes pod with a socket connection not firing 'close' event

I have a Kubernetes deployment where a pod connects to a client via TCP Socket. On connect and disconnect different events happen. In the dev environment the server can respond to connections, data, ...
Kasey Chakos's user avatar
0 votes
0 answers
504 views

configure inactivity timeout while handling keepalive probes

I am developing a TCP echo server using python and the socket library. I'd like to have a timeout configured for each incoming connection. So to drop and close them if there is inactivity for a ...
rebatoma's user avatar
  • 101
0 votes
1 answer
750 views

Ansible - No such file error when activating systemctl Podman user socket

I am running an Ansible playbook on a fresh Oracle Linux 8 system. It includes a step where it asks systemctl to activate a user Podman socket like so: - name: Enable podman socket vars: userid:...
hpy's user avatar
  • 855
0 votes
1 answer
314 views

Hosting a Python sockets server on the web

I made a simple chat app for my friends and I to use, but I don't want to host the server on my computer, I want to host it on the web. Does anyone know any good services or tutorials on doing this?
JKru's user avatar
  • 1
1 vote
1 answer
998 views

IPTables log connection pid on OUTPUT chain

I'm trying to find pid of a socket using iptables OUTPUT chain log, or even better adding it into the log. My current iptable rule: sudo iptables -A OUTPUT -j LOG --log-prefix='[PID]' --log-level 7 --...
Or Yaacov's user avatar
0 votes
1 answer
172 views

PHP socket connection through XR300 router to a receipt printer

I have a PHP application which is attempting to open a socket connection to a printer through my router. A couple things to note - my networking skills are lacking so I may be missing something ...
EvilZebra's user avatar
  • 103
1 vote
1 answer
1k views

Failed to get properties: Unit name [email protected] is missing the instance name

I've recently upgraded my MariaDB servers from 10.1 to 10.6 and now when I restart services for example wildfly, I get this message : sudo service wildfly restart Failed to get properties: Unit name ...
Ror's user avatar
  • 323
2 votes
1 answer
2k views

How do I create a python 3 service that uses socket with systemd?

I am trying to create a service with systemd, where I use python3 to create a simple socket and leave it as a daemon, but I have made several attempts but in both cases without any success. For today ...
David Moran's user avatar
2 votes
2 answers
834 views

Fail2ban socket permissions reset on reboot

I have some specific group/permissions set for my fail2ban.sock file to make Zabbix able to monitor Fail2ban as described here https://github.com/hermanekt/zabbix-fail2ban-discovery- I added the ...
ihorc's user avatar
  • 43
0 votes
1 answer
672 views

Mysqli access denied , using UNIX socket [duplicate]

I am trying to learn PHP, and I am setting up the database connection. On Mysql Workbench, I created a database called php, and created a table. Then I created the account "sam"@"...
Sam's user avatar
  • 25
3 votes
2 answers
21k views

Why am I getting "Connection refused"?

I am running a hello-world http server on an ubuntu EC2 instance, let's say, myurl.com. I am unable to curl it from my client: $ curl myurl.com:4296 curl: (7) Failed to connect to ...
Ruby's user avatar
  • 139
2 votes
1 answer
3k views

Socat - is it possible?

Is there any way to listen and execute a command ( for every connection ) while port forwarding with socat? A non-working example to make it more clear: socat TCP-LISTEN:8080,reuseaddr, "exec:ls&...
hyogy's user avatar
  • 23
0 votes
1 answer
437 views

Not seeing a packet sent from a client to the server in Wireshark

I am new to socket programming and have a couple of questions. For the context, I have a server and client with each having a socket opened: the socket on the server is bounded to INADDR_ANY which ...
Jazzy's user avatar
  • 101
3 votes
0 answers
618 views

How to find out which kernel module opened a socket?

When I try to find the process for an opened socket using e.g. ss I get the following output: ❯ sudo ss -tulpen Failed to open cgroup2 by ID Failed to open cgroup2 by ID Netid State Recv-Q Send-Q ...
sneusse's user avatar
  • 131
1 vote
1 answer
771 views

ssh port forwarding with permament connection between remote and destination

I know you can use ssh to forward a local or remote port to another destination and port. So for example let's say I have this command: ssh -L *:8443:10.0.0.1:443 [email protected] So this allow to open ...
Bemipefe's user avatar
  • 115
2 votes
1 answer
498 views

Start systemd socket on VPN connection automatically after boot

One of my servers is setup so that it will automatically connect to a VPN after booting up using a systemd service. Now I want to host a systemd socket on this VPN connection. And the socket should ...
rollstuhlfahrer's user avatar
0 votes
0 answers
2k views

Curl : Recv failure : Connection Reset By Peer and Unix Socket Crash

I'm trying to set up a unix socket for gunicorn and to ping it from curl (running curl --unix-socket /run/gunicorn.sock http://www.example.com --trace-ascii dump.txt). Unfortunately, the response from ...
NSinha's user avatar
  • 1
-1 votes
1 answer
865 views

Python sockets: TCP errors in linux, while same program works fine on Windows10

I'm trying to communicate with a commercial power supply device via TCP/IP using python sockets. I tried using both a virtual linux(centos8stream) and virtual windows10, both running at the same ...
Cenkoloji's user avatar
1 vote
2 answers
4k views

How to open a socket on EC2 instance?

I want to send webcam video from my laptop to aws EC2 instance. I'm trying to follow suggestions from here and code from here. The issue I'm facing is that I do not know how to open a socket and ...
mirzaD14's user avatar
0 votes
1 answer
705 views

Serving multiple socket using gunicorn and Nginx cause a NotFound error

I am trying to serve two Flask apps using Nginx as a reverse proxy. In my default.conf which I have reloaded using sudo service nginx restart I have got: location /app2loc/ { include ...
G M's user avatar
  • 103
3 votes
1 answer
7k views

How to share unix domain socket between containers without named volume?

I have two containers A and B which needs to talk via unix domain socket created by A in /var/run/notif.sock. I can't use named volume as sharing /var/run between containers is risky as it contains ...
Ankur Sao's user avatar
2 votes
1 answer
4k views

How to change the docker.socket group

I am managing several compute hosts running Ubuntu 18.04 (with systemd) and Docker inside a mostly trusted network. I have an auth server so rather than manually add users to the docker group, so that ...
WiringHarness's user avatar
0 votes
1 answer
2k views

simple systemd service and socket failing

I had a service I was trying to run this way but it was slightly a large python program. I took a step back and built a dead simple python program to see if I can get it to run. It fails when I try ...
Codejoy's user avatar
  • 139
0 votes
1 answer
227 views

Simple code running in systemd exits to fast?

I had this old code base running in xinet d. It was basically a simple python script that waited for standard in to come in on a socket, it would do something with it and respond on standard out. ...
Codejoy's user avatar
  • 139
0 votes
0 answers
260 views

Ububut 18.0.4 LTS:- unable to start TCP/UDP discard service on port 9 and time service on port 37

I have ubuntu client 18.0.4, I am unable to telnet localhost on port 9 and port 37. root@ubuntu:~# telnet 127.0.0.1 37 telnet: Unable to connect to remote host: Connection refused root@ubuntu:~# ...
NetworkCode's user avatar
2 votes
1 answer
539 views

OpenDKIM's UNIX socket and permissions for "others"

Postfix installation procedure created a system user postfix and it's primary group postfix while installation procedure for OpenDKIM created a system user opendkim and it's primary group opendkim. To ...
71GA's user avatar
  • 373
1 vote
0 answers
1k views

nginx logging to unix socket fails with protocol error

debian stable, nginx version: nginx/1.14.2 I get the following error message (error.log) : connect() failed (91: Protocol wrong type for socket) configuration file : access_log syslog:server=unix:/var/...
Nozz's user avatar
  • 13
1 vote
0 answers
445 views

Enable GRO for UDP port explicitly

I am implementing a simple socket application in python and I need it to receive UDP packets with GRO enabled. I have checked that only the Python service is running and that GRO is enabled via ...
tombjarne's user avatar

1
2 3 4 5
12