-Bash: fork: Resource temporarily unavailable problem Java code causes this problem because the number of connections set by linux users is too small, you only need to modify max user processes to set the maximum number of processes for each linux user at www.2cto.com. Below I will set the maximum number of processes for a linux user to 10000: ulimit-u 10000 ulimit-a core file size (blocks,-c) 0 data seg size (kbytes,-d) unlimited scheduling priority (-e) 0 file size (blocks, -f) unlimited pending signals (-I) 81920 max locked memory (kbytes,-l) 32 max memory size (kbyt Es,-m) unlimited open files (-n) 65536 need to be modified (because it is a tcp protocol to open a socket, to open the file handle, the maximum file handle opened by a single process is restricted. The default value is 1024) pipe size (512 bytes,-p) 8 POSIX message queues (bytes,-q) 819200 real-time priority (-r) 0 stack size (kbytes,-s) 10240 cpu time (seconds,-t) unlimited max user processes (-u) 81920 virtual memory (kbytes,-v) unlimited file locks (-x) unlimited what is a core file? When a program crashes, copies the stored image of the process in the core file of the current working directory of the process. The www.2cto.com core file is only a memory image (with debugging information added) and is mainly used for debugging. The core file is a binary file, and a corresponding tool is required to analyze the memory image when the program crashes. The default core file size is 0, so no file is created. You can use the ulimit command to view and modify the size of the core file. Permanently remove the maximum number of processes and maximum number of files opened in Linux: vi/etc/security/limits. conf # Add the following line * soft noproc 11000 # soft connection * hard noproc 11000 # hard connection * soft nofile 4100 * hard nofile 4100 Description: * indicates all users, noproc indicates the maximum number of processes, and nofile indicates the maximum number of files opened.