|
> 对照文件系统的I/O栈图,还是没能理解YongHuang所说的IO Trunksize 跟ORACLE BLOCK的关系
> 参照上面的两个图,YongHuang所说的“OS space allocation block size ”
> 是指Block device的block的大小吗?
The picture shows these three layers at the bottom: disk -> block device -> filesystem. Disk or hard drive has sector size, which is almost always 512 bytes (set by hard drive makers' low-level format). Block device can get the sector size. On Linux, the command is blockdev --getss. I still have some doubt about the meaning of fdisk (probably equivalent to mkdev on AIX) with -b, an option to "Specify the sector size of the disk. Valid values are 512, 1024, or 2048. (Recent kernels know the sector size. Use this only on old kernels or to override the kernel’s ideas.)" If you can specify a sector size regardless the hard drive sector size, that means OS does have its own space allocation block size, independent of hard drive space allocation block size. If you can't, then it's only one sector, and I'd better drop the word "OS" from "OS space allocation block size". I'm asking the question to a guy that has some Linux kernel knowledge. You can also ask your AIX admin if you can specify a sector size for mkdev. Man page doesn't seem to have such an option.
Filesystem of course has its block size, and it *is* I/O chunk size.
> 第二个图(AIX IO栈)的 Block I/O to logical disk的一次I/O是不是就是指block device的block size?
Not necessarily. Since there's no filesystem, how big an I/O is is determined by the process or application such as Oracle. Of course the OS has minimum and maximum I/O limitation; between the min and max, it's up to the process to decide what the I/O size should be. Block device's block size is, as I said in the paragraph above, is for space allocation, although it may also serve the role of being the *minimum* I/O chunk size.
> 在make filesystem的时候要指定BLOCK的大小,这个block的大小是不是指“I/O Trunk size”? 也就是第二个图中的I/O to blocks in a filesystemde的block的大小。 对文件logical读写的操作,一次I/O是不是就是指I/O Trunk size?
Absolutely. But change "trunk" to "chunk". "Chunk" is a non-technical term. I just chose it to avoid confusion with the dual meanings of the word "block".
By the way, I think sqysl and bluemoon0083 keep talking about OS as if it was only filesystem. Oracle can bypass filesystem, but never OS. If it could, it would directly work with BIOS.
Yong Huang
[The part about AIX mkdev command should be removed; it's not the same as Linux fdisk.]
[ 本帖最后由 Yong Huang 于 2008-11-13 09:26 编辑 ] |
|