Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [ulimit]

ulimit provides control over the resources available to the shell and to processes started by it, on systems that allow such control

0
votes
0answers
10 views

Ulimit in OpenSUSE and KDE

I use Opensuse Tumbleweed with KDE and trying to set core limit to unlimited. I added @users soft core unlimited @users hard core unlimited to /etc/security/limits.conf (my user is in users group), ...
1
vote
0answers
519 views

Increasing ulimit open files and max procedures

I'm working on a test machine and I want to increase ulimit's max open files and max procedures in macOS Sierra. I run sudo ulimit -n 100000 120000 and sudo ulimit -u 10000 12000. no error shows. But ...
4
votes
0answers
2k views

Increase number of open files in mac high sierra

On a mac high sierra 10.13.3 I have 256 open files. I want to raise it and I open a terminal and enter sudo launchctl limit maxfiles 1000000 1000000 This doesnt change anything when I enter ulimit ...
1
vote
0answers
351 views

Why is `ulimit` not limiting the memory usage as I expect?

I am trying to limit the memory usage of a process $ulimit -m 2 $/usr/bin/time -l ./myProcess arg1 arg2 The process run without being killed until time outputs 7.00 real 4.83 user ...
3
votes
1answer
683 views

Why doesn't ulimit -n work when called inside a script?

This is very odd. I'm trying to set the ulimit to 60000 via my startup.sh: #!/bin/bash ulimit -n 60000 echo "Hello! File Descriptor set" I can execute this with ./startup.sh (755 file permissions) ...
0
votes
1answer
3k views

Consequences of setting max open file descriptors to “unlimited” and how?

Is it possible to permanently set max open file descriptors to unlimited (or something like 1 000 000 000 /or even higher)? If yes, please tell me how. I tried ulimit -n 1048576 and it's working, but ...
0
votes
0answers
319 views

ulimit not working properly

i am trying to limit the memory usage of a process using ulimit ulimit -Sv 100000 ulimit -St 10 fakechroot ./compiledfile i am running the command in the same terminal (i am using ubuntu 16.04) and ...
1
vote
0answers
383 views

How to Increase Number of Open Files Limit in Linux

I'm trying to increase the number of files that can be opened by a user, but I keep getting the error: bash: ulimit: open files: cannot modify limit: Operation not permitted Currently it's at: ...
23
votes
3answers
19k views

Cannot Increase open file limit past 4096 (Ubuntu)

I'm on Ubuntu 17.04. Trying to increase the open file limit, and none of the instructions I've found online are working. I can go up to 4096, but can't go past that. $ ulimit -n 1024 $ ulimit -n 4096 ...
1
vote
1answer
721 views

I can't seem to resolve java.io.FileNotFoundException (Too many open files in system)

Disclaimer. First I am NOT a SU. I'm a mid level computer user with a bit of experience. I can write some basic code, have used computers for 20+ years. MSDOS, to Windows through the years now I'm ...
1
vote
1answer
477 views

Unable to enable core dumps (ubuntu/ARM)

I'm struggling to enable core dumps in Ubuntu 14.04 LTS (ARM) running on an nVidia Jetson TX1 SBC. I've done all of the usual stuff, including suggestions from here and here. There is plenty of space ...
1
vote
0answers
208 views

What is the difference between ulimit -r and -e?

What is the real-time scheduling priority mean (ulimit -e) ,and how to use it ? -r The maximum real-time scheduling priority -e The maximum scheduling priority ("nice")
0
votes
1answer
687 views

Limit CPU/RAM in all process for debian

Whenever i run CPU/RAM intensive tasks, i cant use my computer it freezes until the task is complete. I was looking for a way to limit resources per process for all processes. i.e so none of the ...
1
vote
0answers
110 views

ulimit seems to freeze bash script

I'm running a bash script that runs multiple small apps with different inputs. Some of these apps have bugs (e.g., never finish) and so I use ulimit to get the output or an error from all of them. In ...
2
votes
1answer
2k views

Real-time option in ulimit

