免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2469 | 回复: 3
打印 上一主题 下一主题

[proxy] 怎样解决filedescriptors的问题? [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2004-09-10 15:17 |只看该作者 |倒序浏览
squid服务器,透明代理正常,设了cache为20GB,但没用多久就出现下面的错误,服务器死机,请教怎样解决?
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:06:56| comm_open: socket failure: (24) Too many open files
2004/09/09 22:07:17| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:07:33| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:07:49| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:08:05| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:08:21| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:08:37| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:08:53| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:09:09| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:09:25| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:09:41| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:09:57| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:10:13| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:10:29| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:10:45| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:11:27| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:11:43| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:15:05| WARNING! Your cache is running out of filedescriptors
2004/09/09 22:15:05| comm_open: socket failure: (24) Too many open files
2004/09/09 22:15:05| comm_open: socket failure: (24) Too many open files

论坛徽章:
0
2 [报告]
发表于 2004-09-10 15:38 |只看该作者

怎样解决filedescriptors的问题?

硬盘空间不够。修改一下cache设置。

论坛徽章:
0
3 [报告]
发表于 2004-09-23 16:04 |只看该作者

怎样解决filedescriptors的问题?

如果你记录了cache.log的话,你看一下你的filedescriptor是多少?缺省为1024,如果你的服务器比较繁忙,需要增大这个值!!

论坛徽章:
0
4 [报告]
发表于 2004-10-19 11:48 |只看该作者

怎样解决filedescriptors的问题?

Configuring file descriptors on Linux is a little complicated. You must edit one of the system include files, and execute some shell commands before compiling and running Squid. Start off by editing the file /usr/include/bits/types.h. Change the value for _ _FD_SETSIZE as follows:

#define _ _FD_SETSIZE    8192
Next, increase the kernel file descriptor limit with this command:

# echo 8192 >; /proc/sys/fs/file-max
Finally, increase the process file-descriptor limit in the same shell in which you will configure and compile Squid:

sh# ulimit -Hn 8192
This command must be executed as root and only works from the bash shell. There is no need to reboot on Linux.
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP