Increase ulimit for # file descriptors

Like a normaluser :

 $ ulimit -n 4096 -bash: ulimit: open files: cannot modify limit: Operation not permitted 

As root, it works as desired, but then it will not affect the normaluser .

How to get out of this catch 22? I need it to be persistent.

+4
source share
2 answers

You can see / etc / security / limits.conf

+3
source

To change the file descriptor limit as a regular user before starting any application.

I use this small fdlimit utility that will increase the file descriptor limit with setrlimit () "before executing any program.

I use it like that

 $ sudo ./fdlimit <fdlimit> <program_to_run> 
+1
source

All Articles