Questions tagged [ulimit]

ulimit gets or sets the upper limit for resources available to the current shell.

356 questions
1
vote
1 answer

What unit is used in python’s resource RLIMIT_FSIZE setting

According to the docs, with Python you can set the file size limit with: resource.setrlimit(resource.RLIMIT_FSIZE,(fileseeklimit,fileseeklimit)) but it is not clear what the unit is here. The Bash builtin ulimit uses kilobytes for everything.
Joachim Breitner
  • 25,395
  • 6
  • 78
  • 139
1
vote
1 answer

i cannot allocate 100KB with "fileuser - memlock unlimited" in /etc/security/limits.conf

I'm using Fedora release 17 (Beefy Miracle) in my lab, i trying to block 100KB of resident memory with mlock C function, the code is as follows. #include int main(){ char *p; mlock(p, 100000); sleep(100); } When i compiled the code…
c4f4t0r
  • 1,563
  • 15
  • 24
1
vote
2 answers

WEBLOGIC ulimit

I am using weblogic 12C in AIX OS. When I keep ulimit=unlimited in OS level and ulimit=8192 in commEnv.sh in weblogic, I get frequent "Too many file open " error. But when I keep ulimit=2048 in OS level and ulimit=8192 in commEnv.sh in weblogic,…
Shankar Rajan
  • 130
  • 2
  • 8
1
vote
1 answer

LevelDB: IO error: XXX.sst: Too many open files

I'm using LevelDB in my application with 5 databases. Each database is opened with the option max_open_files = 64. ulimit -Sn shows the operating system has a limit of 1024 files. Setting the limit to 2048 fixes the problem. Because I'm distributing…
genjix
  • 852
  • 2
  • 11
  • 21
1
vote
1 answer

How to get the number of timers in a process?

I'm having exactly the same problem described here: timer_create() : -1 EAGAIN (Resource temporarily unavailable) in short, some process is reserving a lot of timers via timer_create but never release them. What I cannot figure out is how to…
Umberto
  • 75
  • 2
  • 6
1
vote
1 answer

limit number of forks/child procs

I am hosting a computing service on Ubuntu 12.04 and I need a method to prevent users from forkbombing. I am currently using setrlimit(RLIMIT_NPROC) in Linux. However, this actually sets a global limit on the number of processes for a given UID.…
Jeroen Ooms
  • 31,998
  • 35
  • 134
  • 207
1
vote
1 answer

Global process spawn limit in PHP?

I have a PHP script which I am running on an Ubuntu linux machine. The script spawns multiple processes using the pcntl_fork() function, and uses the pcntl_waitpid() function to log that they are killed. It spawns these VERY often (I estimate about…
iralls
  • 376
  • 4
  • 16
0
votes
0 answers

Get available memory taking into account ulimit restrictions

I have a Python loop which checks that the available memory is always sufficient at each pass: import psutil for e in mylist: if psutil.virtual_memory().available: raise ValueError else: # Do some stuff... In order to add…
Oriane Nedey
  • 23
  • 1
  • 6
0
votes
1 answer

How to increase memory lock in Telegraf container?

I run Telegraf as a Docker container with a docker-compose file. telegraf: image: telegraf:1.26.3 container_name: telegraf depends_on: socket-proxy: condition: service_started influxdb: condition:…
Babasile
  • 360
  • 1
  • 6
  • 13
0
votes
0 answers

How to modify the ulimit of a process created by docker service

I have set ulimit soft and hard 8196 on both docker-compose.yml file as well as host machine at /etc/security/limits.conf but when I see the process Max Open Files at cat /proc/pid/limit soft limit it's still 1024.
santhosh
  • 1,919
  • 3
  • 21
  • 33
0
votes
1 answer

ElasticSearch In Kubernetes failed to start: "max number of threads [1024] for user [elasticsearch] is too low, increase to at least [4096]"

I am trying to deploy the elasticsearch (7.17.9) using the HELM chart in kubernetes. The POD's went on error and below is the message found in the logs "bootstrap check failure [1] of [2]: max number of threads [1024] for user [elasticsearch] is too…
linuxkaran
  • 71
  • 1
  • 9
0
votes
1 answer

Hitting ulimit on Debian11 with vite build (and others)

I am getting multiple error messages in different places that all hint towards somehow limiting ressources. I have a vuejs application on a server, running vite build can occasionally (not always) fail with runtime: failed to create new OS thread…
Scorix
  • 487
  • 6
  • 20
0
votes
0 answers

how to increase the value of ulimit -n in linode ubuntu server?

I have created mongodb database server in linode dedicated host and while tuning the database server for optimal permormence i could not increase the value of ulimit -n I have asked chat GPT, and search alot of forum and google for help no none of…
Sunil Sapkota
  • 918
  • 2
  • 11
  • 24
0
votes
1 answer

aix java core zero size

in my AIX 6.1 ,java 1.5.0 bash-3.2$ java -fullversion java full version "J2RE 1.5.0 IBM AIX build pap32devifx-20080811c (SR8a)" bash-3.2$ i am getting core by running java . but i see the size of core file is zero. i set ulimit -c unlimited and…
Meghasyam
  • 1,021
  • 2
  • 9
  • 7
0
votes
0 answers

Limit Overall Memory of Multiple Simultaneous Processes of the Same Executable

I have an application that uses Imagemagick's convert utility to resize images. The application has an API exposed which executes a convert command for each request. The application usually serves ~20 requests/s but can spike to upto 200/s. I want…
Swastik Gupta
  • 149
  • 1
  • 1
  • 12