Questions tagged [file-descriptors]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
1 answer
4k views

using named-pipes to control a remote ssh session in BASH

My question is mostly based on this https://stackoverflow.com/questions/22479631/pipe-timely-commands-to-ssh?rq=1 I am following above question and I am able to connect to a server, like this: ...
1 vote
1 answer
1k views

how to see the verbose output of a process that is running that writes to a file (shred)

I am running the shred command to securely wipe some storage. I would like to see its progress, but have lost the ssh terminal that was running the command. Is there a way that I can use to see the ...
3 votes
1 answer
261 views

Why does xinetd try to close file descriptors on startup?

I have xinetd running inside a docker container (base image centos:7) on a rockylinux 9 host machine. On starting xinetd service in the docker image, it appears to hang. So I used strace, and found ...
0 votes
0 answers
1k views

Ubuntu 21.10 ulimit (open file descriptors) not applying correctly

The situation is strange because I have 2 identical servers with the same application but on one server i get a ulimit error from the custom application ulimit error: too many open files but on the ...
-1 votes
2 answers
734 views

Is it actually possible to send some data to remote destination over tcp/ip without any socket? [closed]

I am studying socket concept. As far as I learned socket is like electrical socket that is created in both end of communicating devices (or processes). Socket can keep itself alive forever to listen ...
0 votes
1 answer
182 views

When process writes to pseudoterminal slave, why it doesn't read what it wrote?

Here is my bash session: lrwx------ 1 stas stas 64 Mar 5 18:18 0 -> /dev/pts/0 lrwx------ 1 stas stas 64 Mar 5 18:18 1 -> /dev/pts/0 lrwx------ 1 stas stas 64 Mar 5 18:18 2 -> /dev/pts/0 ...
0 votes
1 answer
622 views

User permission to create new File Descriptor

On CentOS 8 I have a Bash script which uses a non-standard file descriptor (/dev/fd/5) and needs to be executed by a standard user (not root). When the user executes the script it receives tee: /dev/...
2 votes
1 answer
3k views

how to count the open files without lsof [closed]

we have in our cluster more then 800 rhel machines - version 7.2 since lsof | wc -l take too much time ( sometimes 3-4 min ) , in order to get the current open files we want to know if there are ...
1 vote
0 answers
3k views

How to interpret the number of open and max file descriptors for nginx?

I want to get the currently open file descriptors and upper limit of open file descriptors on an AWS Linux instance. The reason is to determine whether to increase the limits for nginx to have enough ...
0 votes
1 answer
425 views

Find out who hold the fd of one file which has been deleted?

Currently, I run a Java program will call some C++ library, and I find that after some files have been deleted, there still some thread holds the fd such as 3515991655 0 lr-x------ 1 user ...
3 votes
2 answers
2k views

Why does writing to the console a process's STDIN is attached to doesn't send input to the application itself?

Taken from this answer: Terminal 1: [ciupicri@hermes ~]$ cat shows on the tty but bypasses cat Terminal 2: [ciupicri@hermes ~]$ pidof cat 7417 [ciupicri@hermes ~]$ echo "shows on the tty but ...
18 votes
1 answer
14k views

Ubuntu 16.04 Server MySql open_file_limit won't go higher than 65536

I'm running Ubuntu 16.04 Server on XenServer and I'm running into an issue with MySql's open file limit. Here's what I've done so far: sudo nano /etc/security/limits.conf (reference) * soft nofile ...
8 votes
2 answers
20k views

How to permanently increase RabbitMQ file descriptors limit

I'm trying to permanently increase the RabbitMQ file descriptors limit. I've already increased the system limit to 65535 and did the same for the RabbitMQ process by adding an entry to the /etc/...
0 votes
1 answer
653 views

Ubuntu 16.10 Server MariaDB (MySql) open_file_limit won't go higher than 16364

I'm running on Ubuntu 16.10 (yakkety yak) with MariaDB 10.x and experience the very same issue as Ubuntu 16.04 Server MySql open_file_limit won't go higher than 65536 with one exception, my open ...
0 votes
1 answer
241 views

Apache vhosts limit and file descriptors limits

I need to host massive websites with SSL and I've read that there is an apache vhosts limit due to file descriptors. Each domain have a SSL certificate, so unable to do a global virtualhost. My ...
25 votes
2 answers
4k views

Why does password entering work in a piped sudo command?

If I do: sudo cat /etc/resolv.conf | less It will prompt me for the password, even though less (presumably) takes stdin. Over what fd's is the password prompt shown and how does it get the input ...
23 votes
3 answers
57k views

Too many open files with nginx, can't seem to raise limit

The server is Ubuntu 13.04 (GNU/Linux 3.9.3-x86_64-linode33 x86_64). nginx is nginx/1.2.6. I've been working on this for an several hours now, so here's what I'm getting and here's what I've done. ...
5 votes
1 answer
6k views

Squid running out of filedescriptors on CentOS 7

I'm running Squid 3.3 (EPEL) on CentOS 7 and recently I have been getting the following error message in my cache.log WARNING! Your cache is running out of filedescriptors I am slightly confused by ...
2 votes
2 answers
2k views

Dangers of closing file descriptors

In the Stack Overflow question Check if a program exists from a bash script the accepted answer notes that closing stderr is dangerous: (minor side-note: some will suggest 2>&- is the same 2>/...
2 votes
1 answer
1k views

How to set up a global CustomLog on Apache2 for every virtualhost

Actually I got some issue with file descriptors on Debian Wheezy with 3.2.13 kernel and Apache/2.2.16. I would like to reduce this limit, actually each virtualhost got a CustomLog and an ErrorLog, I ...
13 votes
2 answers
17k views

Number of file descriptors: different between /proc/sys/fs/file-nr and /proc/$pid/fd?

I would like to check how many file descriptors are actually used: cat /proc/sys/fs/file-nr 12750 0 753795 The first column (12750) indicates the number of file descriptors allocated since boot....
3 votes
1 answer
6k views

Mongodb error - Out of file descriptors. Waiting one second before trying to accept more connections

Details Here is what I see in the logs file 2014-09-08T10:22:43.143+0000 [initandlisten] ERROR: Out of file descriptors. Waiting one second before trying to accept more connections. 2014-09-08T10:...
6 votes
1 answer
2k views

strace shows long time reading from mysql socket - mysql takes long time to execute query?

My Apache server takes long time to process request. I attached strace to it and can see the two following delays: 1) Very critical (143 seconds to process) 1335 0.000037 write(16, "\235\0\0\0\...
4 votes
0 answers
1k views

uwsgi through supervisor too many open files

I have uWSGI set up through supervisor on a ubuntu 12.04 box and lately I noticed that when trying to tail the logs (all the logs in that user account) I get message that too many files opened , uWSGI ...
2 votes
1 answer
4k views

Tuning tcp_keepalive_time for Node.js leak

I'm currently having a socket leak with my Node.js application. This bug is also posted here. I hope to fix this soon. CLOSE_WAIT and FIN_WAIT2 seem to be the major problem. Connections: 1662 ...
1 vote
1 answer
52 views

script reading from new descriptor in read

I have a script that asks some questions to the user and repeats the question until the user has answered something appropiate. This is done with an infinite loop that is break'd when an acceptable ...
0 votes
1 answer
2k views

Apache File Descriptor Limits

I'm trying to change the file descriptor limits for Apache. The problem is that the limits set through "/etc/security/limits.conf" don't apply to system users like "apache" with no login shell. I've ...