- 论坛徽章:
- 0
|
请问如何编译内核解除每个线程1024连接的限制
How to break the limitation of open file
1. Open /usr/src/linux/include/linux/fs.h
2. Modify macro NR_OPEN and INR_OPEN to the number 2048 or what you want
3. Open /usr/src/linux/include/linux/limits.h
4. Modify macro NR_OPEN to the same value as modified in file: fs.h before, and modify macro OPEN_MAX to increase the limitation of open file with one process.
5. Recompile kernel
 make menuconfig (do nothing, just quit and save);
 make dep;
 make clean;
 make bzImage;
 cp bzImage to /boot/xxx;
 cp Systems.map /boot;
6. Reboot and execute "ulimit -n" to check if it works |
|