]> git.pld-linux.org Git - projects/rc-scripts.git/commitdiff
- Allow set /proc/sys/fs/file-max & inode-max
authorArtur Frysiak <artur@frysiak.net>
Wed, 22 Mar 2000 17:24:28 +0000 (17:24 +0000)
committerArtur Frysiak <artur@frysiak.net>
Wed, 22 Mar 2000 17:24:28 +0000 (17:24 +0000)
  (patch by Paweł Krawczyk <kravietz@alfa.ceti.pl>)

svn-id: @683

rc.d/rc.sysinit
sysconfig/system

index 9fc62b688e426480c324a70c04b3ed78522950aa..ccbc9f1d671091614f093ee25c18245d0a0af93f 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/sh
 #
 # /etc/rc.d/rc.sysinit - run once at boot time
-# $Id: rc.sysinit,v 1.50 2000/03/20 06:58:14 waszi Exp $
+# $Id: rc.sysinit,v 1.51 2000/03/22 17:24:28 wiget Exp $
 #
 # Taken in part from Miquel van Smoorenburg's bcheckrc.
 # Changes:      Arkadiusz Mi¶kiewicz <misiek@pld.org.pl>
@@ -455,6 +455,23 @@ show "`nls "Sending val. %s to /proc/sys/kernel/panic" "$PANIC_REBOOT_TIME"`"; b
 if (echo $PANIC_REBOOT_TIME > /proc/sys/kernel/panic); then deltext; ok; else deltext; fail; fi
 fi
 
+# If needed increase number of available system files
+# There are two versions of each setting, because file names
+# changed between Linux 2.0 and 2.2
+if [ -f /proc/sys/kernel/file-max -a "$VFS_FILE_MAX" -gt 0 ]; then
+        echo $VFS_FILE_MAX >/proc/sys/kernel/file-max
+fi
+if [ -f /proc/sys/fs/file-max -a "$VFS_FILE_MAX" -gt 0 ]; then
+        echo $VFS_FILE_MAX >/proc/sys/fs/file-max
+fi
+if [ -f /proc/sys/kernel/inode-max -a "$VFS_INODE_MAX" -gt 0 ]; then
+        echo $VFS_INODE_MAX >/proc/sys/kernel/inode-max
+fi
+if [ -f /proc/sys/fs/inode-max -a "$VFS_INODE_MAX" -gt 0 ]; then
+        echo $VFS_INODE_MAX >/proc/sys/fs/inode-max
+fi
+
+
 # Now that we have all of our basic modules loaded and the kernel going,
 # let's dump the syslog ring somewhere so we can find it later
 dmesg > /var/log/dmesg
index 4e1058ef2e9521dde6c78e762d29ad66733e2d45..a4df285b76f5585e879828a532632d67ef19618e 100644 (file)
@@ -1,4 +1,4 @@
-# $Id: system,v 1.12 2000/03/09 10:57:57 zagrodzki Exp $
+# $Id: system,v 1.13 2000/03/22 17:24:28 wiget Exp $
 
 # Do you want colorized starting scripts ?
 COLOR_INIT=yes
@@ -48,6 +48,15 @@ RUN_LDCONFIG=yes
 
 # Start DevFS daemon to preserve compatibility with old "style" device names
 RUN_DEVFSD=no
+# Adjust number of inodes and file handles available in the system.
+# If you have a havily loaded system and kernel complains about
+# file/inode limit reached in VFS, increase this 2x. The default
+# value is 4096 (file) and 8192 (inode). The inode number should be
+# always 2-3 times the file number. For most systems this should not
+# be changed
+#VFS_FILE_MAX=4096
+#VFS_INODE_MAX=8192
 
 # Set to anything other than 'no' to allow hotkey interactive startup...
 PROMPT=yes
This page took 0.109067 seconds and 4 git commands to generate.