linux: errno: 11 eagain +resource temporarily unavailable-爱代码爱编程
文章目录
错误
2293324 clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7fd98d397a10) = -1 EAGAIN (Resource temporarily unavailable)
说明
man clone查看帮助手册,EAGAIN会转到看man fork。在fork的手册里有以下说明:
EAGAIN错误预示着线程的个数超出了限制。有以下的限制可能触发这个errno:
- the RLIMIT_NPROC soft resource limit (set via setrlimit(2)), which limits the number of processes and threads for a real user ID, was reached; ulimit里的 process个数,
- the kernel’s system-wide limit on the number of processes and threads, /proc/sys/kernel/threads-max, was reached (see proc(5));
- the maximum number of PIDs, /proc/sys/kernel/pid_max, was reached (see proc(5)); or
- the PID