1824171 Members
2597 Online
109669 Solutions
New Discussion юеВ

How to change Block Size

 
Sushil Singh_1
Advisor

How to change Block Size

Hi All,
How to change the OS blokc size?

Thank
2 REPLIES 2
A. Clay Stephenson
Acclaimed Contributor

Re: How to change Block Size

That is set when you create the filesystem. Man newfs for details. It really only matters in hfs filesystems and you shouldn't be using them anyway. Vxfs filesystems are extent-based and blocksize really doesn't make any difference. Vxfs tends to write in 64k chunks regardless of what you do. If you are striping LVOL's then 64k tends to be the optimum stripsize for vxfs filesystems. In general, 8K is considered to be the best all-around db_block_size setting but you can play with other block settings.
If it ain't broke, I can fix that.
Wodisch_1
Honored Contributor

Re: How to change Block Size

Hi Sushil,

it depends on your file-system type. For HFS (=Berkeley) 8KB are really the all-time winners, but for VxFS (in a database environment) it simply isn't neccessary to change the default of 1KB blocks.
Read my more detailed explanation in that thread:
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x6dc0c8ecad09d6118ff40090279cd0f9,00.html
The important point is, that for databases you usually allocate the diskspace once (when you start) and if you need to extend it you do it in huge chunks (multi-megabyte) and you start on a "fresh" filesystem. Then your datafiles will be allocated in one huge chunk on the disk, and since the VxFS tries to read and write in 64KB blocks, the filesystem blocksize does not matter at all!

Just my $0.02,
Wodisch