Oracle ZFS provides the following features that make it ideal for backing up the Oracle Communications Messaging Server message store:
Snapshot backup
Enables the use of less expensive SATA drives
Built-in volume manager that enables you to grow file systems dynamically
Topics:
Before using ZFS to back up the Messaging Server message store, read "Messaging Server and Tiered Storage Overview," which describes message store operation, its performance characteristics, and how to plan for and allocate store partitions.
The basic recommendations for configuring ZFS and Messaging Server are:
Separating the Messaging Server mboxlist database, message file, and index cache files on different file systems
Configuring the index cache record file system to use the recordsize of 4 Kbytes
Disabling file access time record
Keeping ZFS pool space under 80 percent utilization to maintain pool performance
The following information provides more context on these recommendations.
The mboxlist database is a sleepycat database that contains mailbox meta data. The index cache records (store.idx and store.c*) contain meta information about mailboxes and messages. Messaging Server accesses and modifies this meta information, although the modifications tend to be more random and smaller.
The location of the index cache records is controlled by setting the partition:partition_name.path option, where partition_name is the name of the partition.
Each message file (*.msg) represents a single email. Each message file is written to disk once, never modified, read many times (for example, when a user accesses the email, when the messages are backed up, and so on) and may be deleted. By default, these files are stored with the index and cache files.
The location of message files is controlled by setting the partition:partition_name.messagepath option, where partition_name is the name of the partition.
Separating the message files from the index cache records to different partitions (and underlying file systems) enables you to configure the file system with properties appropriate for the access type.
The index recordsize is 128 bytes. Cache recordsize is usually less than 2 Kbytes. The mboxlist database maximum page size is 8 Kbytes. The default ZFS recordsize is 128 Kbytes. Reducing the recordsize to 4 Kbytes for these file systems can improve performance and reduce incremental snapshot backup size.
The message store does not utilize the file access time. By disabling file access time updates, you reduce unnecessary overhead.
ZFS pool performance can degrade when a pool is very full. As the pool approaches 100 percent full, more time is needed to find free space and it is more likely that the free space is available only in small chunks.
Configure the disk usage alarm threshold alarm.system:diskavail.threshold option to at least 20, to receive a warning before the disk becomes full. (The default value is 10). To enable message throttling sooner, configure the store.diskusagethreshold to 90.
The following steps implement the previously discussed recommendations.
Separate the Messaging Server mboxlist database, message file, and index cache files on different file systems. For example:
zfs create store/mboxlist zfs set mountpoint=/var/opt/sun/comms/messaging/store/mboxlist store/mboxlist zfs create store/primary-idx msconfig set partition:primary.path /store/primary-idx zfs create store/primary-msg msconfig set partition:primary.messagepath /store/primary-msg
Configure the index cache record file system to use the recordsize of 4 Kbytes. For example:
zfs set recordsize=8k store/primary-idx zfs set recordsize=128k store/primary-msg zfs set recordsize=8k store/mboxlist
Note:
This setting controls the recordsize of newly created files only.
Do not set recordsize smaller than the system page size (8 Kbytes on SPARC and 4 Kbytes on Intel).
Set recordsize=128k on the -msg file system even though that is the default so that it does not accidentally get overridden by a setting on a parent file system at a later time.
The default recordsize of 128k is appropriate for the message store message file system.
Disable file access time record. For example:
zfs set atime=off store/mboxlist zfs set atime=off store/primary-idx zfs set atime=off store/primary-msg
Configure the disk usage alarm threshold alarm.system:diskavail.threshold option to at least 20, to receive a warning before the disk becomes full. (The default value is 10). For example:
msconfig set alarm.system:diskavail.threshold 20
To enable message throttling sooner, configure the store.diskusagethreshold option to 90. (The default is 99). For example:
msconfig set store.diskusagethreshold 90
Perform snapshot backup regularly. Back up the mboxlist database, index, and message file systems atomically by using the zfs snapshot -r command. Then use the zfs send and receive commands, or an enterprise-level backup solution to save the data. For example:
zfs snapshot -r store@now zfs send store/mboxlist@now | ssh host2 zfs recv store/mboxlist zfs send store/primary-idx@now | ssh host2 zfs recv store/primary-idx zfs send store/primary-msg@now | ssh host2 zfs recv store/primary-msg
Perform incremental backups. You can use zfs send -i to perform incremental backups. Destroy the snapshots when they are not needed. For example:
zfs destroy -r store@now
Note:
ZFS snapshots are for backing up and restoring the entire message store files system. You cannot back up and restore individual mailboxes. However, you can use imsbackup to back up the snapshot and imsrestore to restore the mailboxes.