Using dsync with disk init

Considerations for using dsync.

Note: Do not set dsync to false for any device that stores critical data. The only exception is tempdb, which can safely be stored on devices for which dsync is set to false.
  • (UNIX only) On raw devices, you cannot:
    • Set directio or dsync to true

    • Set directio or dsync via the sp_deviceattr stored procedure to true.

    Note: For HPUX, only the dsync option applies.
    Doing so returns a message such as:
    You cannot set option dsync for raw device 'dev/raw/raw235'
    or:
    You cannot set attribute dsync for raw device 'myrawdisk1'
  • When dsync is on, writes to the database device are guaranteed to take place on the physical storage media, and the SAP ASE server can recover data on the device in the event of a system failure.

  • When dsync is off, writes to the database device may be buffered by the UNIX file system. The UNIX file system may mark an update as being completed, even though the physical media has not yet been modified. In the event of a system failure, there is no guarantee that data updates have ever taken place on the physical media, and the SAP ASE server may be unable to recover the database.

  • dsync is always on for the master device file.

  • Turn off the dsync value only when databases on the device need not be recovered after a system failure. For example, you may consider turning dsync off for a device that stores only the tempdb database.

  • The SAP ASE server ignores the dsync setting for devices stored on raw partitions—writes to those device are guaranteed to take place on the physical storage media, regardless of the dsync setting.

  • disk reinit ensures that master..sysdevices is correct if the master database has been damaged or if devices have been added since the last dump of master.