The tag has no wiki summary.

learn more… | top users | synonyms

16
votes
2answers
6k views

Unix socket vs TCP/IP host:port

Could someone please describe to me the pros and cons of using a Unix socket file vs a tcp/ip localhost:port when setting up services on a server (Ubuntu, FWIW)? In this particular instance it's for ...
13
votes
4answers
11k views

How to find other end of unix socket connection?

I have a process (dbus-daemon) which has many open connection over UNIX sockets. One of these connections is fd #36: =$ ps uw -p 23284 USER PID %CPU %MEM VSZ RSS TTY STAT START TIME ...
13
votes
3answers
7k views

What's the difference between Unix socket and TCP/IP socket?

It's from this answer: http://stackoverflow.com/questions/2482411/is-this-pdo-bug-fixed-now/2482424#2482424
8
votes
2answers
7k views

Need to increase nginx throughput to an upstream unix socket — linux kernel tuning?

I am running an nginx server that acts as a proxy to an upstream unix socket, like this: upstream app_server { server unix:/tmp/app.sock fail_timeout=0; } server { listen ...
7
votes
3answers
7k views

How do I configure Nginx proxy_pass Node.js HTTP server via UNIX socket?

I am trying to configure a Nginx server to connect to a Node.js HTTP server via a UNIX domain socket. The Nginx configuration file: server { listen 80; location / { proxy_pass ...
7
votes
3answers
21k views

How to get a linux network log?

We have a java server running in linux at a specific port that accepts persistent connections for thousands and thousands of users. Recently our clients are not able to connect with a time out error. ...
6
votes
3answers
6k views

How to automatically restart a service on failure in Linux

On Windows, you can set what should happen if/when a service fails. Is there a standard way of achieving the same thing on Linux (CentOS in particular)? A bigger part of my question is: how do you ...
6
votes
2answers
3k views

Create Unix Named Socket from the Command Line

Is there a command similar to mkfifo but for domain sockets?
6
votes
1answer
3k views

Apache in linux-vserver won't start, can't create socket

During extensive research and testing to write a proper question worthy of stackexchange I found a solution: rebuild the libapr1 package inside the guest.I thought I'd nevertheless post this ...
5
votes
2answers
2k views

Does Mac OS X throttle the RATE of socket creation?

This may seem programming related, but this is an OS question. I'm writing a small high performance daemon that takes thousands of connections per second. It's working fine on Linux (specifically ...
5
votes
4answers
6k views

Max number of socket on Linux

It seems that the server is limited at ~32720 sockets... I have tried every known variable change to raise up this limit. But the server stay limited at 32720 opened socket, even if there is still 4Go ...
4
votes
3answers
247 views

How to get sockets which are listening on a specific port in linux?

An application may be binding multiple sockets to a specific port,how can I get those sockets command line?
4
votes
2answers
923 views

Why can't I attach a screen session

I've got a screen session running which I would like to :quit, but I can't because when I try to re-attach, I get an error saying it can't open my terminal. I'm sure I could kill the daemon or ...
4
votes
2answers
1k views

Postgres application tries to use incorrect socket file

I have a local postgres server running (on ubuntu linux). It is listening via a socket file: $ ls -la /var/run/postgresql/ total 8 drwxrwsrwx 2 postgres postgres 100 2011-04-15 19:06 . drwxr-xr-x ...
3
votes
3answers
5k views

How do you determine what type of CPU socket a linux computer has?

What Linux command/program can I use to tell me what type of CPU socket a Linux desktop has? I use CPUZ or SIW on windows, and I can use "cat /proc/cpuinfo" on Linux to get the rest of the ...
3
votes
1answer
925 views

When to use a MySQL socket and when to use a host:port?

Many applications allow me to connect to Mysql using a username, password host and port. Some allow me to configure a socket instead of the host:port. Is there any clear benefit of one over the ...
3
votes
2answers
4k views

nginx not able to connect to php-fpm socket

I setup a system similar to the tutorial here: http://vladgh.com/blog/varnish-nginx-and-php-533-ubuntu-1010 I'm having issues with nginx connecting to the php5-fpm socket, but from what I can tell ...
3
votes
3answers
569 views

python reports socket in use, netstat and others claim its not

We have a strange socket issue with a RHES3 box: Python 2.4.1 (#1, Jul 5 2005, 19:17:11) [GCC 3.2.3 20030502 (Red Hat Linux 3.2.3-52)] Type "help", "copyright", "credits" or "license" for more ...
3
votes
1answer
335 views

Determine if TCP socket is in kernel-space

I have no problem finding out if a socket belongs to user space - I simply scan /proc/ to see which PID owns the [socket]. But with TCP sockets open in the kernel space there is no entry in /proc/ ...
2
votes
2answers
1k views

vmware virtual sockets vs cores per socket

VMware configuration give me various options for upgrade the cpu of the virtual machine. Number of virtual sockets Number of cores per socket If I need 4 cpu in my linux box, which is better for ...
2
votes
1answer
56 views

What is the most efficient way to connect my application on one VM to my Postgres DB on another VM?

I have 1 physical machine with 2 VMs (VMWare esxi) - one for database (PostgreSQL 9.2.1), and one for application. I'd like my application to connect to my database in an efficient way, and I've heard ...
2
votes
3answers
3k views

CUPS printing via socket very slow

I don't find anything suitable on this topic: we have a Solaris server, running CSW CUPS and several network printers. Printing using LPD is fast, but when we try socket or SMB, it is painfully slow ...
2
votes
1answer
100 views

Create a link to the Unix socket [duplicate]

Is there a possibility to create a hard link for an unix socket? I'm creating a jail and symbolic links won't work, so I'm looking for a solution, how to provide an unix socket inside chrootted ...
2
votes
0answers
322 views

How to solve SocketException: Permission denied: connect

I recently encountered a problem that is giving me a headache and I need help ... The System consists of two subsystems, called A and B, each running on a standalone Tomcat instance and currently ...
2
votes
0answers
87 views

How do I find the path of socket?

Is there any method that can allow me to find the path of socket if the type of socket is PF_UNIX? And I have another question: let's assume that I have the following output of lsof: COMMAND PID ...
2
votes
0answers
304 views

Unix socket connection limit

This may appear like an already discussed/answered question. But I am specifically looking for info which I couldn't find anywhere answered clearly. I have an Nginx + php-fpm setup which uses unix ...
2
votes
1answer
678 views

Maximum limit of filepointer in php reached and not changeable

I have a server with the current 5.3.x version installed. Since we are running a really simple and small server in php using sockets, that connects to a lot clients using sockets we need to raise the ...
1
vote
2answers
23 views

When a socket switch to TIME_WAIT state, why I can't see its inode number?

I'm developing a program in python that parses /proc/net/tcp informations, but unfortunately, while I was doing this, I saw a strange thing. Practically, when a socket change in TIME_WAIT state, ...
1
vote
1answer
141 views

Do keepalives to socket connections exist?

Pre briefing: Although my question is broad on purpose, I am dealing with nginx connecting to php-fpm (fcgi), which is served via a local socket (/tmp/somesocket.socket). Nginx has a setting to ...
1
vote
2answers
188 views

Can no longer open files in linux server!

We have a linux server running fine in prod for weeks, until our user base started to grow and our java server started to fail in many places! It turns out that all files and sockets are failing ...
1
vote
2answers
75 views

How do communcations through ports works [closed]

I was studying socket programming and certain questions came to my mind. These are some beginner level doubts Is it mandatory to to use well known port for a particular application. For example if i ...
1
vote
2answers
2k views

TCP performance differences between RH Linux and Solaris in java?

While comparing java TCP socket performance between RH Linux and Solaris, one of my test is done by using a java client sending strings and reading the replies from a java echo server. I measure the ...
1
vote
1answer
526 views

Why would a client send a RST packet as reply to a SYN,ACK?

I have a HTTP webservice where sometimes the connection setup fails in a strange way: client sends a SYN packet server sends a SYN,ACK reply client responds with RST In which situations could a ...
1
vote
2answers
776 views

Linux server resend SYN ACK

I am troubleshooting a connection timeout problem between two Linux boxes, where it seems the ACK to SYN-ACK was lost on the server's stack. The tcpdump is done on the server side. The client got ...
1
vote
2answers
67 views

Communicating between two servers sitting behind their respective NATs

I'm building an web app (Server A) that communicates with a remote server (Server B) that is connected to the internet. Server B resides behind a NAT and is listening to communication on 3 ...
1
vote
2answers
279 views

TCP vs UDP Error-Checking

I've bounced upon two articles that describe in-depth on how TCP and UDP connections work. However there is some kind of inconsistency. Where one article tells me that UDP does no Error-Checking at ...
1
vote
3answers
2k views

ERROR 2002 MYSQL socket /tmp/mysql.sock

A have already read everything about this error but I coundn't solve the problem. ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (38) I'm trying to install ...
1
vote
1answer
1k views

Setting up PHP 5.4 with MySQL to use Unix Sockets

I've compiled PHP 5.4.5 from source, and I've installed nginx 1.2.1 and mysql 5.1.63-0ubuntu0.11.04.1 from apt-get on my Ubuntu 11.04 LTS server. I installed nginx using this: add-apt-repository ...
1
vote
2answers
108 views

Problems with firewall when forwarding 8080 thru Comtrend5071T

I am trying to forward port 8080 thru my modem but i have not been successful. to be exact my desired route is as follows: Connection to Server A (192.168.0.5) is tested as working ...
1
vote
2answers
384 views

Performance: mysql socket vs. mysql remote

I'm running a couple of projects which consume a lot of MySQL power (10'000 qps in peaktimes)...now I'm wondering what would be the best setup in order to keep it fast and smooth even if the user ...
1
vote
1answer
100 views

Increase number of connections per socket

How do I increase the number of connections each socket can accept? I know that you can increase the total number of connections using: # sysctl kern.ipc.somaxconn=4096 But each connection is then ...
1
vote
1answer
172 views

Uwsgi and flask with unix socket instead of URL

I was trying to find out the difference between a socket as a unix file and a socket that is a ip and port. If I switch something like uwsgi to use a file instead of a port and ip, how do I then ...
1
vote
0answers
198 views

Suphp connection reset by peer in error logs

In my Linux server's logs I have this record nearly every 5 minutes. I couldn't find the reason for two weeks and I would be very happy if you can recommend me a way to diagnose the problem. It is ...
0
votes
3answers
204 views

Socket and Swap Space

I have a system that is running out of memory and has a lot of open connections. but my swap space is not being used up that much. Can socket/socket file descriptors use swap space? This is for a ...
0
votes
1answer
55 views

Allow user to bind only certain ports on Linux [closed]

Welcome, I'm looking for equivalent of mac_portacl from FreeBSD. I want to assign to one user only certain ports. Filtering it by iptables isn't enough, because when process works, the port is blocked ...
0
votes
1answer
98 views

Updated php5-fpm, can't use socket anymore

Earlier today, I updated packages on one of my servers. One of those packages was an update to php5-fpm, which seems to have broken my ability to utilize unix:/var/run/php5-fpm.sock. Disclaimer: I ...
0
votes
1answer
240 views

Is there a system wide limit to the total amount of socket & queue buffer space?

in Linux I know that you can tweak the maximum buffer size per socket connection, but is there a system wide limit to the amount of space the buffers can take up and does this apply equally to the ...
0
votes
3answers
72 views

Xeon sockets and interoperability (upgrading)

So it looks like for the most part Xeon motheboard sockets are fairly standardized. If I order a new server with a Xeon proc would I be able to expect to upgrade to any processor in the Xeon family ...
0
votes
2answers
452 views

Is there a Windows app out there that can pipe command line arguments into a TCP socket connection?

I haven't needed anything like this before but I'm sure something exists. I'm looking for a compiled Windows executable (i.e. noninterpreted language) that I don't need to write that can read the ...
0
votes
1answer
173 views

Socket based byte counts

I see a lot of tools to get the RX and TX byte counts for transmission on interfaces, is there any tool/program that I can use to get a total transmitted byte count for a single specified socket? I'm ...