]> jfr.im git - irc.git/blame - software/!RELEASES/ircservices/achurch.org/services/lists/ircservices-coding/2002/000858.html
RELEASE -> !RELEASE
[irc.git] / software / !RELEASES / ircservices / achurch.org / services / lists / ircservices-coding / 2002 / 000858.html
CommitLineData
3bd189cb
JR
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2<HTML>
3 <HEAD>
4 <TITLE> [IRCServices Coding] A bit more on FD limits (not strictly services-related)
5 </TITLE>
6 <LINK REL="Index" HREF="index.html" >
7 <LINK REL="made" HREF="mailto:ircservices-coding%40ircservices.za.net?Subject=%5BIRCServices%20Coding%5D%20A%20bit%20more%20on%20FD%20limits%20%28not%20strictly%20services-related%29&In-Reply-To=NDBBLDHKLKMANPGMACIGIEPBCPAA.rg%40tcslon.com">
8 <META NAME="robots" CONTENT="index,nofollow">
9 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
10 <LINK REL="Previous" HREF="000857.html">
11 <LINK REL="Next" HREF="000859.html">
12 </HEAD>
13 <BODY BGCOLOR="#ffffff">
14 <H1>[IRCServices Coding] A bit more on FD limits (not strictly services-related)</H1>
15 <B>Russell Garrett</B>
16 <A HREF="mailto:ircservices-coding%40ircservices.za.net?Subject=%5BIRCServices%20Coding%5D%20A%20bit%20more%20on%20FD%20limits%20%28not%20strictly%20services-related%29&In-Reply-To=NDBBLDHKLKMANPGMACIGIEPBCPAA.rg%40tcslon.com"
17 TITLE="[IRCServices Coding] A bit more on FD limits (not strictly services-related)">rg at tcslon.com
18 </A><BR>
19 <I>Wed Jun 5 04:39:02 PDT 2002</I>
20 <P><UL>
21 <LI>Previous message: <A HREF="000857.html">[IRCServices Coding] (no subject)
22</A></li>
23 <LI>Next message: <A HREF="000859.html">[IRCServices Coding] A bit more on FD limits (not strictly services-related)
24</A></li>
25 <LI> <B>Messages sorted by:</B>
26 <a href="date.html#858">[ date ]</a>
27 <a href="thread.html#858">[ thread ]</a>
28 <a href="subject.html#858">[ subject ]</a>
29 <a href="author.html#858">[ author ]</a>
30 </LI>
31 </UL>
32 <HR>
33<!--beginarticle-->
34<PRE>OK, I've done a touch more research on this, the Linux default is
35maximum 1024 FDs per process, and 4096 in total. A `cat
36/proc/sys/fs/file-nr` will tell you the number of open FDs, the
37number in use, and the maximum limit.
38
39To increase the maximum number of FDs to 65536 (for a 2.2 kernel - I
40think 2.4 is the same):
41
421. In /usr/include/bits/types.h change the &quot;#define __FD_SETZISE
431024&quot; to &quot;#define __FD_SETSIZE 65536&quot;
442. Do the same in /usr/include/linux/posix_types.h
453. Recompile your kernel
46
47The following steps need to be performed every time you start the
48FD-hungry application, or in your init scripts:
49
504. echo &quot;65536&quot; &gt; /proc/sys/fs/file_max
515. echo &quot;196608&quot; &gt; /proc/sys/fs/inode_max
526. ulimit -HSn 65536
53
54Russ Garrett
55<A HREF="http://www.ircservices.za.net/mailman/listinfo/ircservices-coding">russ at garrett.co.uk</A>
56www.faereal.net
57
58
59</PRE>
60
61<!--endarticle-->
62 <HR>
63 <P><UL>
64 <!--threads-->
65 <LI>Previous message: <A HREF="000857.html">[IRCServices Coding] (no subject)
66</A></li>
67 <LI>Next message: <A HREF="000859.html">[IRCServices Coding] A bit more on FD limits (not strictly services-related)
68</A></li>
69 <LI> <B>Messages sorted by:</B>
70 <a href="date.html#858">[ date ]</a>
71 <a href="thread.html#858">[ thread ]</a>
72 <a href="subject.html#858">[ subject ]</a>
73 <a href="author.html#858">[ author ]</a>
74 </LI>
75 </UL>
76
77</body></html>