Sun Java System Messaging Server 6.3 Administration Reference


The imsbackup utility is used to write selected contents of the message store to any serial device, including magnetic tape, a UNIX pipe, or a plain file. The backup or selected parts of the backup may later be recovered via the imsrestore utility. The imsbackup utility provides a basic backup facility similar to the UNIX tar command.

When imsbackup, imsrestore, imsimport or any processing intensive operation takes significantly more system resources than normal, and continues doing so longer than the msprobe interval, there may be a temporary backlog of DB transaction log files to be cleared. If there are more files than specified in, then msprobe may erroneously restart all the processes during a restore. To prevent this from happening, disable msprobe during the imsbackup, imsrestore, and imsimport.

Location: msg-svr-base/sbin

For more information about imsbackup and backing up the message store, see the section “Backing Up and Restoring the Message Store” in the Messaging Server Administration Guide.


imsbackup -f device [-b blocking_factor] [-d YYYYMMDD [:HHMMSS]]
[-e encoding] [-u file] [-m linkcount] [-ivlgx] [ name ...]


The options for this command are:



-b blocking_factor

Everything written to the backup device is performed by blocks of the size 512xblocking_factor. The default is 20.


Date from which messages are to be backed up, expressed in YYYYMMDD [:HHMMSS]; for example, -d 19990501:131000 would backup messages stored from May 1, 1999 at 1:10 pm to the present. The default is to back up all the messages regardless of their dates.

-e encoding

Mailbox name encoding (example: IMAP_MODIFIED-UTF-7) 

-f device

Specifies the file name or device to which the backup is written. If device is ”-’, backup data is written to stdout.


Debug mode. The output is written in the default log file not to the stdout. For the stdout, one should use -v.


Ensures that all messages are backed up for a partial restore. Backs up every message multiple times if necessary. 


Used to autoload tape devices when end-of-tape is reached. 

-m link_count

Specifies the minimum link count for hashing. 

-u file

Specifies a backup object file. This file contains the object names (entire message store, user, group, mailbox, and so on) to backup. See name for a list of backup object


Executes the command in verbose mode. 


Can be 1) logical pathname of the backup object, 2) user ID, 3) message store mailbox name. Backup objects and paths: 

  • Entire message store: /

  • Message store partition: /partition_name (default: /primary)

  • Backup group—a group of users defined with regular expressions in a configuration file. See To Create Backup Groups in Sun Java System Messaging Server 6.3 Administration Guide for details. Path: /partition_name/backup_group(/primary/user represents all users under primary).

  • User: /partition_name/backup_group/user_ID

  • Mailbox:/partition_name/backup_group/user_ID/mailbox_name

  • Message:/partition_name/backup_group/user_ID/mailbox_name/msgID

User IDs: can be any user ID in the message store. If the user is not in the default domain, the user ID must be fully qualified (example: If user is in the default domain, the user ID can stand alone (example: Wally).

mailbox: An email folder. It is specified using the following message store internal name:


Note that user is a message store keyword.


The following example backs up the entire message store to /dev/rmt/0:

imsbackup -f /dev/rmt/0 /

The following backs up the mailboxes of user ID joe to /dev/rmt/0:

imsbackup -f /dev/rmt/0 /primary/user/joe

The following example backs up all the mailboxes of all the users defined in the backup group groupA to backupfile:

imsbackup -f- /primary/groupA > backupfile