Questions tagged [limit]

Limiting the usage of a resource (memory, disk space, CPU time, open files, network bandwidth, …) by a process or a group of processes.

62 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
1answer
147 views

dash maximum variable length under systemd

I have a shell script that uses a single variable as an associative array (one KEY=VALUE per line). Throughout the execution of the script, the variable is manipulated to add, remove or modify ...
5
votes
0answers
420 views

Limiting per process dirty bytes without slowing down the whole system

Given a busy system with a really fast block device (highend NVMe raid, 2 GB/s write, 4 GB/s read) mounted at /data and an a really slow device (USB HDD with spinning 8 TB disk, 50 MB/s write, 60 MB/s ...
4
votes
0answers
112 views

Processes started through SSH add up to limit of SSH Daemon (systemd)

on a productive server there are (background) processes started by users which connect through SSH and run some scripts. These processes are daemons and keep on running. Each started process is found ...
4
votes
0answers
675 views

Trickle not behaving as expected

I'm using Ubuntu Trusty 14.04 64 bits. I've installed trickle network shaper from repositories and I performed some tests: No limits I executed this command to test somehow my network download ...
4
votes
1answer
2k views

Traffic shaping with tc does not work

I want to limit the outgoing traffic to a specific bandwidth. My Code: tc qdisc add dev vif1.0 root handle 1: htb default 30 tc class add dev vif1.0 parent 1: classid 1:1 htb rate 1mbit tc class add ...
3
votes
0answers
76 views

How to “soft-limit” CPU usage of a process

I have some processes running on Debian that I want to limit cpu of it usage in the "soft" manner. For example, if it eats more than 70% of a single core for more than 15 minutes, the CPU should be ...
3
votes
0answers
271 views

How to report current usage for a user on ulimits aka pam_limits etc?

Every SA sooner or later runs into a user hitting a ulimit like open files or number of processes. There must be a simple mechanism to track and test against usage of these limits, or ulimits would ...
3
votes
2answers
2k views

Limiting users ram with cgroups not working (for me)

I registred because I didn't manage running cgroups with several tutorials/comments/whatever you find on google. I want to limit the amount of ram a specifix user may use. Internet says "cgroups". My ...
3
votes
0answers
5k views

Increasing ulimit stack size benefits?

Hello I'm new in Linux and at my work I have a server that runs a banking software. The company that made the software said that the stack size should be set to unlimited. Does this make the software ...
3
votes
1answer
857 views

limiting a user's TCP transfer quota

I've been researching how to limit a user's monthly TCP download plus upload quotas. The total transfer limit is 1 TB / month . There are 50 users, so I wish to limit each user to a maximum of 20 GB / ...
2
votes
0answers
254 views

Restart a process if cpu usage is more than 90% for more than a 60sec

Normally one of my systemd services will take about 0...5% cpu Usage. In some cases it can reach up to 100% but only for some seconds. If the Service "crashes" it takes up to 100% continuously. So I ...
2
votes
0answers
603 views

scp : -l option (bandwidth limiting) doesn't work when scp-ing from a remote server to another remote server

If I do : $ scp -l 1024 remote1:/path/to/file remote2:/path/to/destination I can see, using nload on remote1, that the bandwidth used by scp isn't limited to 1024 kbits/s like I thought. I found a ...
2
votes
0answers
104 views

Using a large number of nullfs mounts to create a virtual FS on FreeBSD - what are the practical limits + impacts?

I have a situation where I'm possibly going to create a virtual file system on FreeBSD, comprised entirely of nullfs mounts of selected "ordinary" dirs within my various ZFS datasets (and their ...
2
votes
0answers
238 views

How to check usage of mqueues reliably?

I run a testing server for software that depends on the massive usage of mqueues (POSIX messages queues). I increased limits to a reasonable level and got it working a long time ago. However, the ...
2
votes
0answers
148 views

How to decrease speed/priority of file transfer (graphical)?

I regularly have big transfers of files running between two local hard drives, and at the same time some network transfers through my Internet browser. The problem is that the local transfer seems to ...
2
votes
0answers
5k views

File limits getrlimit(RLIMIT_NOFILE) failed

(32-bit system) Posted a Q/A earlier regarding Chrome crashing because of exhausted limit in open files. Chrome has since run more smooth, (after increasing limit), but still crashes from time to ...
2
votes
0answers
317 views

Can I control number of TCP Connections per second in curl?

I am trying to make one traffic generator tool in linux centOS 6.5. I am using curl for this purpose. I can generate traffic from virtual interfaces using curl but I don't know if I can control number ...
2
votes
2answers
225 views

centos5 maximum memory setting for all users

I'm using Centos5 for operating server and the machine has limited memory. There are many users using the server and some of them are running programs which use a lot of RAM. When I check the used ...
2
votes
0answers
155 views

How to limit network bandwidth after some data transferred?

So the question is in the name of topic. How to limit bandwidth I know. Using tc. But how to do so after, for example, traffic had reached 500MB. And after some time reset the limits.
2
votes
0answers
768 views

Find and close/unlink message queues in the system

I have a SLES-11 machine on which I am not the root where I am building software code that makes extensive use of message queues. Due to some bugs, Now have an error: mq_open: Too many open files I ...
2
votes
0answers
235 views

Limit CPU cycles inside of Xen

I'd like to run some minimum-expectation benchmarks on EC2, but I'm having an issue of high variability in my output data. Specifically, they keep giving me more CPU than I'm minimally entitled to, ...
2
votes
1answer
98 views

starts logging when the limits are hit

/etc/security/limits.conf. The file is responsible to limit resources of users/groups on a Linux server. Unfortunately, the file does not generate any logs (or the case could be that I do not really ...
2
votes
0answers
110 views

equivalent to 'cpusets' for gpu's

I work with clusters of computers and manage the nodes with torque and Moab. A user is able to submit a job to a node, and request the amount of resources they need. #The following submits the job ...
2
votes
0answers
319 views

Can I limit the number of inotify watches available to a process or cgroup?

I am consistently running out of inotify resources, leading to errors along the lines of: # tail -f /some/files tail: inotify resources exhausted tail: inotify cannot be used, reverting to polling ...
2
votes
0answers
2k views

Permanently change per-process stack size

When I use ulimit -s to change the per-process stack size, it only lasts for that login; if I restart the setting is lost. How can I permanently change the maximum stack size on my system?
1
vote
1answer
86 views

apache2 limits prefork

mb someone could give me some recommendation what limits should i use? I have problem with webservice in centos7-cloudlinux Cpanel server, Apache2.4. When server have high traffic in apache2 error ...
1
vote
0answers
226 views

Limit container resources both using --memory and --cgroup-parent

I'd like to limit both total memory consumption for a group of containers as well as memory consumption for a particular container. Say, a container is allowed to consume not greater than 1Gb and all ...
1
vote
0answers
15 views

Launch a program to only specific resources

Question: How can I launch a program such that it only uses X ram and Y CPU cores, etc? I happen to be using Ubuntu in this case, but since I often am on other distros, I need a general GNU/Linux ...
1
vote
0answers
309 views

What is the maximum open files limit?

I'm working on a reasonably large project, and recently had to bump the nofile setting above 500,000. I tried to change it to five million in /etc/security/limits.d/99-users-nofile.conf, but ...
1
vote
0answers
241 views

Where does a bash process get its default signal handlers/traps?

From https://stackoverflow.com/questions/50606753/do-getrlimit-and-setrlimit-work-by-reading-from-and-writing-to-etc-sec#comment88227414_50607042 Bash doesn't have a special handler for SIGQUIT ...
1
vote
0answers
207 views

How to check the shell of a running process?

I am working on Solaris 11 zone and I need to check which shell a running process is using. I have the PID but I am not sure where to get the information from. I have a scenario where some resource ...
1
vote
0answers
220 views

how to let aufs use more than 127 layers? or an alternative to it

I came to the conclusion that aufs is limited to 127 layers based on tests. (prepare) mkdir write joined {1..400} for((i=1;i<=400;i++));do echo >$i/$i.txt;done #for checks using a single ...
1
vote
1answer
1k views

Curl parallel download file list

first post sorry if I did some mess here =) Using Ubuntu 14.04lts 64bits server version. I have a list (url.list) with only URLs to download, one per line, that looks like this: http://domain.com/...
1
vote
0answers
106 views

CentOS 7 tweaking sshd config to access the machine no matter how busy its

When CentOS 7 free memory goes below 200 MB, it become unresponsive even to ssh connection. Currently I have many machines not accessible remotely in peak time due to free memory being between 80 MB ...
1
vote
1answer
345 views

Difference between behaviors of setrlimit and limit stack

I am seeing a difference of behavior when setting stack size from shell and from inside my c program. The issue is that I have a function which has a large set of local variables (large arrays). If I ...
1
vote
1answer
1k views

iptables limit inbound connections to Docker container

Running an Ubuntu 16.04 server with Docker Engine (latest version 1.12.1) and a Docker image/container based on Ubuntu 16.04 as well. I need to limit (on a specific port using TCP) both: the number ...
1
vote
0answers
186 views

is cgroups limits per user or shared across all members?

for example, group memlimit { memory { #approx 200MB memory.limit_in_bytes = 200000000; } } will all members of memlimit share 200 MB, or will each member individually get ...
1
vote
0answers
147 views

How to restrict swap space usage of application

We have a Java application hosted on (jetty server) running on CentOS machine. Every second the application will handle thousands of websocket connections which will get opened and closed again. Also ...
1
vote
0answers
54 views

getpriority returning different value on different hosts with same kernel version

I am running centos 6.6 on same type of hardware with kernel version "2.6.32-504.30.3.el6.x86_64" Has anybody seen this why the below code when compiled and executed gives a different value on two ...
1
vote
1answer
181 views

Does loginuid have any impact on process limits?

On CentOS/RHEL 6, when I start my daemon as root user, I see /proc/<pid>/loginuid of the process as 0 and when I start it through sudo, I see loginuid of the sudo user. Even if I do sudo su - ...
1
vote
0answers
139 views

How can I define time limit to a user's group per session

I have the group ABC and I need to configure a time-limit to 2min per session for its members. Like a TMOUT is only for a user, but I need for a group). How can I define time limit to a user's group ...
1
vote
1answer
823 views

How can I use arptables to limit the number of outgoing ARP requests a second?

End goal: Make a script that will limit the number of outgoing ARP requests in a second using arptables. This is to have the ability to not trip the ARP-limiting feature on Cisco devices. I want to ...
1
vote
0answers
106 views

icmp limited in many network spaces?

I wrote small script do show example usage of ip netns on unused class size C (here changed into 192.168.10) #!/bin/sh network=192.168.10 for id in `seq 0 127`; do ip netns del test-$id; done; ...
1
vote
0answers
358 views

CentOS limits.conf & cpulimit not working

I have a CentOS server I am testing things out on. In it, I have configured USERNAME hard maxlogins 4 USERNAME hard cpu 1 USERNAME hard nproc 10 in /etc/security/limits....
1
vote
0answers
96 views

Is there a limit of GPIOs that can be used in Linux?

When it comes to use GPIOs, is there a limited number that can be used in Linux (except through the limitation of the physical availability/amount of the ports/pins) or is it theoretically possible to ...
1
vote
0answers
475 views

Which filter configuration in kernel rate limit the outgoing packets to 1packet/sec?

Which net filter in kernel configuration other than iptables enable rate limiting on the outgoing packets on ethernet port?
1
vote
0answers
706 views

JVM memory limit on Linux (Debian)

When running my java program, I get following error: Exception in thread "main" java.lang.OutOfMemoryError: Requested array size exceeds VM limit I am wondering how I can increase the limits on my ...
1
vote
0answers
425 views

Limiting the total size of samba's vfs_recycle by pruning oldest deleted files first

Running SerNet Samba 4.0.9 on CentOS 6.4 serving as an AD DC and fileshare for XP clients. Added recycler per the example here. My concern is that the recycle dir will eventually grow large. ...
0
votes
0answers
20 views

AMDGPU driver vramlimit

I have a console installation of debian and i found that from the available 16GB of ram i can see only 14GB, this is because my APU (AMD) is reserving 2GB which is way too much for my needs. The bad ...
0
votes
0answers
31 views

How can df report different information depending in it's target path?

Example: root@myinstance:/my/instance/path# df -h Filesystem Size Used Avail Use% Mounted on ... /dev/mapper/hdd-place 13T 899G 12T 8% /run/iss ... root@myinstance:/my/instance/...