Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

find out what is the right block size for SWAP?

Tags:

sysadmin

swap

i found the following method to create swap, from here

dd if=/dev/zero of=/root/myswapfile bs=1M count=1024

Is there any thumb rule that to decide block size ? What is the best block size for Swap in any machine ? Here it is 1M..

like image 393
user412125 Avatar asked Aug 19 '10 07:08

user412125


1 Answers

When creating a regular file for swap using dd the blocksize is a convenience to allow the count parameter to create a file of the specified size.

The underlying disk structure is unchanged by the bs= in the dd command.

like image 125
Richard Harrison Avatar answered Nov 13 '22 21:11

Richard Harrison