increase ulimit for # of file descriptors

前端 未结 2 917
北荒
北荒 2021-01-20 03:20

As normaluser:

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

As root it works as

相关标签:
2条回答
  • 2021-01-20 03:57

    You may want to look at /etc/security/limits.conf

    0 讨论(0)
  • 2021-01-20 04:06

    To change file descriptor limit as normal user before running any applicaiton.

    I use this small utility fdlimit which will increase file descriptor limit using "setrlimit()" system call before executing any program.

    I use it like this

    $ sudo ./fdlimit <fdlimit> <program_to_run>
    
    0 讨论(0)
提交回复
热议问题