Sun Java System Messaging Server 6.3 Administration Guide

ProcedureTo Setup Quota Notification

Quota notification is the process of sending users a warning message when they are getting close to their quota. Using this feature requires three steps.

  1. Enable Quota Notification

    Run the following at the command line:

    configutil -o store.quotanotification -v [ yes | no ]

    If the message is not set, no quota warning message is sent to the user.

  2. Define a Quota Warning Message

    The Warning Message is the message that will be sent to users who are close to exceeding their disk quota. To define a quota warning message at the command line:

    configutil -o store.quotaexceededmsg -v ’message

    The message must be in RFC 822 format. It must contain a header with at least a subject line, follow by $$, then the message body. ’$’ represents a new line. Depending on the shell that you are using, it might be necessary to append a \ before $ to escape the special meaning of $. ($ is often the escape character for the shell.) Example:

    configutil -o store.quotaexceededmsg -v ”Subject: WARNING: User quota exceeded$$User quota threshold exceeded - reduce space used.’

    In addition, there is support for the following variables:

    [ID] - userid

    [DISKUSAGE] - disk usage

    [NUMMSG] - number of messages

    [PERCENT] - store.quotawarn percentage

    [QUOTA] - mailquota attribute

    [MSGQUOTA] - mailmsgquota attribute

    Here’s an example, using these variables:

    configutil -o store.quotaexceededmsg -v ”Subject: Overquota Warning$$[ID],$$Your mailbox size has exceeded [PERCENT] of its alloted quota.$Disk Usage: [DISKUSAGE]$Number of Messages: [NUMMSG]$Mailquota: [QUOTA]$Message Quota: [MSGQUOTA]$$-Postmaster’

  3. Specify how often the warning message is sent.

    Set the following parameter:

    configutil -o store.quotaexceededmsginterval -v number

    where number indicates a number of days. For example, 3 would mean the message is sent every 3 days.

  4. Specify a Quota Threshold

    A quota threshold is a percentage of a quota that is exceeded before clients are sent a warning. When a user’s disk usage exceeds the specified threshold, the server sends a warning message to the user.

    Note –

    When email notifications are not triggered until the user’s disk usage exceeds 100% of the quota regardless of the threshold set with store.quotawarn.

    For IMAP users whose clients support the IMAP ALERT mechanism, the message is displayed on the user’s screen each time the user selects a mailbox and a message is also written to the IMAP log.

    To specify a quota threshold at the command line:

    configutil -o store.quotawarn -v number

    where number indicates a percentage of the allowed quota.