Raw Partitions on Linux

You can create and mount database devices on raw bound devices for raw disk IO. Raw disk IO enables direct memory access from your address space to the physical sectors on the disk while omitting needless memory copy operations from the user address space to the kernel buffers.

Raw disk IO assumes that logical and physical IO are simultaneous, and writes are guaranteed to flush to the disk when the system write() call returns. When preparing a raw partition device, follow these guidelines:

  1. Do not initialize a database device on the partition that contains your Sybase installation software. Doing so destroys all existing files on that partition.
  2. A raw partition designated for use by Sybase cannot be mounted for use by the operating system for any other purpose, such as for file systems or swap space.
  3. After a Sybase configuration utility or the disk init command has initialized a portion of a partition as a database device, the entire partition cannot be used for any other purpose. Any space left on the partition beyond the size specified for the device can be reused with the disk resize command.
  4. To avoid any possibility of using a partition that contains the partition map, do not use cylinder 0.
  5. Place the database device on a character device, because the server recovery system needs unbuffered system IO.
  6. To determine whether a device is a block device or a character device run:
    ls -l <device path>