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

learn more… | top users | synonyms (1)

0
votes
0answers
18 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
23 views

Linux cgroups: limit CPU usage in absolute values which do not depend on CPU speed

I have a server with a 2.4GHz processor. And there are several cgroups, each one allowed to use 25% of CPU. That's equal to 600MHz. Then I replace the CPU with a faster one, let's say 3.0GHz. If I ...
4
votes
1answer
42 views

218TB XFS LVM filesystem. 144TB Free. Error message “No Free Space Left on Device”

I have a giant 218 TB RAID6, across LVM. It is actually 2 separate RAID6s joined together through LVM to form one giant RAID6. df -h shows all space was available, and I mounted to /share. I wanted ...
0
votes
0answers
30 views

threads limit on linux

My box is: x86_64 x86_64 x86_64 GNU/Linux Red Hat Enterprise Linux Server release 6.3 whan I run sample java app (does not matter how much java heap I provide!), it creates 2016 threads and dies with ...
1
vote
0answers
21 views

Limit cpu usage to one core [duplicate]

I want to run a server with user-written scripts. But these scripts should only use one core (which should be the one with the lowest usage because there will be many concurrent scripts). Also I need ...
1
vote
0answers
22 views

Process exceeding max open files limit

I am counting current open files by a process pid by :- cmd1:- ls /proc/$pid/fd/* | wc -l and then I am calculating percentage by fetching Max open Files limits. cmd2:- $ cat /proc/$pid/limits ...
-1
votes
1answer
20 views

How can I limit a log file to a certain number of most recent logs?

I know that you can limit the size of a file in respect to bytes, but I was wondering if there was a way to limit the number of logs within the file to, for example, the most recent 200 logs.
1
vote
0answers
54 views

File descriptor limits in /etc/system vs /etc/sysctl.conf vs /etc/security/limits.conf on Solaris

Let me explain first what I understood. In Solaris 10, rlim_fd_max and rlim_fd_cur in /etc/system set the hard and soft limits at the system level. And /etc/security/limits.conf sets the limits for ...
0
votes
0answers
66 views

Kill the process and restart server when memory is exceeded - bash and cron

I have a site on webfaction, using django and python. However, I have problem with memory. The problem arises, because I use external library, that can run forever (consuming much time and memory). ...
6
votes
1answer
96 views

Terminal does not accept pasted or typed lines of more than 1024 characters [duplicate]

When I enter text on stdin in an OS X Terminal, a single line is limited to 1024 characters. For example, cat > /dev/null beeps after I type (or paste) a line longer than this, and refuses to ...
3
votes
0answers
46 views

Limit the inode cache used by a command

I want to run a task with limits on the kernel objects that they will indirectly trigger. Note that this is not about the memory, threads, etc. used by the application, but about memory used by the ...
0
votes
2answers
86 views

bash execute command for X arguments at a time

I have a list of files stored in txt file. ./test7 ./test4 ./test1 ./test5 ./test6 ./test10 ./test8 ./test2 ./test9 ./test3 I want to run a command on all those files but I want to sleep 1 second ...
3
votes
1answer
57 views

GNU Parallel: How to limit max running network jobs per host

I'm using GNU Parallel for scanning a list of urls (from different hosts) for vulnerability, like this: cat urls.txt | parallel --gnu -j 50 ./scan {} The 'scan' program works for one url in one ...
4
votes
1answer
170 views

How to limit the running time of a program?

Sometimes when I write code I found that I made a stupid mistake and some loop takes almost all CPU time forever. Is there a way the running time of a program for example to 10 seconds in bash?
1
vote
0answers
27 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; ...
0
votes
0answers
115 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 ...
3
votes
0answers
57 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
127 views

chromium browser: “Aw, snap” when too many windows/tabs are open

I have noticed, when I open more than 15 chromium instances (windows or tabs), I get the "AW, Snap" error Page: Seems to me there is some limit how many instances can be running at the same time. I ...
0
votes
0answers
70 views

How to check number of connections

My server have high loads. CPU usage is low. Memory usage is low. IO is low. So I improve maximum number of connections in cpanel. Things are working. However, where can I see detail? How do I ...
1
vote
2answers
299 views

What do unlimit and limit do in the context of csh?

I'm running a csh script that calls unlimit and limit just before running a scientific model. The script looks something like so (truncated for brevity): #!/bin/csh -f # ... unlimit limit ...
1
vote
0answers
579 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
1answer
329 views

Chrome too many files open / crash / Sorry Jim

When using Google Chrome I frequently get “Sorry Jim” tabs. The browser also frequently freezes and crashes. Running it from terminal emulator show a long line of Too many open files: ...
0
votes
1answer
73 views

Mint maximum user passtext length?

Strangely, I can use a long passtext, approximately 64 words long, for disk encryption, but I'm having trouble with user password lengths. Certain steps fail like the installer or unlocking the ...
1
vote
0answers
59 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 ...
1
vote
0answers
212 views

receive signal before process is being killed by OOM killer / cgroups

In our cluster, we are restricting our processes resources, e.g. memory (memory.limit_in_bytes). I think, in the end, this is also handled via the OOM killer in the Linux kernel (looks like it by ...
0
votes
0answers
526 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 ...
2
votes
1answer
481 views

number of open files configuration not operational

Addressing an error of Too many open files I was attempting to follow the suggestions here Although /etc/sysctl.conf fs.file-max = 70000 vm.swappiness = 10 and /etc/security/limits.conf nginx ...
3
votes
1answer
326 views

Limit maximum number of concurrent scp processes running on a host

I am facing a problem where I have a fleet of servers which contain a lot of data. Each of the host runs many instances of a specific process p1, which makes several scp connections to other hosts in ...
5
votes
1answer
144 views

Can you throttle the bandwidth to a tmpfs based ramdisk?

I created a ramdisk using tmpfs as follows: sudo mount -t tmpfs -o size=1024m tmpfs /myramdisk I was looking into cgroup blkio subsystem bandwidth limits "read_bps_device" and "write_bps_device" ...
2
votes
2answers
128 views

does sudo always set process limits to the numbers from /etc/security/limits.d?

I have observed the following behavior: [ec2-user@ip-10-66-68-55 ~]$ uname -a Linux ip-10-66-68-55 3.4.103-76.114.amzn1.x86_64 #1 SMP Fri Sep 12 00:57:39 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux ...
4
votes
2answers
2k views

set packet rate limit via iptables

I have a packet rate limit (max. 10 per seconds) which is set by my internet provider. This is a problem if I want to use the AceStream player, because if I exceed the limit I get disconnected. How ...
3
votes
1answer
386 views

What are the bash shell length limitations for here-docs?

What are the length limitations for using here-docs as part of bash command lines? I am finding that short here-docs work fine, but when they get longer there is some point or structure after which ...
2
votes
1answer
703 views

How to change the kernel max PID number? [duplicate]

The default PID max number is 32768. To get this information type: cat /proc/sys/kernel/pid_max 32768 or sysctl kernel.pid_max kernel.pid_max = 32768 Now, I want to change this number... but I ...
1
vote
1answer
729 views

Daemon's open file limit is reached even though the system limits have been increased

I am running Debian wheezy. File limits are increased to 100000 for every user. ulimit -a and ulimit -Hn / -Sn show me the right amounts of maximum open file limits even in screen. But for some reason ...
1
vote
2answers
348 views

Increasing stack size in 64 bit Cygwin? (installing ocaml)

I'm trying to set up an older version of ocaml, and I'm getting an error message that says that I need to increase my stack size. The only way I've found to do this in cygwin involves running an ...
2
votes
2answers
238 views

cpulimit does not detect Node.JS process

I was able to limit python process to use only 50% CPU with the following cpulimit -l 50 -e python but when I tried to do the same for Node, and it is not able to detect the process at all. Does ...
9
votes
5answers
8k views

Limiting processes to not exceed more than 10% of CPU usage

I operate a Linux system which has a lot of users but sometimes an abuse occurs; where a user might run a single process that uses up more than 80% of the CPU/Memory. So is there a way to prevent ...
3
votes
1answer
161 views

Different between `ulimit -e` and `renice`?

I would like to run a backup script in low CPU and disk I/O. Is there any different between this: #!/bin/bash ulimit -e 19 ionice -c3 -p $$ and this: #!/bin/bash ionice -c3 -p $$ renice -n 19 ...
4
votes
1answer
147 views

FILE size limitation according to Robert Love's textbook

From Robert Love's Linux System Programming (2007, O'Reilly), this is what is given in the first paragraph (Chapter 1, Page 10): The file position’s maximum value is bounded only by the size of ...
2
votes
2answers
113 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 ...
10
votes
1answer
499 views

Limit on the number of btrfs snapshots?

I am considering using btrfs on my data drive so that I can use snapper, or something like snapper, to take time based snapshots. I believe this will let me browse old versions of my data. This would ...
1
vote
0answers
43 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 ...
10
votes
3answers
14k views

Limit max connections per IP address and new connections per second with iptables

We have an Ubuntu 12.04 server with httpd on port 80 and we want to limit: the maximum connections per IP address to httpd to 10 the maximum new connections per second to httpd to 150 How can we ...
9
votes
2answers
834 views

How to limit the total resources (memory) of a process and its children

There are plenty of questions and answers about constraining the resources of a single process, e.g. RLIMIT_AS can be used to constrain the maximum memory allocated by a process that can be seen as ...
1
vote
2answers
60 views

Why does it temporarily look like the pv command transfer limit is no longer enforced when I come out of suspend to ram?

I have this perl script and I discovered the pv command and decided to use it to get some feedback into what is going on with the randomness in terms of throughput. After a few tests1 I decided to ...
1
vote
1answer
942 views

What are the effects of increasing hard and soft limits for ldap user

I've been having some instability issues with my LDAP server. I have ~2000 machines connecting to it. Using netstat -pant | grep slapd, I can typically see 1500+ connections from the clients to the ...
2
votes
0answers
55 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.
3
votes
3answers
470 views

Is there a way to make your process use less CPU?

I want my device to use less CPU to save battery. I have a program that uses a large amount of it. nice won't help as all it does is change scheduling when CPU is at %100, while I don't want it to get ...
2
votes
1answer
2k views

How to configure the process open file limit of a user?

The default open file limit per process is 1024 on - say - Linux. For certain daemons this is not enough. Thus, the question: How to change the open file limit for a specific user?
3
votes
1answer
864 views

Increasing nproc limit for a non-root user . Only effective by restart

I am increasing nproc limit for one of a development user account in my rhel6 system . After searching some rubust solution , I zerod at editing /etc/security/limits.conf with these two lines : ...