Export (0) Print
Expand All

Registering Event Sink on Mailboxes

 

Topic Last Modified: 2006-06-29

This topic discusses how to use the RegisterMailbox.vbs script to register Auto Accept Agent event sinks on one or more resource mailboxes.

importantImportant:
The RegisterMailbox.vbs script uses Web Distributed Authoring and Versioning (WebDAV) to access the Exchange server. For the script to work, WebDAV must be enabled on the Exchange server. To disable WebDAV, refer to the Exchange Server 2003 Security Hardening Guide download page at http://go.microsoft.com/fwlink/?linkid=37804. When WebDAV is disabled, the script will not work. Additionally, the script is based on the default Exchange virtual directory naming (/exchange). If you have a different mailbox store virtual directory name, the script will not work. For more information about WebDAV, see the WebDAV Reference at http://go.microsoft.com/fwlink/?linkid=64698.

To help you grant mailbox permissions and register the Auto Accept Agent event sinks on mailboxes, the RegisterMailbox.vbs script has been provided in the install folder. You can use this script to either register mailboxes individually, or to register multiple mailboxes by providing a text file that contains the primary Simple Mail Transfer Protocol (SMTP) addresses of the resources that you want to register. You can create this file in Notepad or another text editor of your choice by typing the primary SMTP address for each mailbox you want to register, specifying each mailbox on a new line, and then saving the file as a text file (such as file.txt). The following is an example of what this text file might contain:

conf_room1@example.com

conf_room2@example.com

video_conf1@example.com

video_conf2@example.com

After you have created a text file that contains the mailboxes you want to register, use the RegisterMailbox.vbs script to register the mailboxes.

noteNote:
RegisterMailbox.vbs must be run on the Exchange server where the resource mailboxes are located. This script cannot be run remotely.

The following is the syntax for this script:

cscript RegisterMailbox.vbs {/m:mailbox@domain.com | /f:file.txt} [/t:domain\AgentAccountName] [/u] [/DEBUG]

Where:

/m

The primary SMTP address of the mailbox that you want to register. Use this switch when registering or unregistering a single mailbox.

/f

The name of the text file that contains the primary SMTP addresses of the mailboxes that you want to register. Use this switch when registering or unregistering multiple mailboxes. You must create the text file before you use this script. This switch cannot be used with the /m switch.

noteNote:
If the text file is not in the same folder as the RegisterMailbox.vbs script, you must provide the full path of the location of your text file.
/t

Specifies the account that will be granted full mailbox access. This is typically the domain account that the Auto Accept Agent is running as on the local server. The account must be provided as domain\accountname. If Auto Accept Agent is running as Local System, you do not have to specify this switch unless you want to grant permissions to a domain account that you can use to monitor the resource mailboxes, which is necessary for the MailboxStatus.vbs script. For information about MailboxStatus.vbs script, see Verifying Event Sink Registration.

/u

Tries to remove the mailbox binding. Additionally, this switch also tries to remove full mailbox access for the Auto Accept Agent account specified in the /t switch.

/DEBUG

Outputs verbose debug information that you can use to diagnose issues.

For example, if you were using a file that is named Mailboxes.txt to register multiple mailboxes, where the Agent's security context is example\AgentAccount, you might type the following at the command prompt:

C:\>cscript RegisterMailbox.vbs /f:Mailboxes.txt /t:example\AgentAccount
 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft