java中的最大套接字数 [英] Maximum number of socket in java

查看:201
本文介绍了java中的最大套接字数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Windows下java中的最大套接字数是多少?
如何更改?

How many is the maximum number of sockets in java under windows? How can I change it?

推荐答案

这在很大程度上取决于文件描述符的最大数量(Windows中的句柄) )OS配置为。每个打开的文件或套接字使用一个文件描述符例如,在Solaris中,65536是max fd的默认值。有可能,有使用FD池的其他文件,因此限制套接字的上限,除非操作系统被调整为增加FD的数量

This is largely dependent on the max number of file descriptors (handles in Windows) the OS is configured for. Each open file or socket uses one file descriptor. In Solaris, for example, 65536 is the default for max fd's. Chances are, there are additional files using the pool of FD's, therefore limiting the upper limit of sockets unless the OS is tuned to increase the number of FD's

在Windows NT /中2000 / XP(可能是Vista& 7)在\ WINDOW \ System32 \ config.nt(可能也是一个注册表设置?)中应该有一个条目FILES =,它应该给你最大的文件句柄数。

In Windows NT/2000/XP (Probably Vista & 7) there should be an entry "FILES=" in \Windows\System32\config.nt (Possibly also a registry setting?) that should give you the max number of file handles.

以下是对Windows中限制的更深入讨论:

Here is a more in depth discussion of the limits in Windows:

http://blogs.technet.com/markrussinovich/archive/2009/09/29/3283844 .aspx

这篇关于java中的最大套接字数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