Calling ulimit -a returns the following: core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited scheduling priority (-e) 0 file size (blocks, -...
0
votes
1answer
1k views

xterm: Can't execvp ulimit

I setup my suse to work with xterm so it could pop up gdb when my tests crash. The test launching .exe file runs the specified test and opens up gdb when crash occurs. This works just fine. There is a ...
1
vote
1answer
901 views

How to log out and back in using a bash script [closed]

I am trying to set ulimit when starting an EC2 instance on Amazon Web Services. Is there any way to write a script that will: sudo root to set ulimit, then: Log out and back in as my original user ...
1
vote
1answer
588 views

how does GDM set ulimits (Fedora)?

On Fedora FC20. /etc/security/limits.conf has: * soft nofile 60000 * hard nofile 60000 * soft nproc 30000 * hard nproc 30000 After logging in through GDM, and opening a shell, the limits are 60000 ...
5
votes
1answer
5k views

Increasing Yosemite maxfile limit for Application

I've been trying to up the maxfile limit and maxfileperproc limit on Yosemite, with no luck. I have created a sysctl.conf file in the etc folder, which has successfully increased the values when ...
20
votes
3answers
43k views

Open files limit does not work as before in OSX Yosemite [duplicate]

I just updated the Mac OS X to Yosemite, and now some applications do not work (IBM DB2). I know that I need to set the Open Files to 65000, however the command does not work. Andress-MBP:~ root# ...
17
votes
3answers
63k views

How do I check the ulimit for another user and change open files?

I have a process running as the gearman user and I want to change open files to avoid getting this nasty error: ERROR 2014-09-12 17:49:14.000000 [ main ] accept(Too many open files) -> libgearman-...
1
vote
1answer
498 views

Why isn't “(ulimit -d 1000; firefox) &” working?

I'm trying to limit the memory usage of firefox to prevent it from stalling the whole system with problematic web sites. I tried, in bash: (ulimit -d 1000; firefox) & This should limit the ...
1
vote
0answers
202 views

Ulimit is set on second login, not first

I'm using Debian Jessie and I have a strange error connected with setting the limit of open files per process. I want to increase the default limit for certain user (me), so I added to /etc/security/...
1
vote
1answer
3k views

Other ways to increase max open files?

I have an application which keeps giving me the following error. tail: inotify cannot be used, reverting to polling: Too many open files I have already followed all the advice I've been able to find ...
0
votes
1answer
764 views

How to check core dump enabledness status in bash?

$ ulimit unlimited $ sleep 2 && killall -SEGV cat & [1] 11358 $ cat Segmentation fault $ ulimit -c unlimited $ ulimit unlimited $ sleep 2 && killall -SEGV cat & [1] 11462 $ cat ...
11
votes
2answers
40k views

modify and apply limits.conf without reboot

I have added a line in /etc/security/limits.conf to increase the number of open files. * hard nofile 4096 root hard nofile 16384 However when I run ulimit -n it says 1024 which is the default ...
1
vote
2answers
3k views

Core dump generation on Linux

Something very perplexing is going on, with respect to my box. Below are my settings in /etc/sysctl.conf: kernel.core_pattern = core kernel.core_uses_pid = 1 In /etc/profile, I have this: ulimit -...
0
votes
0answers
4k views

How to increase maximum file open limit (ulimit) in Ubuntu?

Currently ulimit -n shows 10000. I want to increase it to 40000. I've edited /etc/sysctl.conf and put fs.file-max=40000. I've also edited /etc/security/limits.conf and updated hard and soft values. ...
4
votes
1answer
2k views

Does “ulimit -Su” limit the number of user processes created in interactive login subshells and tmux sessions created therein?

A few months ago, I wrote a set of bash scripts utilizing tmux to create a simple IDE on an AIX 7.1 server. There is a bug in one of my scripts that will sometimes generate user processes very rapidly ...
2
votes
1answer
5k views

values set in limits.conf are not working

I set some values in /etc/security/limits.conf as below: * hard stack 204800 * hard nofile 8192 Then rebooted the server. Now the ulimit command still lists some old/default values: # ...
1
vote
2answers
2k views

Why changes to /etc/limits don't work on an embedded system

I am trying to provide support for core dump on my ARM based target. I have read about both /etc/limits and /etc/security/limits.conf. My target file system doesn't have the latter one on to it. So I ...
0
votes
2answers
1k views

Does ulimit change resource limits at runtime?

Does ulimit change the limits of running programs? Are their specific resources which can not be changed at run time? If ulimit doesn't change limits at run time, does this mean that you have to ...
3
votes
1answer
1k views

Cannot increase maxfiles limits on Mac 10.7

I an only set lower values for the launchctl limit maxfiles. I try launchctl limit maxfiles 2048 2048 and nothing changes: $ launchctl limit maxfiles maxfiles 500 500 $ launchctl limit ...
0
votes
1answer
859 views

Do I have to restart my machine for ulimit - u to take affect?

So I have an external 3rd party application which runs on Java. The JVM is getting a load of OutOfMemeory errors and their support team suggested I raise the ulimit - u from he default 1024 to 4096 ...
0
votes
0answers
490 views

what are sane open file descriptor limits on linux?

Where can I get good guidance on sane values for open file descriptor limits on linux. We have users asking for massive numbers as their limits and I am unsure of the impact of this and what should ...
0
votes
1answer
2k views

What's the meaning of ulimit -a output?

What each of the values listed in the output of ulimit -a represents? For example, what's the meaning of the following output (I've removed the obvious ones)? core file size (blocks, -c) 0 ...
0
votes
1answer
673 views

Why do we need hard and soft limit in open file count?

I was reading a separate SU question on setting ulimit value and the answer from Gordon mentioned something about hard and soft limit on open file descriptor count. Just curious, why do we need a hard ...
6
votes
2answers
7k views

ulimit nofiles and lsof

If I do an lsof | grep user | wc -l I get a number returned in the 25,000 range. If I check ulimit -a user nofiles is set at 1024. Can someone help me to understand the number of open files ...
1
vote
1answer
281 views

Best folder configuration for application that opens around 1 million files and ulimit problems

I have an application that creates 16^5 files (1048576). I can configure it to create all them in the same folder or separate them in whatever way I want (having 1, 2, 3 or 4 subfolders on each folder)...
1
vote
1answer
369 views

Why does “ulimit -t 5” have no effect on “less” or “man”, but work on “yes”?

If I run $ ulimit -t 5 $ yes then yes gets killed after 5 seconds, but man and less/more don't. Why are those two immune to ulimit?
6
votes
1answer
11k views

Mac os x 10.7.4 process limit

I have a 709 max user process. I want to double it, or more. First: ulimit > ulimit -a core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited file size ...
5
votes
1answer
12k views

Why does limiting my virtual memory to 512MB with ulimit -v crash the JVM?

I am trying to enforce maximum memory a program can consume on a Unix system. I thought ulimit -v should do the trick. Here is a sample Java program I have written for testing : import java.util.*; ...
1
vote
2answers
10k views

pipe: too many files open renders entire OS completely useless

I'm running Ubuntu 12.04, and I am having a major problem. Two separate times today, one of my open gnome-terminal sessions locked up and printed the error pipe: too many open files I realize that ...
21
votes
2answers
13k views

Make ulimits work with start-stop-daemon

I have an init.d script that starts an app using start-stop-daemon --chuid SOME_SYSTEM_USER. That is, the app runs under a different user, not root. Problem is, the app needs special limit settings (...
1
vote
0answers
444 views

How to find out the available (and used) user resources?

With ulimit, we can find out how many open files, running processes etc. at most the user can have at the same time. My question is: how can we find out how much of these limits are being used and how ...
5
votes
1answer
952 views

Locked out of host after reaching some ulimit

So, I have a sudoer account in a remote host, in which I create a process with thousands of threads and sockets. The thing is, if I create too many threads/sockets (not sure which one, it might even ...
3
votes
2answers
2k views

daemontools and ulimit

I have a daemontools service whose /service/myservice/run contains: #!/bin/sh exec setuidgid someuser somecommand Now, if I run this as a script directly from a root shell, somecommand will get a ...
1
vote
0answers
483 views

Adobe flash on Linux 64bit: “Movie not loaded” and maximum stack-size

I was experiencing problems with all flash content (tried Firefox/Chromium/Opera, Ubuntu/Fedora and several Flash releases to no avail). While trying to playback any flash-movie, no video/sound ...
1
vote
3answers
7k views

XAMPP won't start Apache on Mac OS X 10.6.8 Snow Leopard

When I try starting Apache from the XAMPP control panel (Mac OS X 10.6.8 Snow Leopard), I get the following error popup and Apache won’t start: /Applications/XAMPP/xamppfiles/bin/apachectl: line 70: ...
23
votes
2answers
23k views

setting ulimit on a running process

I launched a server application and I want to run it for a long time for testing purpose. Unfortunately, I forgot to set before ulimit -c unlimited to catch an eventual crash and inspect it. Is there ...