
I/O stack components Overview
Typically the stack consists of the following
• Database
• Character or block device driver
• Multipathing driver
• SCSI driver
• HBA
• System Bus
• Switch/iSCSI routers
• Storage Array
• Disks
Example of vendors:
ASM-Database IBM Oracle
Character or block device driver
Multipathing driver – PowerPath, Windows MPIO
SCSI driver
HBA – Host Bus Adapter, Qlogic (IBM), Emulex
System Bus - PCI
Switch/iSCSI routers – Brocade, McData
Storage Array – IBM DS8100, EMC, HDS, HP
Disks - Seagate
The database processes makes I/O calls to the block device. The I/O scheduler in Linux forms the
interface between the generic block layer and the low level device drivers. The block layer provides
functions that are utilized by the file systems, databases (10gR2) and the virtual memory manager to submit I/O requests to block devices. These requests are transformed by the I/O scheduler and made available to the low-level device drivers. The device drivers consume the transformed requests and forward them (by using device specific protocols) to the actual device controllers that perform the I/O operations.
The model above is missing something that is seen quite commonly in ‘real life’. Most UNIX and UNIX-Like systems have some sort of logical volume manager these days, and not all RDBMS’s are on ‘raw’ devices. This is an important thing to consider, and imposes some more stops on an IO’s journey.
ReplyDeleteIn AIX, for example - ‘raw’ devices are either entire PVs (physical or LUN disks) or they are raw logical volumes (commonly seen with Oracle 9i RAC) in the case of raw logical volumes, IO’s are also managed by the LVM sub system, and therefore spend some extra time in RAM.
In some cases, data files are kept on standard file systems, JFS/JFS2/EXT2,3/VxFS/etc… IOs to these systems also spend time in RAM (in most systems) and are buffered in File System Cache. What can make this perform even more poorly is the fact that RDBMS’s also perform buffering of their own (in RAM) - in the worst cases, database blocks can be buffered a multiple of times.
An important item to consider with back end storage arrays is cache size and cache utilization, and the types of data accesses that your RDBMS is executing.
Abstract Initiative
http://www.abstractinitiative.com/PerformanceJungle/