Date: Fri, 17 Nov 2006 11:15:00 +0100 From: VeeJay <maanjee@gmail.com> To: maanjee@gmail.com, freebsd-questions@freebsd.org Subject: Block Size (FreeBSD File System) Message-ID: <2cd0a0da0611170215w2a2d6855me48163247ad059ca@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
* Hello there I am building a Web Server with 4 x 146GB SAS disks (using RAID 10) with FreeBSD 6.1, Apache 2 & MySQL. I have read this below quoted information that to increase performance, one can set a Block Size. If so, how much? Could some genius advise what to do? I am having over 100GB for /var, 100GB for /home, 256MB for /root, 16GB for /swap, 4GB for /usr, etc. Block Size This section contains options that can really impair system performance. If you're new to FreeBSD, take the defaults! This is for experienced UNIX administrators who know exactly what they're doing. Block size refers to the minimum size of a file. If you have a file that contains just one tiny character, it uses one whole block, even if it barely fills that block. By the same token, if your file is just over the block size, it takes up one block and a fragment of another. Each block can be divided into fragments, so that multiple, slightly oversized files can use one block to store their extra tidbits. FreeBSD defaults to 8KB blocks. If you're creating a large partition―say, 1GB or more―use 16KB blocks. When you do this, you also need to change your fragment size. The FreeBSD file system (UFS, or UNIX File System) works best with fragments one−eighth the size of a block. This would be 16,384−byte blocks and 2,048−bit fragments. Set the block size with the newfs program. From the Disklabel screen, press N while on a partition to display a pop−up dialog box containing newfs options. To use 16KB blocks and 2KB fragments, enter .................................................................................................... newfs −f 2048 −b 16384 .................................................................................................... -- Thanks! BR / vj *
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2cd0a0da0611170215w2a2d6855me48163247ad059ca>